Re: error compiling qt frontend

2002-07-30 Thread Kuba Ober
On poniedziałek 29 lipiec 2002 10:15 am, Lars Gullik Bjønnes wrote: > Kuba Ober <[EMAIL PROTECTED]> writes: > | On środa 24 lipiec 2002 04:10 am, Angus Leeming wrote: > >> On Wednesday 24 July 2002 7:25 am, Lars Gullik Bjønnes wrote: > >> > Just make sure that QString::data is required to

Re: error compiling qt frontend

2002-07-29 Thread John Levon
On Mon, Jul 29, 2002 at 04:31:00PM +0200, Andre Poenitz wrote: > >From what was being said I assumed that one has to copy the content. > That might be wrong, but then, who owns the 'char *' returned by latin1() > and if it is the QString, what happens if it gets destroyed? The first thing I do w

Re: error compiling qt frontend

2002-07-29 Thread Andre Poenitz
On Mon, Jul 29, 2002 at 04:24:21PM +0200, Lars Gullik Bjønnes wrote: > | And why don't you use > > > | std::string mystr = selectedFile().latin1(); > > That will work. > ... unless .latin1() can return NULL. Ah yes... I tend to forget these things... Andre' -- Those who desire to give up Fre

Re: error compiling qt frontend

2002-07-29 Thread Andre Poenitz
On Mon, Jul 29, 2002 at 03:22:19PM +0100, John Levon wrote: > > std::string mystr = selectedFile().latin1(); > > Why bother ? data() is just as good ... >From what was being said I assumed that one has to copy the content. That might be wrong, but then, who owns the 'char *' returned by latin1(

Re: error compiling qt frontend

2002-07-29 Thread Lars Gullik Bjønnes
Andre Poenitz <[EMAIL PROTECTED]> writes: | On Mon, Jul 29, 2002 at 10:02:23AM -0400, Kuba Ober wrote: >> It does return a null terminated char const *, although please notice that >> this pointer may point to garbage on any subsequent line of your code, if the >> source QString was destroyed.

Re: error compiling qt frontend

2002-07-29 Thread John Levon
On Mon, Jul 29, 2002 at 04:13:48PM +0200, Andre Poenitz wrote: > std::string mystr = selectedFile().latin1(); Why bother ? data() is just as good ... john -- "The simpler it is, the harder it is." - Tim Van Holder

Re: error compiling qt frontend

2002-07-29 Thread Lars Gullik Bjønnes
Kuba Ober <[EMAIL PROTECTED]> writes: | On środa 24 lipiec 2002 04:10 am, Angus Leeming wrote: >> On Wednesday 24 July 2002 7:25 am, Lars Gullik Bjønnes wrote: >> > Just make sure that QString::data is required to retrun a >> > null-terminated char const *. >> >> const char* data() const { retu

Re: error compiling qt frontend

2002-07-29 Thread Andre Poenitz
On Mon, Jul 29, 2002 at 10:02:23AM -0400, Kuba Ober wrote: > It does return a null terminated char const *, although please notice that > this pointer may point to garbage on any subsequent line of your code, if the > source QString was destroyed. > > Thus, I'd always do this (unless I'm the on

Re: error compiling qt frontend

2002-07-29 Thread John Levon
On Mon, Jul 29, 2002 at 10:02:23AM -0400, Kuba Ober wrote: > char mybuf[512]; not necessary regards john -- "The simpler it is, the harder it is." - Tim Van Holder

Re: error compiling qt frontend

2002-07-29 Thread Kuba Ober
On środa 24 lipiec 2002 04:10 am, Angus Leeming wrote: > On Wednesday 24 July 2002 7:25 am, Lars Gullik Bjønnes wrote: > > Just make sure that QString::data is required to retrun a > > null-terminated char const *. > > const char* data() const { return latin1(); } > > I don't have the Qt src to

Re: error compiling qt frontend

2002-07-24 Thread Angus Leeming
On Wednesday 24 July 2002 7:25 am, Lars Gullik Bjønnes wrote: > Just make sure that QString::data is required to retrun a > null-terminated char const *. const char* data() const { return latin1(); } I don't have the Qt src to hand so can't dig any further. Angus

Re: error compiling qt frontend

2002-07-24 Thread Lars Gullik Bjønnes
Angus Leeming <[EMAIL PROTECTED]> writes: | On Wednesday 24 July 2002 6:56 am, Lars Gullik Bjønnes wrote: | > John Levon <[EMAIL PROTECTED]> writes: | > | On Tue, Jul 23, 2002 at 07:30:54PM +0100, Angus Leeming wrote: | > | > argument types are: (kb_action, const char *) | > | >

Re: error compiling qt frontend

2002-07-24 Thread Angus Leeming
On Wednesday 24 July 2002 6:56 am, Lars Gullik Bjønnes wrote: > John Levon <[EMAIL PROTECTED]> writes: > | On Tue, Jul 23, 2002 at 07:30:54PM +0100, Angus Leeming wrote: > | > argument types are: (kb_action, const char *) > | > lv_->getLyXFunc()->dispatch(action_, > | >

Re: error compiling qt frontend

2002-07-24 Thread Lars Gullik Bjønnes
John Levon <[EMAIL PROTECTED]> writes: | On Tue, Jul 23, 2002 at 07:30:54PM +0100, Angus Leeming wrote: | | > argument types are: (kb_action, const char *) | > lv_->getLyXFunc()->dispatch(action_, selectedFile().data()); | | lv_->getLyXFunc()->dispatch(action_, selec

Re: error compiling qt frontend

2002-07-23 Thread John Levon
On Tue, Jul 23, 2002 at 09:22:42PM +0200, Herbert Voss wrote: > what have I to do when I want the qt-frontend compiled? Well I wouldn't start from here .. make distclean export QTDIR=/path/to/qt ./configure --with-frontend=qt2 make (use automake 1.5) regards john -- "If you cannot convince

Re: error compiling qt frontend

2002-07-23 Thread Angus Leeming
On Tuesday 23 July 2002 8:22 pm, Herbert Voss wrote: > Angus Leeming wrote: > > On Tuesday 23 July 2002 8:05 pm, John Levon wrote: > >>lv_->getLyXFunc()->dispatch(action_, selectedFile().data(), false); > > what have I to do when I want the qt-frontend compiled? touch frontends/*.C configure --wi

Re: error compiling qt frontend

2002-07-23 Thread Herbert Voss
Angus Leeming wrote: > On Tuesday 23 July 2002 8:05 pm, John Levon wrote: > >>lv_->getLyXFunc()->dispatch(action_, selectedFile().data(), false); what have I to do when I want the qt-frontend compiled? Herbert -- http://www.lyx.org/help/

Re: error compiling qt frontend

2002-07-23 Thread Angus Leeming
On Tuesday 23 July 2002 8:05 pm, John Levon wrote: > lv_->getLyXFunc()->dispatch(action_, selectedFile().data(), false); ta!

Re: error compiling qt frontend

2002-07-23 Thread John Levon
On Tue, Jul 23, 2002 at 07:30:54PM +0100, Angus Leeming wrote: > argument types are: (kb_action, const char *) > lv_->getLyXFunc()->dispatch(action_, selectedFile().data()); lv_->getLyXFunc()->dispatch(action_, selectedFile().data(), false); regards john -- "If you

error compiling qt frontend

2002-07-23 Thread Angus Leeming
cxx: Error: ../../../../devel/src/frontends/qt2/FileDialog_private.C, line 37: #308 more than one instance of overloaded function "LyXFunc::dispatch" matches the argument list: function "LyXFunc::dispatch(kb_action, std::string, bool)" function "LyXFunc