SmDocShell Class Reference

#include <document.hxx>

Collaboration diagram for SmDocShell:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 TYPEINFO ()
 SFX_DECL_OBJECTFACTORY ()
 SmDocShell (SfxObjectCreateMode eMode=SFX_CREATE_MODE_EMBEDDED)
virtual ~SmDocShell ()
void LoadSymbols ()
void SaveSymbols ()
void ArrangeFormula ()
BOOL HasPrinter ()
SfxPrinter * GetPrinter ()
void SetPrinter (SfxPrinter *)
const String & GetComment () const
sal_Bool ReplaceBadChars ()
void UpdateText ()
void SetText (const String &rBuffer)
String & GetText ()
void SetFormat (SmFormat &rFormat)
const SmFormatGetFormat ()
void Parse ()
SmParserGetParser ()
const SmNodeGetFormulaTree () const
void SetFormulaTree (SmNode *&rTree)
String GetAccessibleText ()
EditEngine & GetEditEngine ()
SfxItemPool & GetEditEngineItemPool ()
void Draw (OutputDevice &rDev, Point &rPosition)
Size GetSize ()
void Repaint ()
virtual SfxUndoManager * GetUndoManager ()
virtual SfxItemPool & GetPool () const
void Execute (SfxRequest &rReq)
void GetState (SfxItemSet &)
virtual void SetVisArea (const Rectangle &rVisArea)
virtual void SetModified (BOOL bModified)

Private Member Functions

virtual void SFX_NOTIFY (SfxBroadcaster &rBC, const TypeId &rBCType, const SfxHint &rHint, const TypeId &rHintType)
BOOL WriteAsMathType3 (SfxMedium &)
virtual void Draw (OutputDevice *pDevice, const JobSetup &rSetup, USHORT nAspect=ASPECT_CONTENT)
virtual void FillClass (SvGlobalName *pClassName, sal_uInt32 *pFormat, String *pAppName, String *pFullTypeName, String *pShortTypeName, sal_Int32 nFileFormat) const
virtual BOOL SetData (const String &rData)
virtual ULONG GetMiscStatus () const
virtual void OnDocumentPrinterChanged (Printer *)
virtual sal_Bool InitNew (const::com::sun::star::uno::Reference< ::com::sun::star::embed::XStorage > &xStorage)
virtual BOOL Load (SfxMedium &rMedium)
void ImplSave (SvStorageStreamRef xStrm)
virtual BOOL Save ()
virtual BOOL SaveAs (SfxMedium &rMedium)
virtual BOOL ConvertTo (SfxMedium &rMedium)
virtual BOOL SaveCompleted (const::com::sun::star::uno::Reference< ::com::sun::star::embed::XStorage > &xStorage)
Printer * GetPrt ()
OutputDevice * GetRefDev ()
BOOL IsFormulaArranged () const
void SetFormulaArranged (BOOL bVal)
virtual BOOL ConvertFrom (SfxMedium &rMedium)

Private Attributes

String aText
SmFormat aFormat
SmParser aInterpreter
String aAccText
SmNodepTree
SfxMenuBarManager * pMenuMgr
SfxItemPool * pEditEngineItemPool
EditEngine * pEditEngine
SfxPrinter * pPrinter
Printer * pTmpPrinter
long nLeftBorder
long nRightBorder
long nTopBorder
long nBottomBorder
USHORT nModifyCount
BOOL bIsFormulaArranged

Friends

class SmPrinterAccess
class SmModel

Detailed Description

Definition at line 129 of file document.hxx.


Constructor & Destructor Documentation

SmDocShell::SmDocShell ( SfxObjectCreateMode  eMode = SFX_CREATE_MODE_EMBEDDED  ) 

Definition at line 806 of file document.cxx.

References aFormat, SmModule::GetConfig(), GetPool(), SmMathConfig::GetStandardFormat(), SM_MOD1, and SmModel.

SmDocShell::~SmDocShell (  )  [virtual]

Definition at line 833 of file document.cxx.

References aFormat, SmModule::GetConfig(), pEditEngine, pEditEngineItemPool, pPrinter, pTree, and SM_MOD1.


Member Function Documentation

