Lazarus

Announcements => Third party => Topic started by: Onur2x on April 05, 2022, 06:04:27 am

Title: Lazarus visual components
Post by: Onur2x on April 05, 2022, 06:04:27 am
Hello (Lazarus visual components) A long time ago I decided to make some components for a project. It uses BgraBitmap. It needs to be developed. Beautiful visual programs can be made. I will continue to improve as long as I am eligible. The link is below.

I write hobby code with Pascal, I love pascal language. I am never a professional, I have not received an education. I'm trying to learn something by myself.
pros
If you have a talent for drawing pictures, very nice controls can occur.
Fully customizable. It's up to your imagination.
The components all derive from the (TcustomControl or TgraphicsControl) class. (Tedit included. inspired by lazarus customdrawn)


deficiencies
More skins should be added. More controls should be added.


https://github.com/Onur2x/onurcomp (https://github.com/Onur2x/onurcomp)

Title: Re: Lazarus visual components
Post by: AlexTP on April 05, 2022, 10:30:14 am
Why not to name the topic 'Onur's visual components'?
Title: Re: Lazarus visual components
Post by: kupferstecher on April 05, 2022, 12:10:21 pm
Hi, a screenshot would be nice!
Title: Re: Lazarus visual components
Post by: Onur2x on April 05, 2022, 02:46:10 pm
I couldn't draw a good picture in a hurry. I guess I don't really have a talent for this.
I also made a small demo.
Title: Re: Lazarus visual components
Post by: Onur2x on March 24, 2023, 10:09:32 pm
Onpagecontrol = A component derived from TCustomcontrol. Pages are a rendered component and accept components on it.

OnGraphicsbutton = button control derived from TGraphicscontrol.

OnCropbutton = Button control derived from TCustomcontrol. With this control you can add buttons with cropped corners. Square, triangle, round or polygon etc.It can take shape according to the picture.

Onpanel = A panel derived from Tcustomcontrol. Component can be put on it. And with the crop feature, you can create panels as you wish.

Onheaderpanel = It is a derived panel from Tcustomcontrol. Component can be put on it. And with the crop feature, you can create panels as you wish.

Oncollapsedpanel = A panel derived from Tcustomcontrol. Component can be put on it. And with the crop feature, you can create panels as you wish. It also has the ability to reduce or enlarge with a button on it. You set the button position

Ongraphicspanel = A panel derived from TGraphicscontrol. Components cannot be placed on it. It is a "tshape"-like component.

OnEdit = A component derived from TCustomcontrol. Developed from Lazarus customdrawn controls. It has crop property.It can take shape according to the picture.

OnMemo = A component derived from TCustomcontrol. Developed from Lazarus customdrawn controls. It has crop property.It can take shape according to the picture.

OnSpinedit = A component derived from TCustomcontrol.It has crop property.It can take shape according to the picture.

OnCombobox = A component derived from TCustomcontrol. It has a crop feature. can take shape according to the picture.

OnListbox = A component derived from TCustomcontrol. It has a crop feature. can take shape according to the picture.

Oncolumlist = A component derived from TCustomcontrol. It has a crop feature. can take shape according to the picture.Listing is done by creating columns. can be used like listview or stringrid for example.

OnSwich = A component derived from TGraphicControl.

OnSrollbar = A component derived from TCustomcontrol. It has a crop feature. can take shape according to the picture.

OnProgressbar = A component derived from TGraphicControl.

OnTrackbar = A component derived from TGraphicControl.

OnCheckbox = A component derived from TGraphicControl.

OnRadiobutton = A component derived from TGraphicControl.

OnLABEL = A component derived from TGraphicControl.The label is created by taking the letters on the bitmap.Takes the fonts from the image.and animation can be created

OnNormalLABEL = A component derived from TGraphicControl.is a component that has a label with the font on the component. animation can be created

OnLED = A component derived from TGraphicControl. On off.

