[EMAIL PROTECTED] (Lars Gullik Bjønnes) writes: | This patch even makes it run, albeit with a grabled screen. The gui | operations (adding objects and such) are done in the wrong order.
No changes to xforms, but changes so that qt compiles. (patch at bottom) Qt4 and gtk has some failures unrelated to my changes: qt4 (4.1.4) --- Application.C: In member function 'virtual bool lyx::frontend::Application::x11EventFilter(XEvent*)': Application.C:77: error: 'class lyx::frontend::GuiWorkArea' has no member named 'view' Application.C:82: error: 'class lyx::frontend::GuiWorkArea' has no member named 'view' GuiWorkArea.C: In member function 'virtual void lyx::frontend::GuiWorkArea::inputMethodEvent(QInputMethodEvent*)': GuiWorkArea.C:606: error: 'class QInputMethodEvent' has no member named 'text' gtk (very similar errors to what I saw with xforms) --- GView.C: In constructor 'lyx::frontend::GView::GView(lyx::frontend::Gui&)': GView.C:96: error: request for member 'reset' in '((lyx::frontend::GView*)this)->lyx::frontend::GView::<anonymous>.LyXView::bufferview_', which is of non-class type 'BufferView*' GView.C:96: error: no matching function for call to 'BufferView::BufferView(lyx::frontend::GView* const, int, int)' ../../../src/BufferView.h:97: note: candidates are: BufferView::BufferView(LyXView*, lyx::frontend::WorkArea*) ../../../src/BufferView.h:91: note: BufferView::BufferView(const BufferView&) GuiImplementation.h:31: error: 'GView' does not name a type GuiImplementation.h:106: error: 'FView' was not declared in this scope GuiImplementation.h:106: error: template argument 1 is invalid GuiImplementation.h: In member function 'virtual int lyx::frontend::GuiImplementation::newView(unsigned int, unsigned int)': GuiImplementation.h:56: error: request for member 'reset' in '((lyx::frontend::GuiImplementation*)this)->lyx::frontend::GuiImplementation::view_', which is of non-class type 'int' GuiImplementation.h:56: error: expected type-specifier before 'FView' GuiImplementation.h:56: error: expected `)' before 'FView' GuiImplementation.h: At global scope: GuiImplementation.h:54: warning: unused parameter 'w' GuiImplementation.h:54: warning: unused parameter 'h' GuiImplementation.h: In member function 'virtual LyXView& lyx::frontend::GuiImplementation::view(int)': GuiImplementation.h:63: error: invalid type argument of 'unary *' GuiImplementation.h: In member function 'virtual void lyx::frontend::GuiImplementation::destroyView(int)': GuiImplementation.h:69: error: request for member 'reset' in '((lyx::frontend::GuiImplementation*)this)->lyx::frontend::GuiImplementation::view_', which is of non-class type 'int' GuiImplementation.h: In member function 'virtual int lyx::frontend::GuiImplementation::newWorkArea(unsigned int, unsigned int, int)': GuiImplementation.h:74: error: request for member 'get' in '((lyx::frontend::GuiImplementation*)this)->lyx::frontend::GuiImplementation::view_', which is of non-class type 'int' GuiImplementation.h:81: error: request for member 'get' in '((lyx::frontend::GuiImplementation*)this)->lyx::frontend::GuiImplementation::view_', which is of non-class type 'int' GuiImplementation.h:83: error: base operand of '->' is not a pointer lyx_gui.C: At global scope: lyx_gui.C:144: warning: unused parameter 'posx' lyx_gui.C:144: warning: unused parameter 'posy' And the patch -------------
Index: src/frontends/gtk/lyx_gui.C =================================================================== --- src/frontends/gtk/lyx_gui.C (revision 14200) +++ src/frontends/gtk/lyx_gui.C (working copy) @@ -145,7 +145,7 @@ { int view_id = theApp->gui().newView(width, height); GView & view = static_cast<GView &> (theApp->gui().view(view_id)); - int workArea_id_ = theApp->gui().newWorkArea(width, height, 0); + theApp->gui().newWorkArea(width, height, 0); LyX::ref().addLyXView(&view); Index: src/frontends/gtk/GWorkArea.h =================================================================== --- src/frontends/gtk/GWorkArea.h (revision 14200) +++ src/frontends/gtk/GWorkArea.h (working copy) @@ -58,7 +58,7 @@ class GWorkArea : public sigc::trackable { public: GWorkArea(LyXView & owner, int width, int height); - ~GWorkArea(); + virtual ~GWorkArea(); virtual Painter & getPainter(); /// Index: src/frontends/gtk/GuiImplementation.h =================================================================== --- src/frontends/gtk/GuiImplementation.h (revision 14200) +++ src/frontends/gtk/GuiImplementation.h (working copy) @@ -58,18 +58,18 @@ } - LyXView& view(int id) + LyXView& view(int /*id*/) { return *view_; } - void destroyView(int id) + void destroyView(int /*id*/) { view_.reset(); } - int newWorkArea(unsigned int w, unsigned int h, int view_id) + int newWorkArea(unsigned int w, unsigned int h, int /*view_id*/) { old_work_area_.reset(new FWorkArea(*view_.get(), w, h)); old_screen_.reset(new FScreen(*old_work_area_.get())); @@ -84,12 +84,12 @@ return 0; } - lyx::frontend::WorkArea& workArea(int id) + lyx::frontend::WorkArea& workArea(int /*id*/) { return *work_area_; } - void destroyWorkArea(int id) + void destroyWorkArea(int /*id*/) { clipboard_.reset(); work_area_.reset(); Index: src/frontends/gtk/GuiWorkArea.h =================================================================== --- src/frontends/gtk/GuiWorkArea.h (revision 14200) +++ src/frontends/gtk/GuiWorkArea.h (working copy) @@ -67,7 +67,7 @@ /// paint the cursor and store the background - virtual void showCursor(int x, int y, int h, Cursor_Shape shape) + virtual void showCursor(int x, int y, int h, CursorShape shape) { old_screen_->showCursor(x, y, h, shape); } Index: src/frontends/gtk/GScreen.C =================================================================== --- src/frontends/gtk/GScreen.C (revision 14200) +++ src/frontends/gtk/GScreen.C (working copy) @@ -32,6 +32,7 @@ #include "frontends/font_metrics.h" #include "frontends/Painter.h" +#include "frontends/GuiCursor.h" #include "insets/insettext.h" @@ -64,7 +65,7 @@ } -void GScreen::showCursor(int x, int y, int h, Cursor_Shape shape) +void GScreen::showCursor(int x, int y, int h, CursorShape shape) { // Update the cursor color. setCursorColor(owner_.getGC()); Index: src/frontends/gtk/GPainter.C =================================================================== --- src/frontends/gtk/GPainter.C (revision 14200) +++ src/frontends/gtk/GPainter.C (working copy) @@ -232,7 +232,7 @@ XftFont * fontS = getXftFont(smallfont); char c; int tmpx = x; - for (int i = 0; i < ls; ++i) { + for (unsigned int i = 0; i < ls; ++i) { c = lyx::support::uppercase(s[i]); if (c != s[i]) { XftDrawString8(draw, xftClr, fontS, tmpx, y, Index: src/frontends/gtk/GScreen.h =================================================================== --- src/frontends/gtk/GScreen.h (revision 14200) +++ src/frontends/gtk/GScreen.h (working copy) @@ -39,7 +39,7 @@ /// virtual void removeCursor(); /// - virtual void showCursor(int x, int y, int h, Cursor_Shape shape); + virtual void showCursor(int x, int y, int h, CursorShape shape); /// Copies specified area of pixmap to screen virtual void expose(int x, int y, int w, int h); Index: src/frontends/WorkArea.h =================================================================== --- src/frontends/WorkArea.h (revision 14200) +++ src/frontends/WorkArea.h (working copy) @@ -66,7 +66,7 @@ void greyOut(); /// paint the cursor and store the background - virtual void showCursor(int x, int y, int h, Cursor_Shape shape) = 0; + virtual void showCursor(int x, int y, int h, CursorShape shape) = 0; /// hide the cursor virtual void removeCursor() = 0; Index: src/frontends/qt3/lyx_gui.C =================================================================== --- src/frontends/qt3/lyx_gui.C (revision 14200) +++ src/frontends/qt3/lyx_gui.C (working copy) @@ -241,7 +241,7 @@ int view_id = theApp->gui().newView(width, height); QtView & view = static_cast<QtView &> (theApp->gui().view(view_id)); - int workArea_id_ = theApp->gui().newWorkArea(width, height, 0); + theApp->gui().newWorkArea(width, height, 0); LyX::ref().addLyXView(&view); Index: src/frontends/qt3/qscreen.C =================================================================== --- src/frontends/qt3/qscreen.C (revision 14200) +++ src/frontends/qt3/qscreen.C (working copy) @@ -60,7 +60,7 @@ } -void QScreen::showCursor(int x, int y, int h, Cursor_Shape shape) +void QScreen::showCursor(int x, int y, int h, CursorShape shape) { if (!qApp->focusWidget()) return; Index: src/frontends/qt3/qscreen.h =================================================================== --- src/frontends/qt3/qscreen.h (revision 14200) +++ src/frontends/qt3/qscreen.h (working copy) @@ -40,7 +40,7 @@ virtual void expose(int x, int y, int exp_width, int exp_height); /// paint the cursor and store the background - virtual void showCursor(int x, int y, int h, lyx::frontend::Cursor_Shape shape); + virtual void showCursor(int x, int y, int h, lyx::frontend::CursorShape shape); /// hide the cursor virtual void removeCursor(); Index: src/frontends/qt3/QtView.C =================================================================== Index: src/frontends/qt3/GuiImplementation.h =================================================================== --- src/frontends/qt3/GuiImplementation.h (revision 14200) +++ src/frontends/qt3/GuiImplementation.h (working copy) @@ -51,25 +51,25 @@ return *clipboard_; } - int newView(unsigned int w, unsigned int h) + int newView(unsigned int /*w*/, unsigned int /*h*/) { view_.reset(new FView(*this)); return 0; } - LyXView& view(int id) + LyXView& view(int /*id*/) { return *view_; } - void destroyView(int id) + void destroyView(int /*id*/) { view_.reset(); } - int newWorkArea(unsigned int w, unsigned int h, int view_id) + int newWorkArea(unsigned int w, unsigned int h, int /*view_id*/) { old_work_area_.reset(new FWorkArea(*view_.get(), w, h)); old_screen_.reset(new FScreen(*old_work_area_.get())); @@ -84,12 +84,12 @@ return 0; } - lyx::frontend::WorkArea& workArea(int id) + lyx::frontend::WorkArea& workArea(int /*id*/) { return *work_area_; } - void destroyWorkArea(int id) + void destroyWorkArea(int /*id*/) { clipboard_.reset(); work_area_.reset(); Index: src/frontends/qt3/GuiWorkArea.h =================================================================== --- src/frontends/qt3/GuiWorkArea.h (revision 14200) +++ src/frontends/qt3/GuiWorkArea.h (working copy) @@ -67,7 +67,7 @@ /// paint the cursor and store the background - virtual void showCursor(int x, int y, int h, Cursor_Shape shape) + virtual void showCursor(int x, int y, int h, CursorShape shape) { old_screen_->showCursor(x, y, h, shape); } Index: src/frontends/GuiCursor.h =================================================================== --- src/frontends/GuiCursor.h (revision 14200) +++ src/frontends/GuiCursor.h (working copy) @@ -11,6 +11,22 @@ * Full author contact details are available in file CREDITS. */ +// X11 use a define called CursorShape, and we really want to use +// that name our selves. Therefore we do something similar to what is done +// in kde/fixx11h.h: +namespace X { +#ifdef CursorShape +#ifndef FIXX11H_CursorShape +#define FIXX11H_CursorShape +int const XCursorShape = CursorShape; +#undef CursorShape +int const CursorShape = CursorShape; +#endif +#undef CursorShape +#endif + +} // namespace X + #ifndef GUI_CURSOR_H #define GUI_CURSOR_H @@ -26,7 +42,7 @@ class WorkArea; /// types of cursor in work area -enum Cursor_Shape { +enum CursorShape { /// normal I-beam BAR_SHAPE, /// L-shape for locked insets of a different language Index: src/frontends/qt4/QLPainter.C =================================================================== --- src/frontends/qt4/QLPainter.C (revision 14200) +++ src/frontends/qt4/QLPainter.C (working copy) @@ -216,7 +216,7 @@ setQPainterPen(*qp_.get(), f.realColor()); int tmpx = x; size_t ls = s.length(); - for (size_t i = 0; i < ls; ++i) { + for (unsigned int i = 0; i < ls; ++i) { QChar const c = s[i].upper(); if (c != s.at(i)) { qp_->setFont(qsmallfont); @@ -240,7 +240,7 @@ QString str; str.setLength(ls); - for (size_t i = 0; i < ls; ++i) + for (unsigned int i = 0; i < ls; ++i) str[i] = QChar(encoding->ucs(s[i])); // HACK: QT3 refuses to show single compose characters Index: src/frontends/qt4/Application.C =================================================================== Index: src/frontends/qt4/GuiImplementation.C =================================================================== --- src/frontends/qt4/GuiImplementation.C (revision 14200) +++ src/frontends/qt4/GuiImplementation.C (working copy) @@ -35,7 +35,7 @@ } -int GuiImplementation::newView(unsigned int w, unsigned int h) +int GuiImplementation::newView(unsigned int /*w*/, unsigned int /*h*/) { size_t const id = max_view_id_; ++max_view_id_; Index: src/frontends/qt4/GuiWorkArea.C =================================================================== --- src/frontends/qt4/GuiWorkArea.C (revision 14200) +++ src/frontends/qt4/GuiWorkArea.C (working copy) @@ -523,7 +523,7 @@ } -void GuiWorkArea::showCursor(int x, int y, int h, Cursor_Shape shape) +void GuiWorkArea::showCursor(int x, int y, int h, CursorShape shape) { if (!qApp->focusWidget()) return; Index: src/frontends/qt4/GuiWorkArea.h =================================================================== --- src/frontends/qt4/GuiWorkArea.h (revision 14200) +++ src/frontends/qt4/GuiWorkArea.h (working copy) @@ -144,7 +144,7 @@ virtual void expose(int x, int y, int exp_width, int exp_height); /// paint the cursor and store the background - virtual void showCursor(int x, int y, int h, Cursor_Shape shape); + virtual void showCursor(int x, int y, int h, CursorShape shape); /// hide the cursor virtual void removeCursor(); @@ -240,7 +240,7 @@ /// QColor cursor_color_; /// - Cursor_Shape cursor_shape_; + CursorShape cursor_shape_; }; } // namespace frontend Index: src/frontends/Gui.h =================================================================== --- src/frontends/Gui.h (revision 14200) +++ src/frontends/Gui.h (working copy) @@ -18,6 +18,8 @@ #include <boost/shared_ptr.hpp> +#include <map> + class LyXView; namespace lyx { Index: src/frontends/xforms/XFormsView.C =================================================================== --- src/frontends/xforms/XFormsView.C (revision 14200) +++ src/frontends/xforms/XFormsView.C (working copy) @@ -74,7 +74,7 @@ XFormsView::XFormsView(Gui & owner, int width, int height) : LyXView(owner), window_(Box(width, height)), - icon_pixmap_(0), icon_mask_(0), frontend_(*this) + icon_pixmap_(0), icon_mask_(0) { int const air = 2; @@ -108,7 +108,6 @@ menubar_.reset(new XFormsMenubar(this, menubackend)); getToolbars().init(); - bufferview_.reset(new BufferView(this, width, height)); minibuffer_.reset(new XMiniBuffer(*this, *controlcommand_)); // Assign an icon to the main form. @@ -138,7 +137,7 @@ focus_command_buffer.connect(boost::bind(&XMiniBuffer::focus, minibuffer_.get())); // Make sure the buttons are disabled if needed. - updateToolbars(); + //updateToolbars(); redraw_con = getDialogs().redrawGUI().connect(boost::bind(&XFormsView::redraw, this)); } Index: src/frontends/xforms/xscreen.C =================================================================== --- src/frontends/xforms/xscreen.C (revision 14200) +++ src/frontends/xforms/xscreen.C (working copy) @@ -73,7 +73,7 @@ } -void XScreen::showCursor(int x, int y, int h, Cursor_Shape shape) +void XScreen::showCursor(int x, int y, int h, CursorShape shape) { // Update the cursor color. (a little slow doing it like this ??) setCursorColor(); Index: src/frontends/xforms/XFormsView.h =================================================================== --- src/frontends/xforms/XFormsView.h (revision 14200) +++ src/frontends/xforms/XFormsView.h (working copy) @@ -12,7 +12,6 @@ #ifndef LyXView_H #define LyXView_H -#include "GuiImplementation.h" #include "LayoutEngine.h" #include "forms_fwd.h" Index: src/frontends/xforms/GuiImplementation.C =================================================================== --- src/frontends/xforms/GuiImplementation.C (revision 0) +++ src/frontends/xforms/GuiImplementation.C (revision 0) @@ -0,0 +1,50 @@ +// -*- C++ -*- +/** + * \file xforms/GuiImplementation.h + * This file is part of LyX, the document processor. + * Licence details can be found in the file COPYING. + * + * \author Abdelrazak Younes + * + * Full author contact details are available in file CREDITS. + */ + +#include "GuiImplementation.h" + +namespace lyx { +namespace frontend { + +int GuiImplementation::newView(unsigned int w, unsigned int h) +{ + view_.reset(new XFormsView(*this, w, h)); + return 0; +} + + +int GuiImplementation::newWorkArea(unsigned int w, unsigned int h, int /*view_id*/) +{ + old_work_area_.reset(new XWorkArea(*view_.get(), w, h)); + old_screen_.reset(new XScreen(*old_work_area_)); + work_area_.reset(new GuiWorkArea(boost::static_pointer_cast<XScreen>(old_screen_).get(), + boost::static_pointer_cast<XWorkArea>(old_work_area_).get())); + clipboard_.reset(new GuiClipboard(boost::static_pointer_cast<XWorkArea>(old_work_area_).get())); + guiCursor().connect(work_area_.get()); + + // FIXME BufferView creation should be independant of WorkArea creation + buffer_views_[0].reset(new BufferView(view_.get(), work_area_.get())); + work_area_->setBufferView(buffer_views_[0].get()); + view_->setBufferView(buffer_views_[0].get()); + return 0; +} + + +void GuiImplementation::destroyWorkArea(int /*id*/) +{ + clipboard_.reset(); + work_area_.reset(); + old_work_area_.reset(); + old_screen_.reset(); +} + +} // namespace frontend +} // namespace lyx Property changes on: src/frontends/xforms/GuiImplementation.C ___________________________________________________________________ Name: svn:eol-style + native Index: src/frontends/xforms/XWorkArea.C =================================================================== --- src/frontends/xforms/XWorkArea.C (revision 14200) +++ src/frontends/xforms/XWorkArea.C (working copy) @@ -116,6 +116,13 @@ FL_OBJECT * obj; FL_OBJECT * frame; + XFormsView & xview = dynamic_cast<XFormsView &>(owner); + + // Set the current form so that objects have something to get + // added to. + //fl_addto_form(fl_current_form); + fl_addto_form(xview.getForm()); + // A frame around the work area. frame = obj = fl_add_box(FL_BORDER_BOX, 0, 0, w, h, ""); fl_set_object_resize(obj, FL_RESIZE_ALL); @@ -150,7 +157,6 @@ // Hand control of the layout of these widgets to the // Layout Engine. - XFormsView & xview = dynamic_cast<XFormsView &>(owner); BoxList & boxlist = xview.getBox(XFormsView::Center)->children(); wa_box_ = boxlist.push_back(Box(0,0)); @@ -179,6 +185,8 @@ val.function = GXcopy; copy_gc = XCreateGC(fl_get_display(), RootWindow(fl_get_display(), 0), GCFunction, &val); + + fl_end_form(); } Index: src/frontends/xforms/xscreen.h =================================================================== --- src/frontends/xforms/xscreen.h (revision 14200) +++ src/frontends/xforms/xscreen.h (working copy) @@ -13,10 +13,10 @@ #ifndef XSCREEN_H #define XSCREEN_H -#include "frontends/GuiCursor.h" - #include <X11/Xlib.h> // for Pixmap, GC +#include "frontends/GuiCursor.h" + class WorkArea; namespace lyx { @@ -44,7 +44,7 @@ virtual void expose(int x, int y, int w, int h); /// paint the cursor and store the background - virtual void showCursor(int x, int y, int h, Cursor_Shape shape); + virtual void showCursor(int x, int y, int h, CursorShape shape); /// hide the cursor virtual void removeCursor(); Index: src/frontends/xforms/GuiImplementation.h =================================================================== --- src/frontends/xforms/GuiImplementation.h (revision 14200) +++ src/frontends/xforms/GuiImplementation.h (working copy) @@ -17,10 +17,13 @@ #include "xscreen.h" #include "XWorkArea.h" +#include "XFormsView.h" #include "GuiClipboard.h" #include "GuiWorkArea.h" +#include "BufferView.h" + #include <boost/shared_ptr.hpp> #include <map> @@ -28,10 +32,6 @@ namespace lyx { namespace frontend { -typedef XFormsView FView; -typedef XScreen FScreen; -typedef XWorkArea FWorkArea; - /** * The Gui class is the interface to all XForms components. */ @@ -51,51 +51,28 @@ return *clipboard_; } - int newView(unsigned int w, unsigned int h) - { - view_.reset(new FView(*this, w, h)); - return 0; - } + int newView(unsigned int w, unsigned int h); - LyXView& view(int id) + LyXView & view(int /*id*/) { return *view_; } - void destroyView(int id) + void destroyView(int /*id*/) { view_.reset(); } - int newWorkArea(unsigned int w, unsigned int h, int view_id) - { - old_work_area_.reset(new FWorkArea(*view_.get(), w, h)); - old_screen_.reset(new FScreen(*old_work_area_.get())); - work_area_.reset(new GuiWorkArea(old_screen_.get(), old_work_area_.get())); - clipboard_.reset(new GuiClipboard(old_work_area_.get())); - guiCursor().connect(work_area_.get()); - - // FIXME BufferView creation should be independant of WorkArea creation - buffer_views_[0].reset(new BufferView(view_.get(), work_area_.get())); - work_area_->setBufferView(buffer_views_[0].get()); - view_->setBufferView(buffer_views_[0].get()); - return 0; - } + int newWorkArea(unsigned int w, unsigned int h, int view_id); - lyx::frontend::WorkArea& workArea(int id) + lyx::frontend::WorkArea & workArea(int /*id*/) { return *work_area_; } - void destroyWorkArea(int id) - { - clipboard_.reset(); - work_area_.reset(); - old_work_area_.reset(); - old_screen_.reset(); - } + void destroyWorkArea(int id); private: /// @@ -103,11 +80,11 @@ /// boost::shared_ptr<GuiWorkArea> work_area_; /// - boost::shared_ptr<FView> view_; + boost::shared_ptr<LyXView> view_; /// - boost::shared_ptr<FWorkArea> old_work_area_; + boost::shared_ptr<XWorkArea> old_work_area_; /// - boost::shared_ptr<FScreen> old_screen_; + boost::shared_ptr<XScreen> old_screen_; }; } // namespace frontend Index: src/frontends/xforms/XWorkArea.h =================================================================== --- src/frontends/xforms/XWorkArea.h (revision 14200) +++ src/frontends/xforms/XWorkArea.h (working copy) @@ -31,7 +31,7 @@ /// XWorkArea(LyXView & owner, int width, int height); /// - ~XWorkArea(); + virtual ~XWorkArea(); /// virtual Painter & getPainter() { return painter_; } /// Index: src/frontends/xforms/Makefile.am =================================================================== --- src/frontends/xforms/Makefile.am (revision 14200) +++ src/frontends/xforms/Makefile.am (working copy) @@ -158,6 +158,7 @@ FormWrap.h \ GuiClipboard.h \ GuiImplementation.h \ + GuiImplementation.C \ GuiWorkArea.h \ LayoutEngine.C \ LayoutEngine.h \ Index: src/frontends/xforms/GuiClipboard.h =================================================================== --- src/frontends/xforms/GuiClipboard.h (revision 14200) +++ src/frontends/xforms/GuiClipboard.h (working copy) @@ -19,15 +19,13 @@ namespace lyx { namespace frontend { -typedef XWorkArea FWorkArea; - /** * The XForms version of the Clipboard. */ class GuiClipboard: public lyx::frontend::Clipboard { public: - GuiClipboard(FWorkArea * work_area) + GuiClipboard(XWorkArea * work_area) : old_work_area_(work_area) { } @@ -54,7 +52,7 @@ //@} private: - FWorkArea * old_work_area_; + XWorkArea * old_work_area_; }; } // namespace frontend Index: src/frontends/xforms/GuiWorkArea.h =================================================================== --- src/frontends/xforms/GuiWorkArea.h (revision 14200) +++ src/frontends/xforms/GuiWorkArea.h (working copy) @@ -20,16 +20,13 @@ namespace lyx { namespace frontend { -typedef XScreen FScreen; -typedef XWorkArea FWorkArea; - /** * Temporary wrapper around XWorkArea and XScreen. * Please refer to the Qt4 implementation for a proper cleanup of the API. */ class GuiWorkArea: public lyx::frontend::WorkArea { public: - GuiWorkArea(FScreen * screen, FWorkArea * work_area) + GuiWorkArea(XScreen * screen, XWorkArea * work_area) : old_screen_(screen), old_work_area_(work_area) { } @@ -67,7 +64,7 @@ /// paint the cursor and store the background - virtual void showCursor(int x, int y, int h, Cursor_Shape shape) + virtual void showCursor(int x, int y, int h, CursorShape shape) { old_screen_->showCursor(x, y, h, shape); } @@ -86,8 +83,8 @@ } private: - FScreen * old_screen_; - FWorkArea * old_work_area_; + XScreen * old_screen_; + XWorkArea * old_work_area_; }; } // namespace frontend Index: src/frontends/GuiCursor.C =================================================================== --- src/frontends/GuiCursor.C (revision 14200) +++ src/frontends/GuiCursor.C (working copy) @@ -42,10 +42,6 @@ #include "support/filetools.h" // LibFileSearch -#include <boost/utility.hpp> -#include <boost/bind.hpp> -#include <boost/signals/trackable.hpp> - using lyx::support::libFileSearch; using std::endl; @@ -57,7 +53,7 @@ namespace frontend { GuiCursor::GuiCursor() - : cursor_visible_(false), work_area_(NULL) + : cursor_visible_(false), work_area_(0) { } @@ -80,7 +76,7 @@ if (!bv.available()) return; - Cursor_Shape shape = BAR_SHAPE; + CursorShape shape = BAR_SHAPE; LyXText const & text = *bv.getLyXText(); LyXFont const & realfont = text.real_current_font; Index: src/BufferView.h =================================================================== Index: src/lyx_main.h ===================================================================
-- Lgb