virtual void SmDocShell::SFX_NOTIFY ( SfxBroadcaster &  rBC,
const TypeId &  rBCType,
const SfxHint &  rHint,
const TypeId &  rHintType 
) [private, virtual]

BOOL SmDocShell::WriteAsMathType3 ( SfxMedium &   )  [private]

Definition at line 1502 of file document.cxx.

References aText, MathType::ConvertFromStarMath(), and pTree.

Referenced by ConvertTo().

void SmDocShell::Draw ( OutputDevice *  pDevice,
const JobSetup &  rSetup,
USHORT  nAspect = ASPECT_CONTENT 
) [private, virtual]

Definition at line 1407 of file document.cxx.

Referenced by SmViewShell::Impl_Print(), and SmGraphicWindow::Paint().

void SmDocShell::FillClass ( SvGlobalName *  pClassName,
sal_uInt32 *  pFormat,
String *  pAppName,
String *  pFullTypeName,
String *  pShortTypeName,
sal_Int32  nFileFormat 
) const [private, virtual]

Definition at line 1460 of file document.cxx.

BOOL SmDocShell::SetData ( const String &  rData  )  [private, virtual]

Definition at line 849 of file document.cxx.

References SetText().

ULONG SmDocShell::GetMiscStatus (  )  const [private, virtual]

Definition at line 1485 of file document.cxx.

void SmDocShell::OnDocumentPrinterChanged ( Printer *   )  [private, virtual]

Definition at line 772 of file document.cxx.

References aText, GetSize(), pTmpPrinter, Repaint(), SetFormulaArranged(), and SetModified().

Referenced by SetText().

virtual sal_Bool SmDocShell::InitNew ( const ::com::sun::star::uno::Reference< ::com::sun::star::embed::XStorage > &  xStorage  )  [private, virtual]

BOOL SmDocShell::Load ( SfxMedium &  rMedium  )  [private, virtual]

Definition at line 927 of file document.cxx.

References C2S, SmXMLWrapper::Import(), Repaint(), and SetFormulaArranged().

void SmDocShell::ImplSave ( SvStorageStreamRef  xStrm  )  [private]

BOOL SmDocShell::Save (  )  [private, virtual]

Definition at line 961 of file document.cxx.

References ArrangeFormula(), SmXMLWrapper::Export(), IsFormulaArranged(), Parse(), pTree, SmXMLWrapper::SetFlat(), and UpdateText().

BOOL SmDocShell::SaveAs ( SfxMedium &  rMedium  )  [private, virtual]

Definition at line 1032 of file document.cxx.

References ArrangeFormula(), SmXMLWrapper::Export(), IsFormulaArranged(), Parse(), pTree, SmXMLWrapper::SetFlat(), and UpdateText().

BOOL SmDocShell::ConvertTo ( SfxMedium &  rMedium  )  [private, virtual]

Definition at line 1056 of file document.cxx.

References ArrangeFormula(), SmXMLWrapper::Export(), IsFormulaArranged(), MATHML_XML, Parse(), pTree, SmXMLWrapper::SetFlat(), STAROFFICE_XML, and WriteAsMathType3().

BOOL SmDocShell::SaveCompleted ( const ::com::sun::star::uno::Reference< ::com::sun::star::embed::XStorage > &  xStorage  )  [private, virtual]

Definition at line 1090 of file document.cxx.

Printer * SmDocShell::GetPrt (  )  [private]

Definition at line 710 of file document.cxx.

References SmConfig::ConfigToItemSet(), SmModule::GetConfig(), GetPool(), pPrinter, pTmpPrinter, and SM_MOD1.

Referenced by GetPrinter(), GetRefDev(), and SmPrinterAccess::SmPrinterAccess().

OutputDevice * SmDocShell::GetRefDev (  )  [private]

Definition at line 746 of file document.cxx.

References GetPrt().

Referenced by SmPrinterAccess::SmPrinterAccess().

BOOL SmDocShell::IsFormulaArranged (  )  const [inline, private]

Definition at line 183 of file document.hxx.

References bIsFormulaArranged.

Referenced by ArrangeFormula(), ConvertTo(), Draw(), GetAccessibleText(), GetSize(), Save(), and SaveAs().

void SmDocShell::SetFormulaArranged ( BOOL  bVal  )  [inline, private]

Definition at line 184 of file document.hxx.

