22 #include <osl/diagnose.h>
34 #include <viewimp.hxx>
44 #include <accessibilityoptions.hxx>
71 aMode.SetScaleX( aNewFactor );
72 aMode.SetScaleY( aNewFactor );
84 mpOpt->SetReadonly(
true );
86 SAL_INFO(
"sw.core",
"View::Init - before InitPrt" );
93 const bool bBrowseMode =
mpOpt->getBrowseMode();
101 mxDoc->CheckDefaultPageFormat();
104 SAL_INFO(
"sw.core",
"View::Init - after InitPrt" );
135 if(
GetDoc()->isXForms() )
149 mpSfxViewShell( nullptr ),
152 mpOut( pOutput ? pOutput
154 : static_cast<
OutputDevice*>(rDocument.getIDocumentDeviceAccess().getPrinter( true ))),
156 mbShowHeaderSeparator( false ),
157 mbShowFooterSeparator( false ),
158 mbHeaderFooterEdit( false ),
159 mpTargetPaintWindow(nullptr),
160 mpBufferedOut(nullptr),
165 mbOutputToWindow(false),
166 mpPrePostOutDev(nullptr),
180 const bool bIsDocModified(
mxDoc->getIDocumentState().IsModified() );
190 mpImp->InitPagePreviewLayout();
196 SetHiddenFlag( !
mpOpt->IsShowHiddenField() );
199 if ( !
mxDoc->GetIDocumentUndoRedo().IsUndoNoResetModified()
202 mxDoc->getIDocumentState().ResetModified();
218 maBrowseBorder( rShell.maBrowseBorder ),
219 mpSfxViewShell( nullptr ),
222 mpOut( pOutput ? pOutput
224 : static_cast<
OutputDevice*>(rShell.GetDoc()->getIDocumentDeviceAccess().getPrinter( true ))),
226 mbShowHeaderSeparator( false ),
227 mbShowFooterSeparator( false ),
228 mbHeaderFooterEdit( false ),
229 mpTargetPaintWindow(nullptr),
230 mpBufferedOut(nullptr),
231 mxDoc( rShell.GetDoc() ),
235 mbOutputToWindow(false),
236 mpPrePostOutDev(nullptr),
253 bool bModified =
mxDoc->getIDocumentState().IsModified();
260 mpImp->InitPagePreviewLayout();
263 SetHiddenFlag( !
mpOpt->IsShowHiddenField() );
266 if( !bModified && !
mxDoc->GetIDocumentUndoRedo().IsUndoNoResetModified() )
268 mxDoc->getIDocumentState().ResetModified();
284 =
mxDoc ? &
mxDoc->getIDocumentLayoutAccess() :
nullptr;
299 while (
nullptr != (pStNd = aIdx.GetNode().
GetStartNode()) )
303 if (
nullptr != pGNd )
310 OSL_ENSURE( pFrame->IsNoTextFrame(),
"GraphicNode with Text?" );
325 if(
mxDoc->getReferenceCount() > 1 )
const SwEndNode * EndOfSectionNode() const
Starts a section of nodes in the document model.
OutDevType GetOutDevType() const
Base class of the Writer layout elements.
SwViewShell(SwViewShell &, vcl::Window *pWin, OutputDevice *pOut=nullptr, tools::Long nFlags=0)
CTor for further Shells on a document.
SwNode & GetEndOfAutotext() const
Section for all Flys/Header/Footers.
virtual ~SwViewShell() override
VclPtr< OutputDevice > mpOut
Window, Printer, VirtDev, ...
VclPtr< vcl::Window > mpWin
= 0 during printing or pdf export
const MapMode & GetMapMode() const
std::unique_ptr< SwViewShellImp > mpImp
static void DestroyFrame(SwFrame *const pFrame)
this is the only way to delete a SwFrame instance
#define VSHELLFLAG_SHARELAYOUT
The root element of a Writer document layout.
static SwCache * GetTextCache()
std::shared_ptr< SwRootFrame > SwRootFramePtr
static void Init(const OutputDevice *pWin)
rtl::Reference< SwDoc > mxDoc
The document; never 0.
void InitPrt(OutputDevice *pOutDev)
void DecreaseMax(const sal_uInt16 nSub)
const IDocumentDrawModelAccess & getIDocumentDrawModelAccess() const
Provides access to the document draw model interface.
void IncreaseMax(const sal_uInt16 nAdd)
const SwStartNode * StartOfSectionNode() const
std::unique_ptr< SwAccessibilityOptions > mpAccOptions
sal_uInt16 GetHtmlMode(const SwDocShell *pShell)
virtual const SwDrawModel * GetDrawModel() const =0
Draw Model and id accessors.
void DeRegisterShell(SwViewShell *pSh)
Marks a node in the document model.
ring_container GetRingContainer()
SwStartNode * GetStartNode()
IDocumentLayoutAccess const & getIDocumentLayoutAccess() const
static void Remove(SwViewShell const *pSh)
SwDrawView * GetDrawView()
void StopNumRuleAnimations(const OutputDevice *)
virtual const SwViewShell * GetCurrentViewShell() const =0
Returns the layout set at the document.
const SwViewOption * GetViewOptions() const
vcl::Window * GetWin() const
SdrView * GetDrawViewWithValidMarkList()
#define SAL_INFO(area, stream)
#define VSHELLFLAG_ISPREVIEW
bool HasDrawView() const
New Interface for StarView Drawing.
Provides access to the layout of a document.
virtual void SetCurrentViewShell(SwViewShell *pNew)=0
!!!The old layout must be deleted!!!
std::unique_ptr< SwViewOption > mpOpt
SAL_DLLPRIVATE void Init(const SwViewOption *pNewOpt)
SwRootFrame * GetLayout() const
bool HasDrawViewDrag() const
sal_uInt16 mnStartAction
!= 0 if at least one Action is active.