2004-01-20 10:33:31 +00:00
|
|
|
/*************************************************************************
|
|
|
|
*
|
2005-09-09 04:05:14 +00:00
|
|
|
* OpenOffice.org - a multi-platform office productivity suite
|
2004-01-20 10:33:31 +00:00
|
|
|
*
|
2005-09-09 04:05:14 +00:00
|
|
|
* $RCSfile: FrameView.hxx,v $
|
2004-01-20 10:33:31 +00:00
|
|
|
*
|
2007-08-28 12:37:48 +00:00
|
|
|
* $Revision: 1.8 $
|
2004-01-20 10:33:31 +00:00
|
|
|
*
|
2007-08-28 12:37:48 +00:00
|
|
|
* last change: $Author: vg $ $Date: 2007-08-28 13:37:48 $
|
2004-01-20 10:33:31 +00:00
|
|
|
*
|
2005-09-09 04:05:14 +00:00
|
|
|
* The Contents of this file are made available subject to
|
|
|
|
* the terms of GNU Lesser General Public License Version 2.1.
|
2004-01-20 10:33:31 +00:00
|
|
|
*
|
|
|
|
*
|
2005-09-09 04:05:14 +00:00
|
|
|
* GNU Lesser General Public License Version 2.1
|
|
|
|
* =============================================
|
|
|
|
* Copyright 2005 by Sun Microsystems, Inc.
|
|
|
|
* 901 San Antonio Road, Palo Alto, CA 94303, USA
|
2004-01-20 10:33:31 +00:00
|
|
|
*
|
2005-09-09 04:05:14 +00:00
|
|
|
* This library is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU Lesser General Public
|
|
|
|
* License version 2.1, as published by the Free Software Foundation.
|
2004-01-20 10:33:31 +00:00
|
|
|
*
|
2005-09-09 04:05:14 +00:00
|
|
|
* This library is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
* Lesser General Public License for more details.
|
2004-01-20 10:33:31 +00:00
|
|
|
*
|
2005-09-09 04:05:14 +00:00
|
|
|
* You should have received a copy of the GNU Lesser General Public
|
|
|
|
* License along with this library; if not, write to the Free Software
|
|
|
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
|
|
|
* MA 02111-1307 USA
|
2004-01-20 10:33:31 +00:00
|
|
|
*
|
|
|
|
************************************************************************/
|
|
|
|
|
|
|
|
#ifndef SD_FRAME_VIEW_HXX
|
|
|
|
#define SD_FRAME_VIEW_HXX
|
|
|
|
|
|
|
|
#include "ViewShell.hxx"
|
|
|
|
|
|
|
|
#ifndef _SVDVIEW_HXX
|
|
|
|
#include <svx/svdview.hxx>
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef _PRESENTATION_HXX
|
|
|
|
#include "pres.hxx"
|
|
|
|
#endif
|
|
|
|
|
|
|
|
class SdDrawDocument;
|
|
|
|
class SdOptions;
|
|
|
|
|
|
|
|
namespace sd {
|
|
|
|
|
|
|
|
/*************************************************************************
|
|
|
|
|*
|
|
|
|
|* View fuer den MDIFrame
|
|
|
|
|*
|
|
|
|
\************************************************************************/
|
|
|
|
class FrameView
|
|
|
|
: public SdrView
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
FrameView(SdDrawDocument* pDrawDoc, FrameView* pFrameView = NULL );
|
|
|
|
FrameView(const FrameView& rFrameView);
|
|
|
|
virtual ~FrameView();
|
|
|
|
|
|
|
|
void Connect();
|
|
|
|
void Disconnect();
|
|
|
|
|
|
|
|
void Update(SdOptions* pOptions);
|
|
|
|
|
|
|
|
void SetStandardHelpLines(const SdrHelpLineList& rHelpLines)
|
2006-12-12 16:33:25 +00:00
|
|
|
{ maStandardHelpLines = rHelpLines; }
|
|
|
|
const SdrHelpLineList& GetStandardHelpLines() { return maStandardHelpLines; }
|
2004-01-20 10:33:31 +00:00
|
|
|
void SetNotesHelpLines(const SdrHelpLineList& rHelpLines)
|
2006-12-12 16:33:25 +00:00
|
|
|
{ maNotesHelpLines = rHelpLines; }
|
|
|
|
const SdrHelpLineList& GetNotesHelpLines() { return maNotesHelpLines; }
|
2004-01-20 10:33:31 +00:00
|
|
|
void SetHandoutHelpLines(const SdrHelpLineList& rHelpLines)
|
2006-12-12 16:33:25 +00:00
|
|
|
{ maHandoutHelpLines = rHelpLines; }
|
|
|
|
const SdrHelpLineList& GetHandoutHelpLines() { return maHandoutHelpLines; }
|
2004-01-20 10:33:31 +00:00
|
|
|
|
|
|
|
void SetVisibleLayers(const SetOfByte& rVisibleLayers)
|
2006-12-12 16:33:25 +00:00
|
|
|
{ maVisibleLayers = rVisibleLayers; }
|
|
|
|
const SetOfByte& GetVisibleLayers() { return maVisibleLayers; }
|
2004-01-20 10:33:31 +00:00
|
|
|
|
|
|
|
void SetLockedLayers(const SetOfByte& rLockedLayers)
|
2006-12-12 16:33:25 +00:00
|
|
|
{ maLockedLayers = rLockedLayers; }
|
|
|
|
const SetOfByte& GetLockedLayers() { return maLockedLayers; }
|
2004-01-20 10:33:31 +00:00
|
|
|
|
|
|
|
void SetPrintableLayers(const SetOfByte& rPrintableLayers)
|
2006-12-12 16:33:25 +00:00
|
|
|
{ maPrintableLayers = rPrintableLayers; }
|
|
|
|
const SetOfByte& GetPrintableLayers() { return maPrintableLayers; }
|
2004-01-20 10:33:31 +00:00
|
|
|
|
|
|
|
void SetRuler(const BOOL bRulerOn)
|
2006-12-12 16:33:25 +00:00
|
|
|
{ mbRuler = bRulerOn; }
|
|
|
|
const BOOL HasRuler() { return mbRuler; }
|
2004-01-20 10:33:31 +00:00
|
|
|
|
|
|
|
void SetNoColors(const BOOL bNoCol)
|
2006-12-12 16:33:25 +00:00
|
|
|
{ mbNoColors = bNoCol; }
|
|
|
|
const BOOL IsNoColors() { return mbNoColors; }
|
2004-01-20 10:33:31 +00:00
|
|
|
|
|
|
|
void SetNoAttribs(const BOOL bNoAttr)
|
2006-12-12 16:33:25 +00:00
|
|
|
{ mbNoAttribs = bNoAttr; }
|
|
|
|
const BOOL IsNoAttribs() { return mbNoAttribs; }
|
2004-01-20 10:33:31 +00:00
|
|
|
|
|
|
|
void SetVisArea(const Rectangle& rVisArea)
|
2006-12-12 16:33:25 +00:00
|
|
|
{ maVisArea = rVisArea; }
|
|
|
|
const Rectangle GetVisArea() { return maVisArea; }
|
2004-01-20 10:33:31 +00:00
|
|
|
|
2006-12-12 16:33:25 +00:00
|
|
|
void SetPageKind(PageKind eKind) { mePageKind = eKind; }
|
|
|
|
const PageKind GetPageKind() { return mePageKind; }
|
2004-01-20 10:33:31 +00:00
|
|
|
|
2005-07-14 10:28:51 +00:00
|
|
|
/** is used in FrameView::ReadUserDataSequence() only to store the
|
|
|
|
page kind that was selected while last saving this document */
|
2006-12-12 16:33:25 +00:00
|
|
|
void SetPageKindOnLoad(PageKind eKind) { mePageKindOnLoad = eKind; }
|
2005-07-14 10:28:51 +00:00
|
|
|
|
|
|
|
/** can be used to get the page kind that was selected on last save of this document */
|
2006-12-12 16:33:25 +00:00
|
|
|
const PageKind GetPageKindOnLoad() { return mePageKindOnLoad; }
|
2005-07-14 10:28:51 +00:00
|
|
|
|
2004-01-20 10:33:31 +00:00
|
|
|
void SetSelectedPage (USHORT nPage);
|
|
|
|
const USHORT GetSelectedPage (void) const;
|
|
|
|
|
2005-07-14 10:28:51 +00:00
|
|
|
/** is used in FrameView::ReadUserDataSequence() only to store the
|
|
|
|
page that was selected while last saving this document */
|
2006-12-12 16:33:25 +00:00
|
|
|
void SetSelectedPageOnLoad (USHORT nPage) { mnSelectedPageOnLoad = nPage; }
|
2005-07-14 10:28:51 +00:00
|
|
|
|
|
|
|
/** can be used to get the page that was selected on last save of this document */
|
2006-12-12 16:33:25 +00:00
|
|
|
const USHORT GetSelectedPageOnLoad (void) const { return mnSelectedPageOnLoad; }
|
2005-07-14 10:28:51 +00:00
|
|
|
|
2004-01-20 10:33:31 +00:00
|
|
|
void SetViewShEditMode(EditMode eMode, PageKind eKind);
|
2005-09-23 13:59:09 +00:00
|
|
|
EditMode GetViewShEditMode (PageKind eKind);
|
|
|
|
|
|
|
|
/** Remember the edit mode of the main view shell at the time when the
|
|
|
|
document is loaded.
|
|
|
|
*/
|
|
|
|
void SetViewShEditModeOnLoad (const EditMode eMode);
|
|
|
|
|
|
|
|
/** Return the value of the edit mode as it was when the document was
|
|
|
|
loaded.
|
|
|
|
*/
|
|
|
|
EditMode GetViewShEditModeOnLoad (void) const;
|
2004-01-20 10:33:31 +00:00
|
|
|
|
|
|
|
void SetLayerMode(BOOL bMode)
|
2006-12-12 16:33:25 +00:00
|
|
|
{ mbLayerMode = bMode; }
|
|
|
|
const BOOL IsLayerMode() { return mbLayerMode; }
|
2004-01-20 10:33:31 +00:00
|
|
|
|
|
|
|
void SetQuickEdit(BOOL bQEdit)
|
2006-12-12 16:33:25 +00:00
|
|
|
{ mbQuickEdit = bQEdit; }
|
|
|
|
const BOOL IsQuickEdit() { return mbQuickEdit; }
|
2004-01-20 10:33:31 +00:00
|
|
|
|
2006-12-12 16:33:25 +00:00
|
|
|
void SetBigHandles( BOOL bOn = TRUE ) { mbBigHandles = bOn; }
|
|
|
|
const BOOL IsBigHandles() const { return mbBigHandles; }
|
2004-01-20 10:33:31 +00:00
|
|
|
|
2006-12-12 16:33:25 +00:00
|
|
|
void SetDoubleClickTextEdit( BOOL bOn = TRUE ) { mbDoubleClickTextEdit = bOn; }
|
|
|
|
const BOOL IsDoubleClickTextEdit() const { return mbDoubleClickTextEdit; }
|
2004-01-20 10:33:31 +00:00
|
|
|
|
2006-12-12 16:33:25 +00:00
|
|
|
void SetClickChangeRotation( BOOL bOn = TRUE ) { mbClickChangeRotation = bOn; }
|
|
|
|
const BOOL IsClickChangeRotation() const { return mbClickChangeRotation; }
|
2004-01-20 10:33:31 +00:00
|
|
|
|
|
|
|
/** Remember the type of the view shell that was (or soon will be)
|
|
|
|
previously associated with this frame view.
|
|
|
|
@param eType
|
|
|
|
The type of the previous view shell or ViewShell::ST_NONE to
|
|
|
|
indicate that there is no previous view shell.
|
|
|
|
*/
|
|
|
|
void SetPreviousViewShellType (ViewShell::ShellType eType);
|
|
|
|
|
|
|
|
/** Return the type of the view shell previously associated with this
|
|
|
|
frame view.
|
|
|
|
*/
|
|
|
|
ViewShell::ShellType GetPreviousViewShellType (void) const;
|
|
|
|
|
2005-09-23 13:59:09 +00:00
|
|
|
/** Remember the type of the view shell at the time when the document is
|
|
|
|
loaded or, rather, when the ViewShellBase is constructed.
|
|
|
|
*/
|
|
|
|
void SetViewShellTypeOnLoad (ViewShell::ShellType eType);
|
|
|
|
|
|
|
|
ViewShell::ShellType GetViewShellTypeOnLoad (void) const;
|
|
|
|
|
2004-01-20 10:33:31 +00:00
|
|
|
void SetPresentationViewShellId(USHORT nId)
|
2006-12-12 16:33:25 +00:00
|
|
|
{ mnPresViewShellId = nId; }
|
|
|
|
const USHORT GetPresentationViewShellId() { return mnPresViewShellId; }
|
2004-01-20 10:33:31 +00:00
|
|
|
|
2006-12-12 16:33:25 +00:00
|
|
|
void SetSlotId(USHORT nId) { mnSlotId = nId; }
|
|
|
|
const USHORT GetSlotId() { return mnSlotId; }
|
2004-01-20 10:33:31 +00:00
|
|
|
|
2006-12-12 16:33:25 +00:00
|
|
|
void SetSlidesPerRow(USHORT nSlides) { mnSlidesPerRow = nSlides; }
|
|
|
|
USHORT GetSlidesPerRow() const { return mnSlidesPerRow; }
|
2004-01-20 10:33:31 +00:00
|
|
|
|
2006-12-12 16:33:25 +00:00
|
|
|
void SetDrawMode(ULONG nNewDrawMode) { mnDrawMode = nNewDrawMode; };
|
|
|
|
ULONG GetDrawMode() const { return mnDrawMode; };
|
2004-01-20 10:33:31 +00:00
|
|
|
|
2006-12-12 16:33:25 +00:00
|
|
|
void SetTabCtrlPercent( double nPercent ) { mnTabCtrlPercent = nPercent; }
|
|
|
|
double GetTabCtrlPercent() const { return mnTabCtrlPercent; }
|
2004-01-20 10:33:31 +00:00
|
|
|
|
2007-08-28 12:37:48 +00:00
|
|
|
void SetIsNavigatorShowingAllShapes (const bool bIsNavigatorShowingAllShapes);
|
|
|
|
bool IsNavigatorShowingAllShapes (void) const;
|
|
|
|
|
2004-01-20 10:33:31 +00:00
|
|
|
virtual void WriteUserDataSequence ( ::com::sun::star::uno::Sequence < ::com::sun::star::beans::PropertyValue >&, sal_Bool bBrowse = sal_False );
|
|
|
|
virtual void ReadUserDataSequence ( const ::com::sun::star::uno::Sequence < ::com::sun::star::beans::PropertyValue >&, sal_Bool bBrowse = sal_False );
|
|
|
|
|
|
|
|
private:
|
2006-12-12 16:33:25 +00:00
|
|
|
USHORT mnRefCount;
|
|
|
|
VirtualDevice* mpVDev;
|
|
|
|
BOOL mbRuler;
|
|
|
|
SetOfByte maVisibleLayers;
|
|
|
|
SetOfByte maLockedLayers;
|
|
|
|
SetOfByte maPrintableLayers;
|
|
|
|
SdrHelpLineList maStandardHelpLines;
|
|
|
|
SdrHelpLineList maNotesHelpLines;
|
|
|
|
SdrHelpLineList maHandoutHelpLines;
|
|
|
|
BOOL mbNoColors; // Gliederungsmodus
|
|
|
|
BOOL mbNoAttribs; // Gliederungsmodus
|
|
|
|
Rectangle maVisArea; // Sichtbarer Bereich
|
|
|
|
PageKind mePageKind; // Seitentyp (Standard, Notizen, Handzettel)
|
|
|
|
USHORT mnSelectedPage; // Selektierte Seite
|
|
|
|
PageKind mePageKindOnLoad;
|
|
|
|
USHORT mnSelectedPageOnLoad;
|
|
|
|
EditMode meStandardEditMode; // Editmode im Zeichenmodus (Page/MasterPage)
|
|
|
|
EditMode meNotesEditMode; // Editmode im Notizen-Modus (Page/MasterPage)
|
|
|
|
EditMode meHandoutEditMode; // Editmode im Handzettel-Modus (Page/MasterPage)
|
2005-09-23 13:59:09 +00:00
|
|
|
EditMode meEditModeOnLoad;
|
2006-12-12 16:33:25 +00:00
|
|
|
BOOL mbLayerMode; // Layer an/aus
|
|
|
|
BOOL mbQuickEdit; // QuickEdit an/aus
|
|
|
|
BOOL mbBigHandles; // Grosse Handles
|
|
|
|
BOOL mbDoubleClickTextEdit; // Textmodus nach Doppelklick
|
|
|
|
BOOL mbClickChangeRotation; // Einfachklick wechselt Selektions-/Rotationsmodus
|
|
|
|
USHORT mnPresViewShellId; // ViewShell aus der die Pres. gestartet wurde
|
|
|
|
USHORT mnSlotId; // SlotId, welche initial ausgefuehrt wird
|
|
|
|
USHORT mnSlidesPerRow; // Dias pro Reihe auf dem Diatisch
|
|
|
|
ULONG mnDrawMode; // Drawmode fuer das normale Fenster
|
|
|
|
double mnTabCtrlPercent;
|
2007-08-28 12:37:48 +00:00
|
|
|
/** Remember whether the navigator shows all shapes (<TRUE/>) or only
|
|
|
|
the names ones (<FALSE/>). Not persistent.
|
|
|
|
*/
|
|
|
|
bool mbIsNavigatorShowingAllShapes;
|
2004-01-20 10:33:31 +00:00
|
|
|
|
|
|
|
/** The type of the previous view shell. The (default) value
|
|
|
|
ViewShell::ST_NONE indicates that there was no previous view shell.
|
|
|
|
Note that this value is used only temporarily and is not saved or
|
|
|
|
restored.
|
|
|
|
*/
|
|
|
|
ViewShell::ShellType mePreviousViewShellType;
|
2005-09-23 13:59:09 +00:00
|
|
|
|
|
|
|
ViewShell::ShellType meViewShellTypeOnLoad;
|
2004-01-20 10:33:31 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
} // end of namespace sd
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|