References bIsFormulaArranged.

Referenced by ArrangeFormula(), ConvertFrom(), Load(), OnDocumentPrinterChanged(), Parse(), Repaint(), SetFormat(), SetPrinter(), and SetText().

BOOL SmDocShell::ConvertFrom ( SfxMedium &  rMedium  )  [private, virtual]

Definition at line 858 of file document.cxx.

References aText, C2S, SmXMLWrapper::Import(), MATHML_XML, Parse(), pTree, Repaint(), SetFormulaArranged(), and STAROFFICE_XML.

SmDocShell::TYPEINFO (  ) 

SmDocShell::SFX_DECL_OBJECTFACTORY (  ) 

void SmDocShell::LoadSymbols (  ) 

Definition at line 272 of file document.cxx.

References SmModule::GetSymSetManager(), SmSymSetManager::Load(), and SM_MOD1.

Referenced by Execute().

void SmDocShell::SaveSymbols (  ) 

Definition at line 1398 of file document.cxx.

References SmModule::GetSymSetManager(), SmSymSetManager::Save(), and SM_MOD1.

Referenced by Execute().

void SmDocShell::ArrangeFormula (  ) 

Definition at line 376 of file document.cxx.

References aAccText, SmNode::Arrange(), GetFormat(), SmViewShell::GetGraphicWindow(), SmPrinterAccess::GetRefDev(), IsFormulaArranged(), SmNode::Prepare(), pTree, SetFormulaArranged(), SM_MOD1, and SmGetActiveView().

Referenced by ConvertTo(), Draw(), GetAccessibleText(), GetSize(), IMPL_LINK(), Save(), and SaveAs().

BOOL SmDocShell::HasPrinter (  )  [inline]

Definition at line 206 of file document.hxx.

References pPrinter.

Referenced by SmViewShell::GetPrinter().

SfxPrinter* SmDocShell::GetPrinter (  )  [inline]

Definition at line 207 of file document.hxx.

References GetPrt(), and pPrinter.

Referenced by SmViewShell::Execute(), Execute(), and SmViewShell::GetPrinter().

void SmDocShell::SetPrinter ( SfxPrinter *   ) 

Definition at line 761 of file document.cxx.

References pPrinter, Repaint(), and SetFormulaArranged().

Referenced by SmViewShell::SetPrinter().

const String & SmDocShell::GetComment (  )  const

Definition at line 281 of file document.cxx.

sal_Bool SmDocShell::ReplaceBadChars (  ) 

Definition at line 987 of file document.cxx.

References aText, and pEditEngine.

Referenced by Parse().

void SmDocShell::UpdateText (  ) 

Definition at line 1019 of file document.cxx.

References GetText(), pEditEngine, and SetText().

Referenced by SmViewShell::Execute(), IMPL_LINK(), Save(), and SaveAs().

void SmDocShell::SetText ( const String &  rBuffer  ) 

Definition at line 289 of file document.cxx.

References aText, SmGraphicWindow::GetAccessible_Impl(), SmViewShell::GetGraphicWindow(), SmGraphicAccessible::LaunchEvent(), OnDocumentPrinterChanged(), Parse(), Repaint(), SetFormulaArranged(), SetModified(), and SmGetActiveView().

Referenced by SmViewShell::Activate(), SmXMLImport::endDocument(), SmViewShell::Execute(), Execute(), SetData(), and UpdateText().

String& SmDocShell::GetText (  )  [inline]

Definition at line 217 of file document.hxx.

References aText.

Referenced by SmXMLImport::endDocument(), Execute(), SmGraphicAccessible::getAccessibleDescription(), GetEditEngine(), GetState(), SmViewShell::Insert(), SmViewShell::InsertFrom(), and UpdateText().

void SmDocShell::SetFormat ( SmFormat rFormat  ) 

Definition at line 336 of file document.cxx.

References aFormat, SetFormulaArranged(), SetModified(), and SmGetActiveView().

Referenced by Execute(), SmFormatAction::Redo(), and SmFormatAction::Undo().

const SmFormat& SmDocShell::GetFormat (  )  [inline]

Definition at line 219 of file document.hxx.

References aFormat.

Referenced by ArrangeFormula(), Execute(), and GetState().

void SmDocShell::Parse (  ) 