OnKnob = A component derived from TGraphicControl. Knob control.
Title: Re: Lazarus visual components
Post by: Blaazen on March 24, 2023, 10:33:59 pm
The prefix "On..." makes it sounds like events: OnEdit.OnEditingDone  :)
Title: Re: Lazarus visual components
Post by: PeterEvans on March 26, 2023, 06:47:55 am
Perhaps you could rename them like:

   OnGraphicsButton ==>  OnurGraphicsButton
Title: Re: Lazarus visual components
Post by: Onur2x on March 26, 2023, 09:56:01 pm
Thank you for your comments, I will implement it
Title: Re: Lazarus visual components
Post by: KodeZwerg on March 26, 2023, 10:15:37 pm
Cool project! (the included demo .exe does not run on my Windows 10 64bit but the skinmaker .exe tool does run)
Screenshots and skinmaker looking great!
Its really a neat project that I install one day to help supporting.

Questions:
Can the skin file be included into resource of binary and called from there or does it need to be in folder of .exe as a seperate file?
Can I switch during runtime the skins? (like "light" and "dark" for example)
Title: Re: Lazarus visual components
Post by: Onur2x on March 26, 2023, 11:31:07 pm
You can create new skins with skin builder. you also have a chance to load "onimg1.Loadskin(filename); " at runtime. I tried a few skins, but I guess drawing really isn't for me :) I have a terrible drawing skill. I started updating in Skinbuilder, it was created very amateurishly. At least it was used to make simple skins.
also if you want opacity and color change on a single skins "onimg1.opacity:= 0 .. 255" "onimg1.mcolor:=colortostring(clred);" you can use
Title: Re: Lazarus visual components
Post by: kirchfritz on March 27, 2023, 07:57:59 am
Cool project!
The included example does compile, but does not run, because you set the property LoadSkins of ONImg1 to a local PNG!!

 object ONImg1: TONImg
    MColor = 'clnone'
    Opacity = 255
    LoadSkins = 'D:\Onur_Yedek\mailler\lazarus\components\paketler\Onur\skins2.png'
  end
Title: Re: Lazarus visual components
Post by: loaded on March 27, 2023, 08:22:02 am
You did a great job, congratulations.
Title: Re: Lazarus visual components
Post by: Onur2x on March 27, 2023, 02:06:37 pm
I'm really sorry. I updated the demo project
Title: Re: Lazarus visual components
Post by: circular on April 01, 2023, 03:26:14 pm
Congrats it looks very good  :)
Title: Re: Lazarus visual components
Post by: Onur2x on April 01, 2023, 04:09:52 pm
Thank you. We also thank you for the BGRABitmap.
Title: Re: Lazarus visual components
Post by: lainz on April 01, 2023, 05:37:51 pm
Cool project. It's using BGRABitmap 9 slice scaling?
Title: Re: Lazarus visual components
Post by: Onur2x on April 01, 2023, 09:26:30 pm
Yes. for example when drawing controls. top left - top - top right  and bottom left - bottom- bottom right and left - center -right  . drawn in the form. Image is not drawn to the control as it is
Title: Re: Lazarus visual components
Post by: Onur2x on April 01, 2023, 09:33:54 pm
If he can draw a few pictures with painting skills, we can decorate it with a few skins. Unfortunately, I'm very inept at drawing.
example picture
Title: Re: Lazarus visual components
Post by: incendio on May 08, 2023, 03:30:52 am
Hi,

I downloaded the example and tried to installed onur.lpk, but got erros :

Warning: windres: can't open file `panel.png': No such file or directory
Error: Error while compiling resources -> Compile with -vd for more details. Check for duplicates.

Am I missing something?
Title: Re: Lazarus visual components
Post by: Onur2x on May 11, 2023, 01:58:47 am
If you update the Onur.rc file, it will be fixed.

//panel RCDATA "panel.png"
//skins RCDATA "skins.ini"
//skins XML "skins.xml"
skn RCDATA "skins.osf"
TinyPortal © 2005-2018