summaryrefslogtreecommitdiff
path: root/starmath/inc/view.hxx
diff options
context:
space:
mode:
authorJonas Finnemann Jensen <jopsen@gmail.com>2010-10-01 22:04:50 +0200
committerJonas Finnemann Jensen <jopsen@gmail.com>2010-10-01 23:08:54 +0200
commit8c340c4270c3e955862f4f56be9fc135a3c2cc43 (patch)
tree58ca65df035ed3d141bd26319b1e2470455e4198 /starmath/inc/view.hxx
parentc1369970be1d2c0cb19edcac4e1d010635c89730 (diff)
Integrated the visual formula editor patch
Ported the most recent version of the visual formula editor patch, to LibreOffice. This patch is not finished yet, see README for more information.
Diffstat (limited to 'starmath/inc/view.hxx')
-rw-r--r--starmath/inc/view.hxx25
1 files changed, 15 insertions, 10 deletions
diff --git a/starmath/inc/view.hxx b/starmath/inc/view.hxx
index d414d1e72309..dffb0100f581 100644
--- a/starmath/inc/view.hxx
+++ b/starmath/inc/view.hxx
@@ -51,7 +51,6 @@ class SmPrintUIOptions;
class SmGraphicWindow : public ScrollableWindow
{
Point aFormulaDrawPos;
- Rectangle aCursorRect;
::com::sun::star::uno::Reference<
::com::sun::star::accessibility::XAccessible > xAccessible;
@@ -60,14 +59,9 @@ class SmGraphicWindow : public ScrollableWindow
SmViewShell *pViewShell;
USHORT nZoom;
short nModifyCount;
- BOOL bIsCursorVisible;
protected:
void SetFormulaDrawPos(const Point &rPos) { aFormulaDrawPos = rPos; }
- void SetIsCursorVisible(BOOL bVis) { bIsCursorVisible = bVis; }
- using Window::SetCursor;
- void SetCursor(const SmNode *pNode);
- void SetCursor(const Rectangle &rRect);
virtual void DataChanged( const DataChangedEvent& );
virtual void Paint(const Rectangle&);
@@ -98,10 +92,6 @@ public:
using ScrollableWindow::SetTotalSize;
void SetTotalSize();
- BOOL IsCursorVisible() const { return bIsCursorVisible; }
- void ShowCursor(BOOL bShow);
- const SmNode * SetCursorPos(USHORT nRow, USHORT nCol);
-
void ApplyColorConfigValues( const svtools::ColorConfig &rColorCfg );
// for Accessibility
@@ -229,6 +219,11 @@ class SmViewShell: public SfxViewShell
DECL_LINK( DialogClosedHdl, sfx2::FileDialogHelper* );
virtual void Notify( SfxBroadcaster& rBC, const SfxHint& rHint );
+ /** Used to determine whether insertions using SID_INSERTSYMBOL and SID_INSERTCOMMAND
+ * should be inserted into SmEditWindow or directly into the SmDocShell as done if the
+ * visual editor was last to have focus.
+ */
+ BOOL bInsertIntoEditWindow;
protected:
Size GetTextLineSize(OutputDevice& rDevice,
@@ -292,6 +287,16 @@ public:
void Impl_Print( OutputDevice &rOutDev, const SmPrintUIOptions &rPrintUIOptions,
Rectangle aOutRect, Point aZeroPoint );
+
+ /** Set bInsertIntoEditWindow so we know where to insert
+ *
+ * This method is called whenever SmGraphicWindow or SmEditWindow gets focus,
+ * so that when text is inserted from catalog or elsewhere we know whether to
+ * insert for the visual editor, or the text editor.
+ */
+ void SetInsertIntoEditWindow(BOOL bEditWindowHadFocusLast = TRUE){
+ bInsertIntoEditWindow = bEditWindowHadFocusLast;
+ }
};
#endif