Definition at line 363 of file document.cxx.

References aInterpreter, aText, nModifyCount, SmParser::Parse(), pTree, ReplaceBadChars(), and SetFormulaArranged().

Referenced by ConvertFrom(), ConvertTo(), Draw(), GetSize(), SmViewShell::Insert(), SmViewShell::InsertFrom(), Save(), SaveAs(), and SetText().

SmParser& SmDocShell::GetParser (  )  [inline]

Definition at line 222 of file document.hxx.

References aInterpreter.

Referenced by SmXMLImport::endDocument(), SmViewShell::NextError(), and SmViewShell::PrevError().

const SmNode* SmDocShell::GetFormulaTree (  )  const [inline]

Definition at line 223 of file document.hxx.

References pTree.

Referenced by SmGraphicAccessible::getCharacterBounds(), SmGraphicWindow::MouseButtonDown(), SmGraphicWindow::SetCursor(), and SmGraphicWindow::SetCursorPos().

void SmDocShell::SetFormulaTree ( SmNode *&  rTree  )  [inline]

Definition at line 224 of file document.hxx.

References pTree.

Referenced by SmXMLImport::endDocument().

String SmDocShell::GetAccessibleText (  ) 

Definition at line 348 of file document.cxx.

References aAccText, ArrangeFormula(), SmNode::GetAccessibleText(), IsFormulaArranged(), and pTree.

Referenced by SmGraphicAccessible::GetAccessibleText_Impl().

EditEngine & SmDocShell::GetEditEngine (  ) 

Definition at line 502 of file document.cxx.

References C2S, GetText(), pEditEngine, pEditEngineItemPool, and SetEditEngineDefaultFonts().

Referenced by SmViewShell::Activate(), SmEditWindow::GetEditEngine(), GetEditEngineItemPool(), and GetUndoManager().

SfxItemPool & SmDocShell::GetEditEngineItemPool (  ) 

Definition at line 550 of file document.cxx.

References GetEditEngine(), and pEditEngineItemPool.

Referenced by SmEditWindow::GetEditEngineItemPool().

void SmDocShell::Draw ( OutputDevice &  rDev,
Point &  rPosition 
)

Definition at line 561 of file document.cxx.

References aFormat, ArrangeFormula(), DIS_LEFTSPACE, DIS_TOPSPACE, SmNode::Draw(), SmFormat::GetDistance(), IsFormulaArranged(), Parse(), and pTree.

Size SmDocShell::GetSize (  ) 

Definition at line 614 of file document.cxx.

References aFormat, ArrangeFormula(), DIS_BOTTOMSPACE, DIS_LEFTSPACE, DIS_RIGHTSPACE, DIS_TOPSPACE, SmFormat::GetDistance(), SmRect::GetSize(), IsFormulaArranged(), Parse(), and pTree.

Referenced by OnDocumentPrinterChanged(), Repaint(), SmGraphicWindow::SetTotalSize(), and SmGraphicWindow::ZoomToFitInWindow().

void SmDocShell::Repaint (  ) 

Definition at line 785 of file document.cxx.

References SmViewShell::GetGraphicWindow(), GetSize(), SetFormulaArranged(), and SmGetActiveView().

Referenced by ConvertFrom(), SmViewShell::Execute(), Execute(), IMPL_LINK(), Load(), OnDocumentPrinterChanged(), SetPrinter(), and SetText().

SfxUndoManager * SmDocShell::GetUndoManager (  )  [virtual]

Definition at line 1388 of file document.cxx.

References GetEditEngine(), and pEditEngine.

Referenced by Execute(), and GetState().

SfxItemPool & SmDocShell::GetPool (  )  const [virtual]

Definition at line 1418 of file document.cxx.

Referenced by GetPrt(), and SmDocShell().

void SmDocShell::Execute ( SfxRequest &  rReq  ) 

Definition at line 1101 of file document.cxx.

