HMG 4 Started

Moderator: Rathinagiri

User avatar
Roberto Lopez
HMG Founder
Posts: 4004
Joined: Wed Jul 30, 2008 6:43 pm

Re: HMG 4 Started

Post by Roberto Lopez »

rathinagiri wrote:Yes. So, shall I co-ordinate with the shared properties?

I think color is taken by Marek. The only property unattended in checkbox which is common is transparent. Shall I take that one and try on?
I've just took color from Marek to to move it to control class and solve some problems.

Yes, you can try transparent with a little advise: If a specific property is not directly supported by QT, I guess that this is not the moment to stop at esoteric solutions :)

ie: maxLength (EditBox) is not supperted by QTextEdit() so, I've documented the situation and going on with another thing.

When we finished with functionality directly supported by QT, we will focus on tricks to support the other things (hopefully, by that time we will acquired the needed experience and knowledge).
Regards/Saludos,

Roberto


(Veritas Filia Temporis)
User avatar
Roberto Lopez
HMG Founder
Posts: 4004
Joined: Wed Jul 30, 2008 6:43 pm

Re: HMG 4 Started

Post by Roberto Lopez »

Roberto Lopez wrote:
rathinagiri wrote:Yes. So, shall I co-ordinate with the shared properties?

I think color is taken by Marek. The only property unattended in checkbox which is common is transparent. Shall I take that one and try on?
I've just took color from Marek to to move it to control class and solve some problems.

Yes, you can try transparent with a little advise: If a specific property is not directly supported by QT, I guess that this is not the moment to stop at esoteric solutions :)

ie: maxLength (EditBox) is not supperted by QTextEdit() so, I've documented the situation and going on with another thing.

When we finished with functionality directly supported by QT, we will focus on tricks to support the other things (hopefully, by that time we will acquired the needed experience and knowledge).
And perhaps this is a good moment to add a text file at SVN to document these situations...
Regards/Saludos,

Roberto


(Veritas Filia Temporis)
User avatar
Roberto Lopez
HMG Founder
Posts: 4004
Joined: Wed Jul 30, 2008 6:43 pm

Re: HMG 4 Started

Post by Roberto Lopez »

esgici wrote:
Roberto Lopez wrote: Really nice... :)
As I've said, it looks hard at the beginning, but it can be extremely useful when you are handling a complex situation...
Thanks, please continue :D

Best regards

--

Esgici
Well... the last chapter...

You'll find references to 'self'.

Self is used to refer to the class object itself.

So, you'll find the the 'new' method in the control class return 'self' whenis called, giving...

oButton := Button:New()

Since new() method return 'self' oButton variable holds the object (as simple as that).

Class variables must be reference in this way:

::xVar

form the class methods.

And this is all... (I'm going to work in color properties).

Please, review the code, create your own class for do tests you should be ready soon...
Regards/Saludos,

Roberto


(Veritas Filia Temporis)
User avatar
mol
Posts: 3718
Joined: Thu Sep 11, 2008 5:31 am
Location: Myszków, Poland
Contact:

Re: HMG 4 Started

Post by mol »

I'm working over AutoSize property of label.
It's almost done, but, I can't calculate text width with function GetTextWidth.
I think, this function is placed in libhbwin.a library, but compilator can't find it?
What's going on?

PS. I've realized Alignment property and added new properties: WordWrap and VAlignment (vertical alignment)...
Marek
User avatar
mol
Posts: 3718
Joined: Thu Sep 11, 2008 5:31 am
Location: Myszków, Poland
Contact:

Re: HMG 4 Started

Post by mol »

I've prepared label.prg and demo_4.prg
Please test it.
Marek
User avatar
esgici
Posts: 4543
Joined: Wed Jul 30, 2008 9:17 pm
DBs Used: DBF
Location: iskenderun / Turkiye
Contact:

Re: HMG 4 Started

Post by esgici »

Roberto Lopez wrote:
Well... the last chapter...

... review the code, create your own class for do tests you should be ready soon...
Thanks a lot Maestro :D

--

Esgici
Viva INTERNATIONAL HMG :D
User avatar
sudip
Posts: 1454
Joined: Sat Mar 07, 2009 11:52 am
Location: Kolkata, WB, India

Re: HMG 4 Started

Post by sudip »

FontColor, BackColor, Visible property connected to Spinner
modified source/spinner.prg

Hello Roberto,

How is your health :) (I read you got fever)

If TextBox control is free, may I work on it after finishing Spinner?
With best regards,
Sudip
User avatar
Roberto Lopez
HMG Founder
Posts: 4004
Joined: Wed Jul 30, 2008 6:43 pm

Re: HMG 4 Started

Post by Roberto Lopez »

mol wrote:I'm working over AutoSize property of label.
It's almost done, but, I can't calculate text width with function GetTextWidth.
I think, this function is placed in libhbwin.a library, but compilator can't find it?
What's going on?

PS. I've realized Alignment property and added new properties: WordWrap and VAlignment (vertical alignment)...
Marek
libhbwin gives support for Windows only. Please, consider that we are working on a multi-platform project. Please, if you used, eliminate any reference to that.

Moreover, the goal to this first stage is to mimic as good as possible the current HMG features, please, do not add new functionality yet.
Regards/Saludos,

Roberto


(Veritas Filia Temporis)
User avatar
Roberto Lopez
HMG Founder
Posts: 4004
Joined: Wed Jul 30, 2008 6:43 pm

Re: HMG 4 Started

Post by Roberto Lopez »

sudip wrote:FontColor, BackColor, Visible property connected to Spinner
modified source/spinner.prg

Hello Roberto,

How is your health :) (I read you got fever)

If TextBox control is free, may I work on it after finishing Spinner?
I'm a little better, thanks!

Please, go on with TextBox.
Regards/Saludos,

Roberto


(Veritas Filia Temporis)
User avatar
mol
Posts: 3718
Joined: Thu Sep 11, 2008 5:31 am
Location: Myszków, Poland
Contact:

Re: HMG 4 Started

Post by mol »

I can't see possibility to realize AutoSize property without GetTextWidth.
I'll read QT doc. Maybe there is a resolve of problem.
Post Reply