Hello, Items specific to the Qt widget set
QAbstractSpinBox have protected function which I need to complete spin edits:
QLineEdit * lineEdit() const;
Best regards,
Paul Ishenin.

Mailing lists / qt / 2007-09
13 messages · 4 people · –
Reply by email Subscribe to this list Your subscription
Read-only archive. Use j and k to move between messages.
Hello, Items specific to the Qt widget set
QAbstractSpinBox have protected function which I need to complete spin edits:
QLineEdit * lineEdit() const;
Best regards,
Paul Ishenin.
QAbstractSpinBox have protected function which I need to complete spin edits: QLineEdit * lineEdit() const;
Sorry, I sent this without finishing.
Den, can you add protected function to bindings?
Best regards,
Paul Ishenin.
Hello, Items specific to the Qt widget set QAbstractSpinBox have protected function which…
why do you need lineEdit() ?
btw. I've had 10 free minutes today, so compiled latest svn, and found that there's again bug with window closing (when you press on "X"), and FormCloseQuery() i assigned ....
Modal Windows:
It dissapears, and then I have confirmation dialog, if U answer "No", then it have strange results .... must kill app.
Normal windows:
If you answer Yes or No it's closed.
App. Main Window:
If you answer Yes it closed normally, but if U press No, app main window disappear and app is still running.
zeljko
to implement missed things in TQtWSCustomFloatSpinEdit:
class function GetSelStart(const ACustomEdit: TCustomEdit): integer;
override;
class function GetSelLength(const ACustomEdit: TCustomEdit):
integer; override;
class procedure SetSelLength(const ACustomEdit: TCustomEdit;
NewLength: integer); override;
class procedure SetSelStart(const ACustomEdit: TCustomEdit;
NewStart: integer); override;I have not looked at that problem. If it is very annoying to you I will look tomorow.
Best regards,
Paul Ishenin.
I will not have any free time tomorrow, but it's possible that I'll take some time during saturday & sunday , and write some code :)
zeljko
Sorry, I sent this without finishing. Den, can you add protected function to bindings?…
????? ?????? wroteDen, can you add protected function to bindings?
quick hack:
qt4.pas:
function QAbstractSpinBox_lineEdit(handle: QAbstractSpinBoxH): QLineEditH;
cdecl; external QtIntf name 'QAbstractSpinBox_lineEdit';lib source code:
QLineEditH QAbstractSpinBox_lineEdit(QAbstractSpinBoxH handle) {
return (QLineEditH) ((QAbstractSpinBox *)handle)->lineEdit();}
compile output:
../qt-x11-opensource-src-4.2.3//include/QtGui/../../src/gui/widgets/qabstractspinbox.h:130: error: ?QLineEdit* QAbstractSpinBox::lineEdit() const? is protected lib/qabstractspinbox.cppb:186: error: within this context
bad luck ;-)
So I will see what I can do, this will not be an easy thing. I know what to do manually (derive a class,change access specificier,misuse typecast,...), but is too bad I do not have a nice generator framework. Perhaps I will just postpone the generator modification till I get more requests for protected functions.
So I will look into it, but have some patience.
regards,
Den Jean
Den Jean wroteSo I will look into it, but have some patience.
I did another quick hack:
V1.49:
function QLCLAbstractSpinBox_lineEditHandle(protectedhandle: QAbstractSpinBoxH): QLineEditH;why do you need lineEdit() ? btw. I've had 10 free minutes today, so compiled latest svn,…
You mean that this bug was not present at some moment?
I checked what happen (but I dont know what happen in qt core ofcource). In order to prevent window closing we must set ignore flag for QCloseEvent and we are doing that in qtwidgets.pas. Also we talking to qt that we handle that signal ourself. Dont know what qt need? It acts as ignore flag is not set. I belive bindings are innosence in this case.
Zeljan, if you know revision where that feature was working please tell me.
Best regards,
Paul Ishenin.
yep, it was ok before I went onto vacations (beginning of August).
I checked what happen (but I dont know what happen in qt core ofcource).
nothing happened in qt core, 4.3.0 and 4.3.1 have same problem.
In order to prevent window closing we must set ignore flag for QCloseEvent and we are doing that in qtwidgets.pas. Also we talking to qt that we handle that signal ourself. Dont know what qt need? It acts as ignore flag is not set. I belive bindings are innosence in this case.
That's the problem I've been talkin about with Den few months ago, he sent fix with lcl glue message (SlotClose()), and then it was ok. Maybe something changed in LCL ?
zeljko
zeljko wroteThat's the problem I've been talkin about with Den few months ago, he sent fix with lcl glue message (SlotClose()), and then it was ok. Maybe something changed in LCL ?
I've made rather big restructuring and code moving, so my changes can cause this problem. But I am curious what was in Den's fix? If you give me some tips I will look more closely.
Best regards,
Paul Ishenin.
nothing, just SlotClose() code as it is now and LCLGlueMessages in uses of qtwidgets.pas.
Before that it was declaration of TLMessage and DeliverMessage() method. I must say that I didn't understand that fix (mainly because of no time to read docs about lcl internals) but it worked ok.
No, code was ok. Just one missed "Result := inherited" in overrided
EventFilter :)fixed.
Best regards,
Paul Ishenin.
great ! :)