Re: LyX Window placed in the upper left corner

2006-06-20 Thread Peter Kümmel
now i've also implemented the qt3 stuff. see ' Qt4 frontend save/restore geoemtry patch' thread

Re: LyX Window placed in the upper left corner

2006-06-18 Thread Enrico Forestieri
On Sun, Jun 18, 2006 at 05:25:00PM +0200, Peter Kümmel wrote: > Enrico Forestieri wrote: > > On Sun, Jun 18, 2006 at 11:09:50AM +0200, Peter Kümmel wrote: > > > >> Enrico Forestieri wrote: > >>> On Sat, Jun 17, 2006 at 11:50:11AM +0200, Peter Kümmel wrote: > >>> > Enrico Forestieri wrote: >

Re: LyX Window placed in the upper left corner

2006-06-18 Thread Peter Kümmel
Enrico Forestieri wrote: > On Sun, Jun 18, 2006 at 11:09:50AM +0200, Peter Kümmel wrote: > >> Enrico Forestieri wrote: >>> On Sat, Jun 17, 2006 at 11:50:11AM +0200, Peter Kümmel wrote: >>> Enrico Forestieri wrote: > On Fri, Jun 16, 2006 at 12:31:55PM +0200, Peter Kümmel wrote: > >

Re: LyX Window placed in the upper left corner

2006-06-18 Thread Enrico Forestieri
On Sun, Jun 18, 2006 at 11:09:50AM +0200, Peter Kümmel wrote: > Enrico Forestieri wrote: > > On Sat, Jun 17, 2006 at 11:50:11AM +0200, Peter Kümmel wrote: > > > >> Enrico Forestieri wrote: > >>> On Fri, Jun 16, 2006 at 12:31:55PM +0200, Peter Kümmel wrote: > >>> > Ok, now setMainWidget is th

Re: LyX Window placed in the upper left corner

2006-06-18 Thread Peter Kümmel
Enrico Forestieri wrote: > On Sat, Jun 17, 2006 at 11:50:11AM +0200, Peter Kümmel wrote: > >> Enrico Forestieri wrote: >>> On Fri, Jun 16, 2006 at 12:31:55PM +0200, Peter Kümmel wrote: >>> Ok, now setMainWidget is the last call which could change the geometry. I could not test Qt3 lyx. >

Re: LyX Window placed in the upper left corner

2006-06-17 Thread Enrico Forestieri
On Sat, Jun 17, 2006 at 11:50:11AM +0200, Peter Kümmel wrote: > Enrico Forestieri wrote: > > On Fri, Jun 16, 2006 at 12:31:55PM +0200, Peter Kümmel wrote: > > > >> Ok, now setMainWidget is the last call which could change the geometry. > >> I could not test Qt3 lyx. > > > > I am sorry, but with

Re: LyX Window placed in the upper left corner

2006-06-17 Thread Andre Poenitz
On Fri, Jun 16, 2006 at 10:38:40AM +0200, Peter Kümmel wrote: > Index: qt3/lyx_gui.C > === > --- qt3/lyx_gui.C (revision 14122) > +++ qt3/lyx_gui.C (working copy) > @@ -235,9 +235,12 @@ > view.init(); > >

Re: LyX Window placed in the upper left corner