References SmModule::GetConfig(), GetFormat(), GetPrinter(), SmMathConfig::GetStandardFormat(), GetText(), GetUndoManager(), SmMathConfig::IsAutoRedraw(), LoadSymbols(), SmAlignDialog::ReadFrom(), SmDistanceDialog::ReadFrom(), SmFontSizeDialog::ReadFrom(), SmFontTypeDialog::ReadFrom(), Repaint(), SaveSymbols(), SmMathConfig::SetAutoRedraw(), SetFormat(), SmMathConfig::SetStandardFormat(), SetText(), SmFormat::SetTextmode(), SM_MOD1, SmAlignDialog::WriteTo(), SmDistanceDialog::WriteTo(), SmFontSizeDialog::WriteTo(), and SmFontTypeDialog::WriteTo().

void SmDocShell::GetState ( SfxItemSet &   ) 

Definition at line 1293 of file document.cxx.

References SmModule::GetConfig(), GetFormat(), GetText(), GetUndoManager(), SmMathConfig::IsAutoRedraw(), nModifyCount, and SM_MOD1.

void SmDocShell::SetVisArea ( const Rectangle &  rVisArea  )  [virtual]

Definition at line 1423 of file document.cxx.

void SmDocShell::SetModified ( BOOL  bModified  )  [virtual]

Definition at line 1491 of file document.cxx.

Referenced by SmViewShell::Insert(), SmViewShell::InsertFrom(), OnDocumentPrinterChanged(), SetFormat(), and SetText().


Friends And Related Function Documentation

friend class SmPrinterAccess [friend]

Definition at line 131 of file document.hxx.

friend class SmModel [friend]

Definition at line 132 of file document.hxx.

Referenced by SmDocShell().


Member Data Documentation

String SmDocShell::aText [private]

Definition at line 134 of file document.hxx.

Referenced by ConvertFrom(), GetText(), OnDocumentPrinterChanged(), Parse(), ReplaceBadChars(), SetText(), and WriteAsMathType3().

SmFormat SmDocShell::aFormat [private]

Definition at line 135 of file document.hxx.

Referenced by Draw(), GetFormat(), GetSize(), SetFormat(), SmDocShell(), and ~SmDocShell().

SmParser SmDocShell::aInterpreter [private]

Definition at line 136 of file document.hxx.

Referenced by GetParser(), and Parse().

String SmDocShell::aAccText [private]

Definition at line 137 of file document.hxx.

Referenced by ArrangeFormula(), and GetAccessibleText().

SmNode* SmDocShell::pTree [private]

Definition at line 138 of file document.hxx.

Referenced by ArrangeFormula(), ConvertFrom(), ConvertTo(), Draw(), GetAccessibleText(), GetFormulaTree(), GetSize(), Parse(), Save(), SaveAs(), SetFormulaTree(), WriteAsMathType3(), and ~SmDocShell().

SfxMenuBarManager* SmDocShell::pMenuMgr [private]

Definition at line 139 of file document.hxx.

SfxItemPool* SmDocShell::pEditEngineItemPool [private]

Definition at line 140 of file document.hxx.

Referenced by GetEditEngine(), GetEditEngineItemPool(), and ~SmDocShell().

EditEngine* SmDocShell::pEditEngine [private]

Definition at line 141 of file document.hxx.

Referenced by GetEditEngine(), GetUndoManager(), ReplaceBadChars(), UpdateText(), and ~SmDocShell().

SfxPrinter* SmDocShell::pPrinter [private]

Definition at line 142 of file document.hxx.

Referenced by GetPrinter(), GetPrt(), HasPrinter(), SetPrinter(), and ~SmDocShell().

Printer* SmDocShell::pTmpPrinter [private]

Definition at line 143 of file document.hxx.

Referenced by GetPrt(), and OnDocumentPrinterChanged().

long SmDocShell::nLeftBorder [private]

Definition at line 144 of file document.hxx.

long SmDocShell::nRightBorder [private]

Definition at line 144 of file document.hxx.

long SmDocShell::nTopBorder [private]

Definition at line 144 of file document.hxx.

long SmDocShell::nBottomBorder [private]

Definition at line 144 of file document.hxx.

USHORT SmDocShell::nModifyCount [private]

Definition at line 148 of file document.hxx.

Referenced by GetState(), and Parse().

BOOL SmDocShell::bIsFormulaArranged [private]

Definition at line 149 of file document.hxx.

Referenced by IsFormulaArranged(), and SetFormulaArranged().


The documentation for this class was generated from the following files:
Generated on Wed Feb 20 17:23:10 2008 for maths by  doxygen 1.5.1