// predefines namespace model { class Theme; } namespace reportdesign { class OSection; } namespace sdr::contact { class ViewContact; } namespace sdr::annotation { class Annotation; } class SdrPage; class SdrModel; class SdrPageView; class SdrLayerAdmin; class SdrLayerIDSet; class Color; class SfxStyleSheet;
//////////////////////////////////////////////////////////////////////////////////////////////////// // // SdrObjList // E3dObjList // SdrPage -> see continuation there
// class SdrObjList class SVXCORE_DLLPUBLIC SdrObjList
{ friendclass SdrObjListIter; friendclass SdrEditView;
private: /// simple ActionChildInserted forwarder to have it on a central place
SAL_DLLPRIVATE staticvoid impChildInserted(SdrObject const & rChild);
// tdf#116879 Clear SdrObjList, no Undo done. Used from destructor, but also // from other places.
SAL_DLLPRIVATE void impClearSdrObjList();
protected: // protected constructor to make clear that this class should only // be used as base for derivations, not naked. See getSdrModelFromSdrObjList // which is pure virtual to force this, too
SAL_DLLPRIVATE SdrObjList();
SAL_DLLPRIVATE virtual ~SdrObjList();
// tdf#116879 clean up everything (without Undo), plus broadcasting // changes. Split to this call and a private one (impClearSdrObjList) // that allows cleanup without broadcasting in the destructor void ClearSdrObjList();
/// remove from list without delete virtual rtl::Reference<SdrObject> NbcRemoveObject(size_t nObjNum); virtual rtl::Reference<SdrObject> RemoveObject(size_t nObjNum);
/// Replace existing object by different one. /// Same as Remove(old)+Insert(new) but faster because the order numbers /// do not have to be set dirty. virtual rtl::Reference<SdrObject> ReplaceObject(SdrObject* pNewObj, size_t nObjNum);
/// Modify ZOrder of an SdrObject virtual SdrObject* SetObjectOrdNum(size_t nOldObjNum, size_t nNewObjNum);
/// Modify ZOrder of an SdrObject, object must already be in the list
SAL_DLLPRIVATE void SetExistingObjectOrdNum(SdrObject* pExistingObj, size_t nNewObjNum);
/// reformat all text objects, e.g. when changing printer
SAL_DLLPRIVATE void NbcReformatAllTextObjects();
SAL_DLLPRIVATE void ReformatAllTextObjects();
/** #103122# reformats all edge objects that are connected to other objects */
SAL_DLLPRIVATE void ReformatAllEdgeObjects();
/// convert attributes of the style to hard formatting
SAL_DLLPRIVATE void BurnInStyleSheetAttributes();
/** Return whether there is an explicit, user defined, object navigation order.Whenthereisonethismethodreturns<TRUE/>andthe GetObjectForNavigationPosition()and SdrObject::GetNavigationPosition()methodswillreturnvalues differentfromthosereturnedbySdrObject::GetOrdNum()and GetObj().
*/ bool HasObjectNavigationOrder() const;
/** Set the navigation position of the given object to the specified value.Notethatthischangesthenavigationpositionforall objectsonorfollowingtheoldornewposition.
*/ void SetObjectNavigationPosition (
SdrObject& rObject, const sal_uInt32 nNewNavigationPosition);
/** Return the object for the given navigation position. When there is auserdefinednavigationorder,i.e.mxNavigationOrderisnotNULL, thenthatisusedtolookuptheobject.Otherwisethez-orderis usedbylookinguptheobjectinmaList. @paramnNavigationPosition Validvaluesinclude0andaresmallerthanthenumberof objectsasreturnedbyGetObjCount(). @return ThereturnedpointerisNULLforinvalidpositions.
*/
SAL_DLLPRIVATE SdrObject* GetObjectForNavigationPosition (const sal_uInt32 nNavigationPosition) const;
/** Restore the navigation order to that defined by the z-order.
*/ void ClearObjectNavigationOrder();
/** Set the navigation position of all SdrObjects to their position in themxNavigationOrderlist.Thismethodreturnsimmediatelywhenno updateisnecessary. @return Thismethodreturns<TRUE/>whenthenavigationpositionsstored inSdrObjectsareuptodate. Itreturns<FALSE/>whenthenavigationpositionsarenotvalid, forexamplebecausenoexplicitnavigationorderhasbeen defined,i.e.HasObjectNavigationOrder()wouldreturn<FALSE/>.
*/
SAL_DLLPRIVATE bool RecalcNavigationPositions();
/** Set the navigation order to the one defined by the given list of XShapeobjects. @paramrxOrder Whenthisisanemptyreferencethenthenavigationorderis resettothez-order.Thepreferredwaytodothis,however,is tocallClearObjectNavigationOrder(). Otherwisethislistisexpectedtocontainalltheshapesinthe calledSdrObjList.
*/ void SetNavigationOrder (const css::uno::Reference<
css::container::XIndexAccess>& rxOrder);
private:
tools::Rectangle maSdrObjListOutRect;
tools::Rectangle maSdrObjListSnapRect;
SdrObjectDeque maList; /// This list, if it exists, defines the navigation order. If it does /// not exist then maList defines the navigation order.
std::optional<std::vector<unotools::WeakReference<SdrObject>>> mxNavigationOrder; bool mbObjOrdNumsDirty; bool mbRectsDirty; /// This flag is <TRUE/> when the mpNavigation list has been changed but /// the indices of the referenced SdrObjects still have their old values. bool mbIsNavigationOrderDirty;
/** Insert an SdrObject into maList. Do not modify the maList member directly. @paramrObject Theobjecttoinsertintotheobjectlist. @paramnInsertPosition Thegivenobjectisinsertedbeforetheobjectatthis position.Validvaluesinclude0(theobjectisinsertedatthe headofthelist)andthenumberofobjectsinthelistas returnedbyGetObjCount()(theobjectisinsertedattheendof thelist.)
*/
SAL_DLLPRIVATE void InsertObjectIntoContainer (
SdrObject& rObject, const sal_uInt32 nInsertPosition);
/** Replace an object in the object list. @paramrObject Thenewobjectthatreplacestheoneinthelistatthe specifiedposition. @paramnObjectPosition Theobjectatthispositionintheobjectlistisreplacedby thegivenobject.Validvaluesinclude0andaresmallerthan thenumberofobjectsinthelist.
*/
SAL_DLLPRIVATE void ReplaceObjectInContainer (
SdrObject& rObject, const sal_uInt32 nObjectPosition);
/** Remove an object from the object list. Theobjectlisthastocontainatleastoneelement. @paramnObjectPosition Theobjectatthispositionisremovedfromtheobjectlist. Validvaluesinclude0andaresmallerthanthenumberof objectsinthelist.
*/
SAL_DLLPRIVATE void RemoveObjectFromContainer ( const sal_uInt32 nObjectPosition);
// class SdrPageProperties class SVXCORE_DLLPUBLIC SdrPageProperties final : public SfxListener, public svl::StyleSheetUser
{ private: // data
SdrPage& mrSdrPage;
SfxStyleSheet* mpStyleSheet;
std::shared_ptr<model::Theme> mpTheme;
SfxItemSet maProperties;
class SVXCORE_DLLPUBLIC SdrPage : public SdrObjList, public cppu::OWeakObject
{ // #i9076# friendclass SdrModel; friendclass SvxUnoDrawPagesAccess;
// this class uses its own UNO wrapper // and thus has to set mxUnoPage (it also relies on mxUnoPage not being WeakRef) friendclass reportdesign::OSection;
// Copying of pages is split into two parts: construction and copying of page objects, // because the copying might need access to fully initialized page. CloneSdrPage() is responsible // to call lateInit() after copy-construction of a new object. Any initialization in derived // classes that needs access to the page objects must be deferred to lateInit. And it must // call lateInit() of its parent class. void lateInit(const SdrPage& rSrcPage);
// derived from SdrObjList, returns this virtual SdrPage* getSdrPageFromSdrObjList() const override;
// #i68775# React on PageNum changes (from Model in most cases) void SetPageNum(sal_uInt16 nNew);
sal_uInt16 GetPageNum() const;
// #i93597# Allow page border definition to not be the full rectangle but to // use only the left and right vertical edges (reportdesigner) void setPageBorderOnlyLeftRight(bool bNew) { mbPageBorderOnlyLeftRight = bNew; } bool getPageBorderOnlyLeftRight() const { return mbPageBorderOnlyLeftRight; }
public: /// changing the layers does not set the modified-flag! const SdrLayerAdmin& GetLayerAdmin() const;
SdrLayerAdmin& GetLayerAdmin();
/// for snap-to-grid in Writer, also for AlignObjects if 1 object is marked /// if pRect != null, then the pages that are intersected by this Rect, /// otherwise the visible pages virtualconst SdrPageGridFrameList* GetGridFrameList(const SdrPageView* pPV, const tools::Rectangle* pRect) const;
/** *deprecated* returns an averaged background color of this page */ // #i75566# GetBackgroundColor -> GetPageBackgroundColor
Color GetPageBackgroundColor() const;
/** *deprecated* returns an averaged background color of this page */ // #i75566# GetBackgroundColor -> GetPageBackgroundColor and bScreenDisplay hint value
Color GetPageBackgroundColor( SdrPageView const * pView, bool bScreenDisplay = true) const;
/** this method returns true if the object from the ViewObjectContact should bevisibleonthispagewhilerendering. bEditselectsifvisibilitytestisforaneditingvieworafinalrender, likeprinting.
*/ virtualbool checkVisibility( const sdr::contact::ViewObjectContact& rOriginal, const sdr::contact::DisplayInfo& rDisplayInfo, bool bEdit );
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.