2006-06-17 Thread Peter Kümmel
Enrico Forestieri wrote: > On Fri, Jun 16, 2006 at 12:31:55PM +0200, Peter Kümmel wrote: > >> Ok, now setMainWidget is the last call which could change the geometry. >> I could not test Qt3 lyx. > > I am sorry, but with this patch applied LyX segfaults when starting: This is the only idea I have

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Peter Kümmel
Peter Kümmel wrote: > > I only was interested in fixing a small bug. > > Now I see qt3 crashing because of the support of geometry and > the working Qt4 patches will not be accepted without further changes. > > Because I'm not willed to invest more time in such a small thing > I propose to undo

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Bo Peng
I only was interested in fixing a small bug. Now I see qt3 crashing because of the support of geometry and the working Qt4 patches will not be accepted without further changes. Because I'm not willed to invest more time in such a small thing I propose to undo all changes on this subject. Which

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Peter Kümmel
Bo Peng wrote: > On 6/16/06, Peter Kümmel <[EMAIL PROTECTED]> wrote: >> I've fixed the save/restore and -geometry problem for Qt4. >> Therefore I have to remember lyx if there was the geometry option, >> and I have to emulate the QWidget::normalGeometry() function. >> >> I've tested it with Linux a

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Peter Kümmel
Peter Kümmel wrote: >> out. I moved most common behaviors of all frontends to lyx_main.C, Sorry, I've thought you've done already something. >> hoping to result in simpler logic in the frontends. Now, things would >> be clearer if all geometry handling goes back to the frontends. >> >> At the v

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Bo Peng
> Have you forgotten to attach your patch? Do I have to attach a patch to express my opinion? Bo

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Peter Kümmel
Enrico Forestieri wrote: > On Fri, Jun 16, 2006 at 12:31:55PM +0200, Peter Kümmel wrote: > >> Ok, now setMainWidget is the last call which could change the geometry. >> I could not test Qt3 lyx. > > I am sorry, but with this patch applied LyX segfaults when starting: > Maybe because QtView::QtV

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Peter Kümmel
Bo Peng wrote: > On 6/16/06, Peter Kümmel <[EMAIL PROTECTED]> wrote: >> I've fixed the save/restore and -geometry problem for Qt4. >> Therefore I have to remember lyx if there was the geometry option, >> and I have to emulate the QWidget::normalGeometry() function. >> >> I've tested it with Linux a

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Peter Kümmel
Enrico Forestieri wrote: > On Fri, Jun 16, 2006 at 07:42:32PM +0200, Enrico Forestieri wrote: > >> On Fri, Jun 16, 2006 at 12:31:55PM +0200, Peter Kümmel wrote: >> >>> Ok, now setMainWidget is the last call which could change the geometry. >>> I could not test Qt3 lyx. >> I am sorry, but with this

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Enrico Forestieri
On Fri, Jun 16, 2006 at 07:42:32PM +0200, Enrico Forestieri wrote: > On Fri, Jun 16, 2006 at 12:31:55PM +0200, Peter Kümmel wrote: > > > Ok, now setMainWidget is the last call which could change the geometry. > > I could not test Qt3 lyx. > > I am sorry, but with this patch applied LyX segfaults

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Bo Peng
On 6/16/06, Peter Kümmel <[EMAIL PROTECTED]> wrote: I've fixed the save/restore and -geometry problem for Qt4. Therefore I have to remember lyx if there was the geometry option, and I have to emulate the QWidget::normalGeometry() function. I've tested it with Linux and Windows. I do not really

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Enrico Forestieri
On Fri, Jun 16, 2006 at 12:31:55PM +0200, Peter Kümmel wrote: > Ok, now setMainWidget is the last call which could change the geometry. > I could not test Qt3 lyx. I am sorry, but with this patch applied LyX segfaults when starting: $ ./src/lyx-qt.exe lyx: SIGSEGV signal caught Sorry, you have

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Peter Kümmel
I've fixed the save/restore and -geometry problem for Qt4. Therefore I have to remember lyx if there was the geometry option, and I have to emulate the QWidget::normalGeometry() function. I've tested it with Linux and Windows. Index: frontends/qt4/lyx_gui.C ===

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Peter Kümmel
Georg Baum wrote: > Peter Kümmel wrote: > >> The original lyx/Qt3 logic was: >> 1. create QtView in start >> 2. in the QtView ctor: resize and setMainWidget, >>thus geometry option is applied if there is any >> 3. back in start check if (posx != -1 && posy != -1) >>is true if yes move widg

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Michael Gerz
Peter Kümmel wrote: Do you use the Qt3 or Qt4 version? With the Qt4 version I don't have this problem. I use qt 4.1.3, mingw, Win XP. Michael

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Georg Baum
Peter Kümmel wrote: > The original lyx/Qt3 logic was: > 1. create QtView in start > 2. in the QtView ctor: resize and setMainWidget, >thus geometry option is applied if there is any > 3. back in start check if (posx != -1 && posy != -1) >is true if yes move widget >(init() does not cal

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Peter Kümmel
Edwin Leuven wrote: > do we need to setGeometry when maximizing?: Yes, we need it because when you normalize the window you need a position and size.

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Peter Kümmel
Angus Leeming wrote: > Peter_Kümmel wrote: >> I prefer to handle all the geometry stuff >> in start so please try the attached patch > > Just move > qApp->setMainWidget(&view); > out of the if-block... (No need for the "else" then.) > > Angus > > Index: qt3/lyx_gui.C >

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Edwin Leuven
Peter Kümmel wrote: if (posx != -1 && posy != -1) { + qApp->setMainWidget(&view); view.setGeometry(posx, posy, width, height); if (maximize) view.setWindowState(Qt::WindowMaximized); + } else { + qAp

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Angus Leeming
Peter_Kümmel wrote: > I prefer to handle all the geometry stuff > in start so please try the attached patch Just move qApp->setMainWidget(&view); out of the if-block... (No need for the "else" then.) Angus Index: qt3/lyx_gui.C =

Re: LyX Window placed in the upper left corner

2006-06-16 Thread Peter Kümmel
Georg Baum wrote: > Am Donnerstag, 15. Juni 2006 17:44 schrieb Enrico Forestieri: >> On Thu, Jun 15, 2006 at 05:30:40PM +0200, Peter Kümmel wrote: >>> Does this patch help? >> Yes, -geometry works again. Thanks :) > > But the logic does not seem to be correct: If you have stored geometry > values

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Enrico Forestieri
On Thu, Jun 15, 2006 at 06:08:19PM +0200, Peter Kümmel wrote: > I must leave now, please add > resize(width, height); > in the else part, this should restore the old behavior. Yes, but then -geometry stops working again. -- Enrico

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Enrico Forestieri
On Thu, Jun 15, 2006 at 06:07:27PM +0200, Georg Baum wrote: > Am Donnerstag, 15. Juni 2006 17:44 schrieb Enrico Forestieri: > > On Thu, Jun 15, 2006 at 05:30:40PM +0200, Peter Kümmel wrote: > > > Does this patch help? > > > > Yes, -geometry works again. Thanks :) > > But the logic does not seem t

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Georg Baum
Am Donnerstag, 15. Juni 2006 17:44 schrieb Enrico Forestieri: > On Thu, Jun 15, 2006 at 05:30:40PM +0200, Peter Kümmel wrote: > > Does this patch help? > > Yes, -geometry works again. Thanks :) But the logic does not seem to be correct: If you have stored geometry values and a -geometry switch,

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Peter Kümmel
Peter Kümmel wrote: > Enrico Forestieri wrote: >> On Thu, Jun 15, 2006 at 05:44:19PM +0200, Enrico Forestieri wrote: >>> On Thu, Jun 15, 2006 at 05:30:40PM +0200, Peter Kümmel wrote: Enrico Forestieri wrote: > On Thu, Jun 15, 2006 at 09:30:00AM -0500, Bo Peng wrote: >>> BTW, I see that

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Peter Kümmel
Enrico Forestieri wrote: > On Thu, Jun 15, 2006 at 05:44:19PM +0200, Enrico Forestieri wrote: >> On Thu, Jun 15, 2006 at 05:30:40PM +0200, Peter Kümmel wrote: >>> Enrico Forestieri wrote: On Thu, Jun 15, 2006 at 09:30:00AM -0500, Bo Peng wrote: >> BTW, I see that no \screen_geometry_* vari

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Enrico Forestieri
On Thu, Jun 15, 2006 at 05:44:19PM +0200, Enrico Forestieri wrote: > On Thu, Jun 15, 2006 at 05:30:40PM +0200, Peter Kümmel wrote: > > Enrico Forestieri wrote: > > > On Thu, Jun 15, 2006 at 09:30:00AM -0500, Bo Peng wrote: > > >>> BTW, I see that no \screen_geometry_* variables are ever written to

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Enrico Forestieri
On Thu, Jun 15, 2006 at 05:30:40PM +0200, Peter Kümmel wrote: > Enrico Forestieri wrote: > > On Thu, Jun 15, 2006 at 09:30:00AM -0500, Bo Peng wrote: > >>> BTW, I see that no \screen_geometry_* variables are ever written to > >>> preferences, at least with qt3. > >> Time... I plan(ned) to add xysav

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Peter Kümmel
Enrico Forestieri wrote: > On Thu, Jun 15, 2006 at 09:30:00AM -0500, Bo Peng wrote: >>> BTW, I see that no \screen_geometry_* variables are ever written to >>> preferences, at least with qt3. >> Time... I plan(ned) to add xysaved, and fixed height/width to the >> preference dialog. > > I really do

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Enrico Forestieri
On Thu, Jun 15, 2006 at 09:30:00AM -0500, Bo Peng wrote: > > > >BTW, I see that no \screen_geometry_* variables are ever written to > >preferences, at least with qt3. > > Time... I plan(ned) to add xysaved, and fixed height/width to the > preference dialog. I really don't care about them. I do ca

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Enrico Forestieri
On Thu, Jun 15, 2006 at 04:32:00PM +0200, Peter Kümmel wrote: > I couldn't find any "geometry" option in the trunk version of lyx. > Weher is the code for the geometry option? Has it been removed? See parse_help() in lyx_main.C. I doubt it has been removed as I do not get any error when use "-geo

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Bo Peng
I couldn't find any "geometry" option in the trunk version of lyx. Weher is the code for the geometry option? Has it been removed? Do you mix branches? In lyxrc.h, session-related options are /// whether or not go to saved position when opening a file bool use_lastfilepos;

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Georg Baum
Am Donnerstag, 15. Juni 2006 16:32 schrieb Peter Kümmel: > I couldn't find any "geometry" option in the trunk version of lyx. > Weher is the code for the geometry option? Has it been removed? No, it was never there. It is handled internally by qt (even on windows), xforms or gtk (almost all X pr

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Peter Kümmel
Enrico Forestieri wrote: > On Thu, Jun 15, 2006 at 03:31:24PM +0200, Peter Kümmel wrote: >> Enrico Forestieri wrote: >>> On Thu, Jun 15, 2006 at 10:47:06AM +0200, Michael Gerz wrote: Hi, after applying svn merge -r14068:HEAD svn+ssh://[EMAIL PROTECTED]/lyx/lyx-devel/trunk

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Bo Peng
BTW, I see that no \screen_geometry_* variables are ever written to preferences, at least with qt3. Time... I plan(ned) to add xysaved, and fixed height/width to the preference dialog. Bo

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Enrico Forestieri
On Thu, Jun 15, 2006 at 04:04:19PM +0200, Peter Kümmel wrote: > Enrico Forestieri wrote: > >> does it work without the geometry option? > > > > I mean that "lyx -geometry 800x600+20+20" and "lyx" produce the same > > result, i.e., -geometry is ignored. The LyX window always opens in the > > upper

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Peter Kümmel
Enrico Forestieri wrote: >> does it work without the geometry option? > > I mean that "lyx -geometry 800x600+20+20" and "lyx" produce the same > result, i.e., -geometry is ignored. The LyX window always opens in the > upper left corner. This is true both on Windows and *nix, but on Windows > it is

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Enrico Forestieri
On Thu, Jun 15, 2006 at 03:31:24PM +0200, Peter Kümmel wrote: > Enrico Forestieri wrote: > > On Thu, Jun 15, 2006 at 10:47:06AM +0200, Michael Gerz wrote: > >> Hi, > >> > >> after applying > >> > >> svn merge -r14068:HEAD svn+ssh://[EMAIL PROTECTED]/lyx/lyx-devel/trunk > >> > >> the LyX window is

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Peter Kümmel
Enrico Forestieri wrote: > On Thu, Jun 15, 2006 at 10:47:06AM +0200, Michael Gerz wrote: >> Hi, >> >> after applying >> >> svn merge -r14068:HEAD svn+ssh://[EMAIL PROTECTED]/lyx/lyx-devel/trunk >> >> the LyX window is always placed in the upper left corner on Windows XP. >> Even worse, the title

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Enrico Forestieri
On Thu, Jun 15, 2006 at 10:47:06AM +0200, Michael Gerz wrote: > Hi, > > after applying > > svn merge -r14068:HEAD svn+ssh://[EMAIL PROTECTED]/lyx/lyx-devel/trunk > > the LyX window is always placed in the upper left corner on Windows XP. > Even worse, the title bar is no longer visible, such t

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Peter Kümmel
Peter Kümmel wrote: > Michael Gerz wrote: >> Hi, >> >> after applying >> >> svn merge -r14068:HEAD svn+ssh://[EMAIL PROTECTED]/lyx/lyx-devel/trunk >> >> the LyX window is always placed in the upper left corner on Windows XP. >> Even worse, the title bar is no longer visible, such that I cannot mov

Re: LyX Window placed in the upper left corner

2006-06-15 Thread Peter Kümmel
Michael Gerz wrote: > Hi, > > after applying > > svn merge -r14068:HEAD svn+ssh://[EMAIL PROTECTED]/lyx/lyx-devel/trunk > > the LyX window is always placed in the upper left corner on Windows XP. > Even worse, the title bar is no longer visible, such that I cannot move > the window. > > Suspec