Bo Peng wrote:
Bo, the geometry session stuff is now stored in GuiView::saveGeometry().
It is guaranted to be called, either in GuiView::closeEvent() or in
LyX::quit().

This is good.

I reckon adding multiple view support will be simple as you have access
to the window id in GuiView thanks to the LyXView::id() method. As I
don't know how to handle the file format change, I will let you do that
if you don't mind.

But I do not know how to create window with given geometry. (Need to
read the code).

At the end of LyX::newLyXView() you can read:

// create the main window
LyXView * view = &pimpl_->application_->createView(width, height, posx, posy, maximize);


+       // save windows size and position
+       Session & session = LyX::ref().session();
+ session.saveSessionInfo("WindowWidth", convert<string>(geometry.width())); + session.saveSessionInfo("WindowHeight", convert<string>(geometry.height())); + session.saveSessionInfo("WindowIsMaximized", (isMaximized() ? "yes" : "no"));
+       if (lyxrc.geometry_xysaved) {
+ session.saveSessionInfo("WindowPosX", convert<string>(geometry.x())); + session.saveSessionInfo("WindowPosY", convert<string>(geometry.y()));
+       }
+}

There is no file format change.

Why is that? I would like LyX to reopen as many window as were opened when I exited. And I would also like LyX to open a second window with the same size as the one I closed a bit earlier.
IMHO, the geometry settings are window ids dependant.

All the information is saved/restored
as key=value pair. However, I think the information of window (not
main window) size information should be saved with lastopenedfiles,
which is not at the frontend level, and can not access window size
info. I guess lastopenedfiles need to be relocated.

I am not sure I understand what you say here but IMHO window geometries have nothing to do with lastopened file.


                { LFUN_WINDOW_NEW, "window-new", NoBuffer },
+<<<<<<< .mine
+               { LFUN_WINDOW_CLOSE, "window-close", NoBuffer },
+=======
                { LFUN_UNICODE_INSERT, "unicode-insert", Noop },

+>>>>>>> .r15509
                { LFUN_NOACTION, "", Noop }
        };

unsolved conflict.

year... I noticed that afterward. It solved and working now.

Abdel.

Reply via email to