php-qt-users Mailing List for PHP-Qt (Page 10)
Status: Beta
Brought to you by:
tm243
You can subscribe to this list here.
2005 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(6) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2006 |
Jan
(40) |
Feb
|
Mar
|
Apr
|
May
(2) |
Jun
(4) |
Jul
(3) |
Aug
(1) |
Sep
|
Oct
(11) |
Nov
(2) |
Dec
(1) |
2007 |
Jan
(10) |
Feb
(11) |
Mar
|
Apr
|
May
|
Jun
(2) |
Jul
(16) |
Aug
(4) |
Sep
(19) |
Oct
|
Nov
(1) |
Dec
(3) |
2008 |
Jan
(11) |
Feb
(16) |
Mar
(12) |
Apr
(2) |
May
|
Jun
(7) |
Jul
(17) |
Aug
(5) |
Sep
(12) |
Oct
(12) |
Nov
(24) |
Dec
(38) |
2009 |
Jan
(9) |
Feb
(10) |
Mar
(12) |
Apr
(22) |
May
(45) |
Jun
(25) |
Jul
(32) |
Aug
(10) |
Sep
(6) |
Oct
|
Nov
(2) |
Dec
(8) |
2010 |
Jan
(4) |
Feb
(9) |
Mar
(5) |
Apr
(1) |
May
|
Jun
|
Jul
(5) |
Aug
(3) |
Sep
(1) |
Oct
(3) |
Nov
|
Dec
|
2011 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
|
Jun
|
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
2014 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(1) |
2016 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2017 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Ferenc V. <li...@ne...> - 2006-01-19 23:52:42
|
RESOLVED: I copied the php.ini-dist to /usr/local/php511/lib/php.ini (That "PREFIX/lib" dir is the default config location.) Thanks, Ferenc Ferenc Veres wrote: > Note, that I cannot find any php.ini in the /usr/local/php511 directories. |
From: Ferenc V. <li...@ne...> - 2006-01-19 23:09:24
|
Hi All, This is a bit off topic, but maybe someone can help: I compiled php511 to /usr/local/php511. If I compile without --disable-cgi, I get the /usr/local/php511/bin/php printing content type and HTML formatted error messages. (<b>error in line</b>: 232 and similar things) If I compile with --disable-cgi, the built PHP looks OK to run php_qt programs, it prints nothing more than I "echo" (no HTML formatting, no HTTP content type), but I am unable to set "error_reporting" to E_ALL. I tried this in my main.php code: ini_set("error_reporting", "E_ALL"); Note, that I cannot find any php.ini in the /usr/local/php511 directories. If I did "if($a == 1)" I got "Warning: uninitialized variable" with the previous built (which printed HTML formatting). Now I don't get any warning for $a there! :-( Any ideas how to make no HTML version WITH full error reporting? :-) Thanks in advance, Ferenc ps: Oh, I wanted to report build errors of the current revision, but I just realized, that I did not run "phpize". I had runtime errors with unresolved symbols on module load, so I went back to rev. 197, but I forgot phpize! So I will try again tomorrow! |
From: Thomas M. <tm...@ip...> - 2006-01-19 19:47:06
|
piotr mali=C5=84ski wrote on Donnerstag, 19. Januar 2006 19:07: > I've downloaded php-qt from svn today, I run phpize, then ./configure > which dies do to syntax error: > > checking for Qt binaries... default path > checking for php_qt... yes, shared > ./configure: line 3307: syntax error near unexpected token > `qt/classes/qcharref. > cpp' > ./configure: line 3307: ` qt/classes/qcharref.cpp \ ' I removed the blanks after the backslashes. Maybe that was it. =2D-=20 Thomas |
From: <rik...@gm...> - 2006-01-19 18:08:35
|
I've downloaded php-qt from svn today, I run phpize, then ./configure which dies do to syntax error: checking for Qt binaries... default path checking for php_qt... yes, shared ./configure: line 3307: syntax error near unexpected token `qt/classes/qcharref. =20 cpp' ./configure: line 3307: ` qt/classes/qcharref.cpp \ ' |
From: Thomas M. <tm...@ip...> - 2006-01-19 00:00:26
|
RmVyZW5jIFZlcm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fubm90IGFjY2VzcyBtZW1vcnkgYXQgYWRk cmVzcyAweDdlYjExMGI3CgotLSAKVGhvbWFzCg== |
From: Thomas M. <tm...@ip...> - 2006-01-18 22:40:24
|
Thomas Moenicke wrote on Dienstag, 17. Januar 2006 10:58: > Lets finish QString and test all functions there. All I have seen in php > internals stores strings binary. Maybe, we have luck. Ok, I improved the argument handlers, now I have no more segfaults, toUtf8() returns any cryptical signs ;) -- Thomas |
From: Ferenc V. <li...@ne...> - 2006-01-18 21:04:12
|
Hi All, I still don't get it. I tried to change tutorial 6 to add a different widgets to the grid, please see the following modifications of "LCDRange" original example class: /* LCD and slider */ class Test1 extends QWidget { public $lcd; public $slider; public $layout; function __construct() { parent::__construct(); $this->lcd = new QLCDNumber(2,$this); $this->slider = new QSlider($this); $this->layout = new QVBoxLayout($this); $this->layout->addWidget($this->lcd); $this->layout->addWidget($this->slider); $this->setLayout($this->layout); } } /* LCD only */ class Test2 extends QWidget { public $lcd; public $layout; function __construct() { parent::__construct(); $this->lcd = new QLCDNumber(2,$this); $this->layout = new QVBoxLayout($this); $this->layout->addWidget($this->lcd); $this->setLayout($this->layout); } } /* Slider only */ class Test3 extends QWidget { public $slider; public $layout; function __construct() { parent::__construct(); $this->slider = new QSlider($this); $this->layout = new QVBoxLayout($this); $this->layout->addWidget($this->slider); $this->setLayout($this->layout); } } Test 1 OK: contains both slider and LCD and can be added to the grid. Test 2 CORE: contains the LCD only, adding it to the grid drops core. Test 3 OK: contains the slider only, can be added to the grid. $this->grid->addWidget(new Test3(), $row, $column, 0); Anyway, will it be possible to add single widgets, like in the example below? (Which will have no additional layout, just the widget itself.) To test QGridLayout I tried to change my little test program to use it, by adding Button or QLineEdit. Seems it works only with the Tutorial 6 class at the moment. ;-) Many thanks, Ferenc Ferenc Veres wrote: > Why tutoruial 6 stops working if I change the grid's internal control to > QLineEdit like this: > > $this->grid->addWidget(new QLineEdit("na", $this), $row, $column, 0); > > If "$this" is the problem, what do you advice to solve it? > > (I have similar problem with my program what I try to convert to use > QGridLayout, but that actually displays all controls in the top left > corner, no segfault.) > > Thanks, > Ferenc > _______________________________________________ |
From: Thomas M. <tm...@ip...> - 2006-01-17 09:58:58
|
=46erenc Veres wrote on Dienstag, 17. Januar 2006 02:12: > Then what is the input encoding? If UTF-8 input just works? Ok, I try > with ISO-8859-1. > > $QString =3D new QString("hell=C3=B3"); > > written in Latin1 prints broken characters to the output. So is the > input encoding UTF-8 for "char*"? I just don't get it. Ok, so UTF-8 is > the default input encoding for "char*". Is that right? Trolls wrote: "Constructs a string initialized with the ASCII string str." And next "str is converted to Unicode using fromAscii()." > My test is proves of nothing. See: > > I input Latin1 chars and output to UTF-8 terminal. I got broken > characters. So this may still mean, that "string travels as binary > entity", or that "wrong input returns wrong output". While entering > UTF-8 text looked fine, that proves either "string travels as binary > entity" or "correct input printed correct output". > > The only proof is when these letters are correctly displayed on the GUI! > (As far as I see now.) Lets finish QString and test all functions there. All I have seen in php=20 internals stores strings binary. Maybe, we have luck. > Yes, I am glad to see that Qt has so advanced features for handling > encodings. Note, that "toAscii()" will probably lose some characters, > e.g. in Japanese it will lose most of them. :-) I hope that won't be a > requirement. We will see. There are toAscii() toLatin1 toUtf8 =2E.. One of these I can use for the magically __toString() method. =2D-=20 Thomas |
From: Ferenc V. <li...@ne...> - 2006-01-17 01:14:31
|
Oh, seems the berlios list is still up and running! I forward to sf, just in case! :-) Sorry for sending twice to some readers! -------- Original Message -------- Subject: [Php-qt-users] QGridLayout Date: Tue, 17 Jan 2006 01:45:31 +0100 From: Ferenc Veres <li...@ne...> To: php...@li... Hi, And last a little QGridLayout question. Why tutoruial 6 stops working if I change the grid's internal control to QLineEdit like this: $this->grid->addWidget(new QLineEdit("na", $this), $row, $column, 0); If "$this" is the problem, what do you advice to solve it? (I have similar problem with my program what I try to convert to use QGridLayout, but that actually displays all controls in the top left corner, no segfault.) Thanks, Ferenc _______________________________________________ Php-qt-users mailing list Php...@li... http://lists.berlios.de/mailman/listinfo/php-qt-users |
From: Ferenc V. <li...@ne...> - 2006-01-17 01:12:34
|
Hi, Thomas Moenicke wrote: >=20 >>QString ( const char * str ) <- looks to be this one now >=20 > Exactly. And=20 > QString ( QChar ch ) > works too. But remember that a char is a number,"a" is a string instead= . So=20 > you have to use use > $mystring =3D new QString(65); I tried that with 337, but that also returned a normal ASCII char. :-) 337 -> Q 338 -> R 0x337 -> 7 So these are not unicode code points. Mabye just mod-128 ASCII values. Actually: QChar () QChar ( char ch ) <-- this is implemented seeing the tests. QChar ( uchar ch ) QChar ( QLatin1Char ch ) QChar ( uchar cell, uchar row ) QChar ( ushort code ) QChar ( short code ) QChar ( uint code ) QChar ( int code ) QChar ( SpecialCharacter ch ) Half of those works with ASCII code, other half unicode code points. :-) > Normally it is possible to provide all constructors, but the others are= still=20 > broken in the current version. Next time I will fire up an improved kal= yptus=20 > script again to solve it. That's great! >>So it looks like the string is just travelling in binary format. (?) >=20 >=20 > The string is stored in the QString object. The zend engine passes it f= rom=20 > your code to the object. In your tests you have proven that it works. Then what is the input encoding? If UTF-8 input just works? Ok, I try with ISO-8859-1. $QString =3D new QString("hell=C3=B3"); written in Latin1 prints broken characters to the output. So is the input encoding UTF-8 for "char*"? I just don't get it. Ok, so UTF-8 is the default input encoding for "char*". Is that right? My test is proves of nothing. See: I input Latin1 chars and output to UTF-8 terminal. I got broken characters. So this may still mean, that "string travels as binary entity", or that "wrong input returns wrong output". While entering UTF-8 text looked fine, that proves either "string travels as binary entity" or "correct input printed correct output". The only proof is when these letters are correctly displayed on the GUI! (As far as I see now.) >>$text =3D QString::fromUtf8($my_database_fetched_variable); // static m= . >>$myLineEdit->setText($text); // (Passing QString there drops core.) >=20 >=20 > The fromUtf8 function does not work for me, I got segfaults. Yes, sorry, that was only a quetion if that would be the right method or not. I mean later. > What is with this piece of code: > $text =3D new QString($my_database_fetched_variable); > $myLineEdit->setText($text); Segfault. :-/ > Note, what we are doing is experimental and the php guys are working on= the=20 > same problems with other tools. I read some of Andrei's implementations= in=20 > php6 and they implemented a function which copies unicode strings to no= rmal=20 > php strings. For php_qt this should be done by Qt's QString::toAscii(),= I=20 > passed the resulting bytearray to a string directly. Yes, I am glad to see that Qt has so advanced features for handling encodings. Note, that "toAscii()" will probably lose some characters, e.g. in Japanese it will lose most of them. :-) I hope that won't be a requirement. Ferenc |
From: Thomas M. <tm...@ip...> - 2006-01-17 00:15:07
|
=46erenc Veres wrote on Dienstag, 17. Januar 2006 00:29: > While seeing your examples, I cannot see how it will work with > non-English strings. E.g. since PHP can implement only one of the 8 > constructors, which one will it be? Or will use use "is_a()" to > implement more? Sounds very difficult. > QString ( const char * str ) <- looks to be this one now Exactly. And=20 QString ( QChar ch ) works too. But remember that a char is a number,"a" is a string instead. So= =20 you have to use use $mystring =3D new QString(65); Normally it is possible to provide all constructors, but the others are sti= ll=20 broken in the current version. Next time I will fire up an improved kalyptu= s=20 script again to solve it. > Seeing from the "test/unicode.php": > > $QString =3D new QString("hello"); > > I really don't know. If I upload the object with "h=C3=A1llo" instead, it > still prints the string back, I use KWrite in "UTF-8" mode for the test. it should print "h=C3=A1llo" to console. > Even the non-latin 1 "=C5=91" character works right! And both "toUtf8" and > simple "echo" prints the characters right. (I use a Konsole configured > for UTF-8.) (I tested with strings from the database too, same result.) =46ine. > So it looks like the string is just travelling in binary format. (?) The string is stored in the QString object. The zend engine passes it from= =20 your code to the object. In your tests you have proven that it works. > There is no such thing as "plain text"! :-) Do you remember my old > screenshot with broken utf-8 text: http://www.wpsnet.hu/~lion/gui.png ? > I think that could be fixed only with QString, something like: > > $text =3D QString::fromUtf8($my_database_fetched_variable); // static m. > $myLineEdit->setText($text); // (Passing QString there drops core.) The fromUtf8 function does not work for me, I got segfaults. What is with this piece of code: $text =3D new QString($my_database_fetched_variable); $myLineEdit->setText($text); Note, what we are doing is experimental and the php guys are working on the= =20 same problems with other tools. I read some of Andrei's implementations in= =20 php6 and they implemented a function which copies unicode strings to normal= =20 php strings. For php_qt this should be done by Qt's QString::toAscii(), I=20 passed the resulting bytearray to a string directly. =2D-=20 Thomas |
From: Ferenc V. <li...@ne...> - 2006-01-16 23:53:08
|
Hi, Please see: public $lblOriginal; ... $this->lblOriginal = new QLabel($this); $this->lblOriginal->setText(new QString("Hello")); Displays: Fatal error: PHP_QT: setText(): hash not found. (Same if I create the QString in a $txt first.) Thanks, Ferenc ps: I hope it's not a typo in my test... |
From: Ferenc V. <li...@ne...> - 2006-01-16 23:29:22
|
Hi! >> Does not work: >> $this->txtGuessPercents[$i]->$text =3D $tr["percent"]."%"; >> >> Error message: "Cannot access empty property". According to the Qt Well, actually that should be ->text, which dumps core, instead that error message. :-) > This is not possible. PHP-properties are provided as you can see in Ok, I did not even remember that C++ can do actions when setting a property! (Been too long time ago.) PHP could do that only via __set(), but maybe that would be too much overload. (Both to php_qt developers and CPU. :-) ) Reasonable. The only problem I could see, is that sometimes setting the property and using the access method has different effects on various checks and signals in Qt4. I don't know if that will cause problems, of course PHP programmers must take extra care of these changes, that's all. I am not sure about that, just browsing QLineEdit docs and thinking... > I improved the QString class and toUtf8() works fine. But I get too muc= h=20 > segfaults with other functions so I have to spend more time to it. > You can put any QString class object to php's echo or print methods, pl= ease=20 > consider test/qstring.php and test/unicode.php. Thanks you! :-) First a little note: $txt =3D new QString(""); $txt->toUtf8(); segfaults. While seeing your examples, I cannot see how it will work with non-English strings. E.g. since PHP can implement only one of the 8 constructors, which one will it be? Or will use use "is_a()" to implement more? Sounds very difficult. QString () QString ( const QChar * unicode, int size ) QString ( QChar ch ) QString ( int size, QChar ch ) QString ( const QLatin1String & str ) QString ( const QString & other ) QString ( const char * str ) <- looks to be this one now QString ( const QByteArray & ba ) Seeing from the "test/unicode.php": $QString =3D new QString("hello"); I really don't know. If I upload the object with "h=C3=A1llo" instead, it still prints the string back, I use KWrite in "UTF-8" mode for the test. Even the non-latin 1 "=C5=91" character works right! And both "toUtf8" an= d simple "echo" prints the characters right. (I use a Konsole configured for UTF-8.) (I tested with strings from the database too, same result.) So it looks like the string is just travelling in binary format. (?) There is no such thing as "plain text"! :-) Do you remember my old screenshot with broken utf-8 text: http://www.wpsnet.hu/~lion/gui.png ? I think that could be fixed only with QString, something like: $text =3D QString::fromUtf8($my_database_fetched_variable); // static m. $myLineEdit->setText($text); // (Passing QString there drops core.) Ok, I stop testing CHARS for now, and leave you with your original schedule, just please, take a note on charset support. ;-) Thanks, Ferenc |
From: Thomas M. <tm...@ip...> - 2006-01-16 17:17:00
|
Ferenc Veres wrote on Montag, 16. Januar 2006 01:41: > 2. QString character code conversions > > I think these routines are not ready yet, it would be great to have them > as time allows. As you could saw on my tests, all localized strings were > displayed broken. > > ::toUtf8 > ::fromUtf8 > > and similar functions. I improved the QString class and toUtf8() works fine. But I get too much segfaults with other functions so I have to spend more time to it. You can put any QString class object to php's echo or print methods, please consider test/qstring.php and test/unicode.php. -- Thomas |
From: Thomas M. <tm...@ip...> - 2006-01-16 11:37:41
|
Ferenc Veres wrote on Montag, 16. Januar 2006 01:41: > Works: > $this->txtGuessPercents[$i]->setText($tr["percent"]."%"); > > Does not work: > $this->txtGuessPercents[$i]->$text = $tr["percent"]."%"; > > Error message: "Cannot access empty property". According to the Qt docs > there is a .text property, but I don't understand the ZEND code in > qlineedit.cpp to see what it can do. :-) This is not possible. PHP-properties are provided as you can see in a few classes. You can readout it, but not write to it directly. It may be possible to store your values into the php object, but property is a passive element and cannot forward its value to the real C++ object. You have to use the setText() way to store the value instead. > 2. QString character code conversions > > I think these routines are not ready yet, it would be great to have them > as time allows. As you could saw on my tests, all localized strings were > displayed broken. > > ::toUtf8 > ::fromUtf8 > > and similar functions. > > I don't have any utf-16 strings, so all I can do with QString is dumping > core files. :-) > > $txt = new QString("Hello"); > $this->txtGuessTranslations[$i]->setText($txt); > > Something like that? (Dumps core at the moment, in the second line.) > That would probably require QString's static ::fromUtf8 or ::fromAscii > methods, becase "Hello" written in source code is not Unicode. > > Anyway, I am not sure my code handles the UTF-8 strings right, I did > nothing more than adding the encoding to the originating XML's header > and creating MySQL tables with UTF-8 setting. I did nothing in PHP > direcly. (I don't have such strings in the source code of course.) > > When I fill those UTF-8 strings to the QLineEdit, they display as "UTF-8 > binary". I write it to the TODO list. It seems to be a little bit tricky, I hope we do not have to touch the zend engine ;-) -- Thomas _______________________________________________ Php-qt-users mailing list Php...@li... http://lists.berlios.de/mailman/listinfo/php-qt-users |
From: Ferenc V. <li...@ne...> - 2006-01-16 10:11:04
|
Hi all, I've two small questions. 1. QLineEdit->$text (with plain ascii text first) Works: $this->txtGuessPercents[$i]->setText($tr["percent"]."%"); Does not work: $this->txtGuessPercents[$i]->$text = $tr["percent"]."%"; Error message: "Cannot access empty property". According to the Qt docs there is a .text property, but I don't understand the ZEND code in qlineedit.cpp to see what it can do. :-) 2. QString character code conversions I think these routines are not ready yet, it would be great to have them as time allows. As you could saw on my tests, all localized strings were displayed broken. ::toUtf8 ::fromUtf8 and similar functions. I don't have any utf-16 strings, so all I can do with QString is dumping core files. :-) $txt = new QString("Hello"); $this->txtGuessTranslations[$i]->setText($txt); Something like that? (Dumps core at the moment, in the second line.) That would probably require QString's static ::fromUtf8 or ::fromAscii methods, becase "Hello" written in source code is not Unicode. Anyway, I am not sure my code handles the UTF-8 strings right, I did nothing more than adding the encoding to the originating XML's header and creating MySQL tables with UTF-8 setting. I did nothing in PHP direcly. (I don't have such strings in the source code of course.) When I fill those UTF-8 strings to the QLineEdit, they display as "UTF-8 binary". Thanks, Ferenc _______________________________________________ Php-qt-users mailing list Php...@li... http://lists.berlios.de/mailman/listinfo/php-qt-users |
From: Thomas M. <tm...@ip...> - 2006-01-15 23:18:16
|
Ferenc Veres wrote on Montag, 16. Januar 2006 00:08: > Yes, I have notes of my old build line, but I remembered that some > things were changed, so I made a new one according to the README! :-D > > Thanks, the adjusted configure line worked and tutorial 6 runs well. I > will check what's new. :-) Ferenc, this are good news! I made tutorial 7 too, but it does not work correctly because it lacks custom widgets. But I work on it actually. And the README before I forget it ;-) -- Thomas |
From: Ferenc V. <li...@ne...> - 2006-01-15 23:08:16
|
Hi, Thomas Moenicke wrote: > zend_update_property_bool is implemented in Zend/zend_API.c and defined in > Zend/zend_API.h. > > For you, it should be here: /usr/include/php/Zend/zend_API.h > > Is it? /usr/local/php511/include/php/Zend/ It is there, probably it was not detected because I forgot the "--with-php-config" option! > In december you have used this command: > > ./configure --prefix=/usr/local/php511/ > --with-php-config=/usr/local/php511/bin/php-config > --with-qtlib=/usr/lib/qt4 --with-php_qt=/usr/lib/qt4/include > > Meanwhile I removed the --prefix argument because it is usual to use php's own > prefix specified at configuration and compilation of php. Yes, I have notes of my old build line, but I remembered that some things were changed, so I made a new one according to the README! :-D Thanks, the adjusted configure line worked and tutorial 6 runs well. I will check what's new. :-) Ferenc |
From: Thomas M. <tm...@ip...> - 2006-01-15 21:48:08
|
=46erenc Veres wrote on Sonntag, 15. Januar 2006 14:18: > Hi everyone, > > I must do the following command line to start it compiling: > > /usr/local/php511/bin/phpize Right. > ./configure --enable-php_qt --prefix=3D/usr/local/php511/ > --with-qtlib=3D/usr/lib/qt4/lib --with-php_qt=3D/usr/lib/qt4/include > make clean > make Ok, I should update the README file. We figured that out a few weeks before. > (I hope that --with-php_qt=3D/usr/lib/qt4/include is what you wanted, > because that's the only combination which creates the INCLUDES variable > right. Hopefully QT4 and PHP5.1.x will became standard installation soon > so we don't need any path tricks. :-) ) Yeah! We can dream :-) > Compiling fails with the error attached below, but probably I checked > out some unfinished changes. =2E.. > g++ -I. -I/home/lion/install/php-5.1.1/ext/php_qt -DPHP_ATOM_INC > -I/home/lion/install/php-5.1.1/ext/php_qt/include > -I/home/lion/install/php-5.1.1/ext/php_qt/main > -I/home/lion/install/php-5.1.1/ext/php_qt -I/usr/include/php > -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend > -I/usr/lib/qt4/include/include -I/usr/lib/qt4/include/QtGui > -I/usr/lib/qt4/include/QtCore -I/usr/lib/qt4/include -DHAVE_CONFIG_H -c > /home/lion/install/php-5.1.1/ext/php_qt/qt/abstract_widgets/qabstractbutt= on >.cpp -fPIC -DPIC -o qt/abstract_widgets/.libs/qabstractbutton.o > /home/lion/install/php-5.1.1/ext/php_qt/qt/abstract_widgets/qabstractbutt= on >.cpp: In function =E2=80=98void zif_QAbstractButton_setAutoExclusive(int, = zval*, > zval*, int)=E2=80=99: > /home/lion/install/php-5.1.1/ext/php_qt/qt/abstract_widgets/qabstractbutt= on >.cpp:40: error: =E2=80=98zend_update_property_bool=E2=80=99 was not declar= ed in this scope > /home/lion/install/php-5.1.1/ext/php_qt/qt/abstract_widgets/qabstractbutt= on >.cpp: In function =E2=80=98void zif_QAbstractButton_setAutoRepeat(int, zva= l*, zval*, > int)=E2=80=99: > /home/lion/install/php-5.1.1/ext/php_qt/qt/abstract_widgets/qabstractbutt= on >.cpp:41: error: =E2=80=98zend_update_property_bool=E2=80=99 was not declar= ed in this scope > /home/lion/install/php-5.1.1/ext/php_qt/qt/abstract_widgets/qabstractbutt= on >.cpp: In function =E2=80=98void zif_QAbstractButton_setCheckable(int, zval= *, zval*, > int)=E2=80=99: > /home/lion/install/php-5.1.1/ext/php_qt/qt/abstract_widgets/qabstractbutt= on >.cpp:42: error: =E2=80=98zend_update_property_bool=E2=80=99 was not declar= ed in this scope > /home/lion/install/php-5.1.1/ext/php_qt/qt/abstract_widgets/qabstractbutt= on >.cpp: In function =E2=80=98void zif_QAbstractButton_setDown(int, zval*, zv= al*, > int)=E2=80=99: > /home/lion/install/php-5.1.1/ext/php_qt/qt/abstract_widgets/qabstractbutt= on >.cpp:43: error: =E2=80=98zend_update_property_bool=E2=80=99 was not declar= ed in this scope > make: *** [qt/abstract_widgets/qabstractbutton.lo] Error 1 > zend_update_property_bool is implemented in Zend/zend_API.c and defined in= =20 Zend/zend_API.h. =46or you, it should be here: /usr/include/php/Zend/zend_API.h Is it? In december you have used this command: =2E/configure --prefix=3D/usr/local/php511/ =2D-with-php-config=3D/usr/local/php511/bin/php-config =2D-with-qtlib=3D/usr/lib/qt4 --with-php_qt=3D/usr/lib/qt4/include Meanwhile I removed the --prefix argument because it is usual to use php's = own=20 prefix specified at configuration and compilation of php. =2D-=20 Thomas |
From: Ferenc V. <li...@ne...> - 2006-01-15 21:18:21
|
Hi everyone, I must do the following command line to start it compiling: /usr/local/php511/bin/phpize ./configure --enable-php_qt --prefix=3D/usr/local/php511/ --with-qtlib=3D/usr/lib/qt4/lib --with-php_qt=3D/usr/lib/qt4/include make clean make (I hope that --with-php_qt=3D/usr/lib/qt4/include is what you wanted, because that's the only combination which creates the INCLUDES variable right. Hopefully QT4 and PHP5.1.x will became standard installation soon so we don't need any path tricks. :-) ) Compiling fails with the error attached below, but probably I checked out some unfinished changes. Ferenc g++ -I. -I/home/lion/install/php-5.1.1/ext/php_qt -DPHP_ATOM_INC -I/home/lion/install/php-5.1.1/ext/php_qt/include -I/home/lion/install/php-5.1.1/ext/php_qt/main -I/home/lion/install/php-5.1.1/ext/php_qt -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/lib/qt4/include/include -I/usr/lib/qt4/include/QtGui -I/usr/lib/qt4/include/QtCore -I/usr/lib/qt4/include -DHAVE_CONFIG_H -c /home/lion/install/php-5.1.1/ext/php_qt/qt/abstract_widgets/qabstractbutt= on.cpp -fPIC -DPIC -o qt/abstract_widgets/.libs/qabstractbutton.o /home/lion/install/php-5.1.1/ext/php_qt/qt/abstract_widgets/qabstractbutt= on.cpp: In function =E2=80=98void zif_QAbstractButton_setAutoExclusive(int, zval*= , zval*, int)=E2=80=99: /home/lion/install/php-5.1.1/ext/php_qt/qt/abstract_widgets/qabstractbutt= on.cpp:40: error: =E2=80=98zend_update_property_bool=E2=80=99 was not declared in th= is scope /home/lion/install/php-5.1.1/ext/php_qt/qt/abstract_widgets/qabstractbutt= on.cpp: In function =E2=80=98void zif_QAbstractButton_setAutoRepeat(int, zval*, z= val*, int)=E2=80=99: /home/lion/install/php-5.1.1/ext/php_qt/qt/abstract_widgets/qabstractbutt= on.cpp:41: error: =E2=80=98zend_update_property_bool=E2=80=99 was not declared in th= is scope /home/lion/install/php-5.1.1/ext/php_qt/qt/abstract_widgets/qabstractbutt= on.cpp: In function =E2=80=98void zif_QAbstractButton_setCheckable(int, zval*, zv= al*, int)=E2=80=99: /home/lion/install/php-5.1.1/ext/php_qt/qt/abstract_widgets/qabstractbutt= on.cpp:42: error: =E2=80=98zend_update_property_bool=E2=80=99 was not declared in th= is scope /home/lion/install/php-5.1.1/ext/php_qt/qt/abstract_widgets/qabstractbutt= on.cpp: In function =E2=80=98void zif_QAbstractButton_setDown(int, zval*, zval*, = int)=E2=80=99: /home/lion/install/php-5.1.1/ext/php_qt/qt/abstract_widgets/qabstractbutt= on.cpp:43: error: =E2=80=98zend_update_property_bool=E2=80=99 was not declared in th= is scope make: *** [qt/abstract_widgets/qabstractbutton.lo] Error 1 |
From: Thomas M. <tm...@ip...> - 2006-01-15 18:30:44
|
Hi, I added the 6th tutorial to the svn repository. A lot of new classes were added, they are most complete. You can help testing if you want. qactionevent.cpp qdatetime.cpp qfocusevent.cpp qinputevent.cpp qobjectdata.cpp qstatustipevent.cpp qwidgetdata.cpp qchar.cpp qdragenterevent.cpp qfont.cpp qinputmethodevent.cpp qobjectuserdata.cpp qtabletevent.cpp qwidgetitem.cpp qcharref.cpp qdragleaveevent.cpp qgridlayout.cpp qkeyevent.cpp qpainter.cpp qtime.cpp qwindowstatechangeevent.cpp qclipboardevent.cpp qdragmoveevent.cpp qhelpevent.cpp qlabel.cpp qpaintevent.cpp qtimer.cpp qcloseevent.cpp qdragresponseevent.cpp qhideevent.cpp qlatin1char.cpp qresizeevent.cpp qtoolbarchangeevent.cpp qcontextmenuevent.cpp qdropevent.cpp qhoverevent.cpp qmouseevent.cpp qshortcutevent.cpp qwhatsthisclickedevent.cpp qdate.cpp qfileopenevent.cpp qicondragevent.cpp qmoveevent.cpp qshowevent.cpp qwheelevent.cpp -- Thomas |
From: Thomas M. <tm...@ip...> - 2006-01-06 18:50:37
|
Hi Piotr, you wrote: > .../trunk/qt/abstract_widgets/qwidget.cpp: In function `void > zif_QWidget_setAccessibleDescription(int, zval*, zval**, zval*, int)': > .../trunk/qt/abstract_widgets/qwidget.cpp:164: error: 'class QWidget' > has no member named 'setAccessibleDescription' > .../trunk/qt/abstract_widgets/qwidget.cpp: In function `void > zif_QWidget_setAccessibleName(int, zval*, zval**, zval*, int)': > .../trunk/qt/abstract_widgets/qwidget.cpp:176: error: 'class QWidget' > has no member named 'setAccessibleName' in src/gui/kernel/qwidget.h, line 174: #ifndef QT_NO_ACCESSIBILITY Q_PROPERTY(QString accessibleName READ accessibleName WRITE setAccessibleName) Q_PROPERTY(QString accessibleDescription READ accessibleDescription WRITE setAccessibleDescription) it seems that you haven't set the QT_NO_ACCESSIBILITY flag. -- Thomas |
From: Thomas M. <tm...@ip...> - 2006-01-06 18:42:25
|
I removed the --with-prefix parameter. It is equivalent with php's --prefix parameter which should works in the same way. I hope there are no problems. -- Thomas |
From: Thomas M. <tm...@ip...> - 2006-01-06 17:23:02
|
piotr mali=F1ski wrote on Freitag, 6. Januar 2006 08:44: > I have php-5.1.1, QT 4.1.0 and todays /trunk from SVN and I still > can't compile php-qt. I get an error: > /home/plusiaczek/nowe/trunk/qt/abstract_widgets/qwidget.cpp:163: > warning: casting `QString*' to `const QString&' does not dereference > pointer Please try this patch and tell me if it works. =2D-=20 Thomas |
From: Thomas M. <tm...@ip...> - 2006-01-06 14:46:22
|
piotr mali=F1ski wrote on Freitag, 6. Januar 2006 08:44: > I have php-5.1.1, QT 4.1.0 and todays /trunk from SVN and I still > can't compile php-qt. I get an error: > /home/plusiaczek/nowe/trunk/qt/abstract_widgets/qwidget.cpp:163: > warning: casting `QString*' to `const QString&' does not dereference > pointer Please try this patch and tell me if it works. =2D-=20 Thomas |