Welcome to the Project Developers' Table

Moderator: Rathinagiri

User avatar
Rathinagiri
Posts: 5482
Joined: Tue Jul 29, 2008 6:30 pm
DBs Used: MariaDB, SQLite, SQLCipher and MySQL
Location: Sivakasi, India
Contact:

Re: Welcome to the Project Developers' Table

Post by Rathinagiri »

If you want to use another object to be used by ::oQTObject, it should be live at the runtime also! This is what had been explained by Roberto in the previous posts. :)

Here, the QValidator creates an object and is set as a validator object. So, it should be live at the time of running the software also.

So, you have to do the following:

1. You have to create a DATA property variable for the TEXTBOX object to hold the validator object:

DATA oValidator INIT Nil

2. At the time of creating the validator and setting it to the textbox object:

::oValidator := QValidator():New("^(\d|-)?(\d|,)*\.?\d*$")
::oQTObject:setValidator(::oValidator)

By this way both the objects (ie., oQTObject and oVAlidator) are available at the run time. I think it should work. Please try.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
User avatar
Rathinagiri
Posts: 5482
Joined: Tue Jul 29, 2008 6:30 pm
DBs Used: MariaDB, SQLite, SQLCipher and MySQL
Location: Sivakasi, India
Contact:

Re: Welcome to the Project Developers' Table

Post by Rathinagiri »

I have uploaded one file hmg.4.html (with status upto 180).

Please tell me if there is anything wrong or to be changed.

I request all the team members to update todo.txt and extensions.txt in SVN main directory so that I can update the project status.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
User avatar
sudip
Posts: 1456
Joined: Sat Mar 07, 2009 11:52 am
Location: Kolkata, WB, India

Re: Welcome to the Project Developers' Table

Post by sudip »

Thanks a lot Rathi. :)

My code is like:

Code: Select all

METHOD DataType ( nValue ) CLASS TEXTBOX

// Datatype is not a property of QLineEdit

   If Pcount() == 0

		RETURN ::nDataType

	ElseIf Pcount() == 1 

		::nDataType := nValue
      
      Do Case
         Case ::nDataType == TXT_NUMERIC
            if ::lCreated
               ::oQTObject:SetValidator( NIL )
               ::oQTObject:SetValidator( QValidator():New("^(\d|-)?(\d|,)*\.?\d*$"))
            endif
            ::nAlignment := TXT_RIGHT
         Case ::nDataType == TXT_DATE
            ::cInputMask := If( CSetCent(), "99/99/9999", "99/99/99")
      EndCase 
        
	EndIf

RETURN Nil
It's not working. It's not giving error, but nothing changed! I think I should add cValidator as a new (internal) property of textbox.

I shall check it. BTW, I mailed Pritpal regarding how to use validator with textbox.

Regarding Todo.txt. Ok I shall change :) (Sorry, for my delay)
With best regards,
Sudip
User avatar
Roberto Lopez
HMG Founder
Posts: 4023
Joined: Wed Jul 30, 2008 6:43 pm

Re: Welcome to the Project Developers' Table

Post by Roberto Lopez »

rathinagiri wrote:I have uploaded one file hmg.4.html (with status upto 180).

Please tell me if there is anything wrong or to be changed.

I request all the team members to update todo.txt and extensions.txt in SVN main directory so that I can update the project status.
Great!
Regards/Saludos,

Roberto


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

Re: Welcome to the Project Developers' Table

Post by Roberto Lopez »

sudip wrote:Hello,

Till now I cannot solve inputmask problem of textbox control fully. Inputmask (especially for numeric data types) is behaving differently. I can't solve the decimal point problem.

Please help me.
When I find something that is not directly supported by QT, I'm tagging as TODO and move to other thing, since I guess that in this stage of development is better to invest our time and energy on having more controls working.

ie: maxlength is not supported by QTextEdit (editbox) so, I've delayed to the next stage.

Hopefully, we will have a better knowledge about QT in the future to revisit this undone things to complete them.
Regards/Saludos,

Roberto


(Veritas Filia Temporis)
User avatar
Rathinagiri
Posts: 5482
Joined: Tue Jul 29, 2008 6:30 pm
DBs Used: MariaDB, SQLite, SQLCipher and MySQL
Location: Sivakasi, India
Contact:

Re: Welcome to the Project Developers' Table

Post by Rathinagiri »

I agree you verbatim Roberto.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
User avatar
Rathinagiri
Posts: 5482
Joined: Tue Jul 29, 2008 6:30 pm
DBs Used: MariaDB, SQLite, SQLCipher and MySQL
Location: Sivakasi, India
Contact:

Re: Welcome to the Project Developers' Table

Post by Rathinagiri »

I had uploaded radiogroup control with all the properties/events (except on change event since IMHO it is not supported by HBQT!?)

Also I could not make demo_2.prg run by changing hmg.ch. It shows some # translate errors which I could not trace out. :(
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
User avatar
Rathinagiri
Posts: 5482
Joined: Tue Jul 29, 2008 6:30 pm
DBs Used: MariaDB, SQLite, SQLCipher and MySQL
Location: Sivakasi, India
Contact:

Re: Welcome to the Project Developers' Table

Post by Rathinagiri »

Hi friends,

I have just uploaded the full working check button control except on change event (connect("toggled()")) because of the reasons stated above.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
User avatar
mol
Posts: 3825
Joined: Thu Sep 11, 2008 5:31 am
Location: Myszków, Poland
Contact:

Re: Welcome to the Project Developers' Table

Post by mol »

I'll commit COMBOBOX tomorrow. I didn't found some solutions, I'll post them in todo.txt
User avatar
Roberto Lopez
HMG Founder
Posts: 4023
Joined: Wed Jul 30, 2008 6:43 pm

Re: Welcome to the Project Developers' Table

Post by Roberto Lopez »

rathinagiri wrote:Hi friends,

I have just uploaded the full working check button control except on change event (connect("toggled()")) because of the reasons stated above.
Ok.

I'm suffering something similar with toolbar.

I need 'addto' method for QACTIONGROUP to implement 'checkgroup' functionality but this event appears to be not available in HBQT yet.

I'll add this information to the TODO file too. This will be useful to complete the work in the future.
Regards/Saludos,

Roberto


(Veritas Filia Temporis)
Post Reply