InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
ISection Class Referenceabstract

#include <ISection.h>

Inheritance diagram for ISection:
IPMUnknown

Public Types

enum  { kDefaultIID = IID_ISECTION }
 
enum  PaginationOption { kInvalidPaginationOption = -1, kAutomatic = 0, kFromLastPage }
 

Public Member Functions

virtual void Set (PMString &sectionName, PMString &sectionMarker, UID startPageUID, int32 startPageNumber, ClassID styleProviderClassID, bool16 bContinueFromPrevSection=kFalse, int32 offsetFromPrevSection=0)=0
 
virtual void SetName (PMString &sectionName)=0
 
virtual void SetMarker (PMString &markerName)=0
 
virtual void SetStartPageUID (UID startPageUID)=0
 
virtual void SetStartPageNumber (int32 startPageNumber)=0
 
virtual void SetNonHiddenStartPageNumber (int32 nonHiddenStartPageNumber)=0
 
virtual void SetStyleInfo (ClassID styleProviderClassID)=0
 
virtual void SetContinueFromPrevSection (bool16 bContinueFromPrevSection, int32 offset=0)=0
 
virtual void SetPageNumberIncludeSectionPrefix (bool16 includeSectionPrefix)=0
 
virtual void SetNamedLayout (const PMString &namedLayout)=0
 
virtual void GetName (PMString *pName)=0
 
virtual void GetMarker (PMString *pMarker)=0
 
virtual UID GetStartPageUID ()=0
 
virtual UID GetNonHiddenStartPageUID ()=0
 
virtual int32 GetStartPageNumber ()=0
 
virtual int32 GetNonHiddenStartPageNumber ()=0
 
virtual void GetStyleInfo (ClassID *styleProviderClassID)=0
 
virtual bool16 IsDefaultSection ()=0
 
virtual bool16 GetContinueFromPrevSection ()=0
 
virtual int32 GetOffsetFromPrevSection ()=0
 
virtual bool16 GetPageNumberIncludeSectionPrefix ()=0
 
virtual int32 GetNumPages (const bool16 bRequireNamedLayout=kFalse)=0
 
virtual void GetNamedLayout (PMString *pNamedLayout)=0
 
virtual PaginationOption GetPaginationOption ()=0
 
virtual void SetPaginationOption (PaginationOption option)=0
 
virtual UID GetPaginationMaster ()=0
 
virtual void SetPaginationMaster (UID masterUID)=0
 
virtual void RecalculateNonHiddenPageUID ()=0
 
- Public Member Functions inherited from IPMUnknown
virtual IPMUnknownQueryInterface (PMIID interfaceID) const =0
 
virtual void AddRef () const =0
 
virtual void Release () const =0
 

Detailed Description

Abstract interface for describing a section. A section is an object, always owned by a page in a document, that is used for page numbering and page shuffling purposes.

See Also
ISectionList.h

Member Enumeration Documentation

Pagination options for adding and removing pages in an alternate layout in HTML5
Enumerator
kAutomatic 

Not a legitimate value, used in command for skipping setting this value.

kFromLastPage 

Add/Remove pages automatically in HTML5 pagination (takes into account Optional pages).

Member Function Documentation

virtual bool16 ISection::GetContinueFromPrevSection ()
pure virtual

Is the page number to continue from the last page number of the previous section?

Returns
bool16
virtual void ISection::GetMarker (PMStringpMarker)
pure virtual

Returns the section marker. Used when section marker is inserted on page.

Parameters
pMarker
virtual void ISection::GetName (PMStringpName)
pure virtual

Return the name (prefix) of the section. Used in page number specification.

Parameters
pName
virtual void ISection::GetNamedLayout (PMStringpNamedLayout)
pure virtual

Return the layout name for this section, maybe be kNullString.

Parameters
pNamedLayout
virtual int32 ISection::GetNonHiddenStartPageNumber ()
pure virtual

returns the first non hidden page number of the section(non hidden pages till prev sections). If page numbering is set to continue from previous section, returns the correct page number by looking back in section list.

Returns
int32
virtual UID ISection::GetNonHiddenStartPageUID ()
pure virtual

Returns UID of first non hidden page in the section, kInvalidUID for the default section of the document (on page 1).

Returns
UID
virtual int32 ISection::GetNumPages (const bool16 bRequireNamedLayout = kFalse)
pure virtual

Return the number of pages in this section. All sections have at least 1 page.

Parameters
bRequireNamedLayout- if kTrue, number of pages will be all within the same named layout, which could span several non-named sections. kFalse means number of pages until next section.
Returns
int32
virtual int32 ISection::GetOffsetFromPrevSection ()
pure virtual

Return the offset value for numbering from previous section. Used when GetContinueFromPrevSection is kTrue.

Returns
int32
virtual bool16 ISection::GetPageNumberIncludeSectionPrefix ()
pure virtual

Does the page number have the section prefix included in it?

Returns
bool16
virtual UID ISection::GetPaginationMaster ()
pure virtual

Return the master to use when pages are added doing HTML5 pagination.

Returns
UID, either a UID of a specific master spread, or kInvalidUID when masters are being automatically applied.
virtual PaginationOption ISection::GetPaginationOption ()
pure virtual

Return the pagination option for adding and removing pages used when doing HTML5 pagination.

Returns
AddPageOption
See Also
AddPageOption enum for values.
virtual int32 ISection::GetStartPageNumber ()
pure virtual

returns the first page number of the section. If page numbering is set to continue from previous section, returns the correct page number by looking back in section list.

Returns
int32
virtual UID ISection::GetStartPageUID ()
pure virtual

Returns UID of first page in the section, kInvalidUID for the default section of the document (on page 1).

Returns
UID
virtual void ISection::GetStyleInfo (ClassIDstyleProviderClassID)
pure virtual

Returns info about page numbering style (Roman, numberic, etc.)

Parameters
styleProviderClassID
See Also
SectionClass.fr
virtual bool16 ISection::IsDefaultSection ()
pure virtual

Is this the default section? default section cannot be deleted,

Returns
bool16
virtual void ISection::RecalculateNonHiddenPageUID ()
pure virtual

(For Internal Use Only) Recalculate the non hidden start page UID of the section

virtual void ISection::Set (PMStringsectionName,
PMStringsectionMarker,
UID startPageUID,
int32 startPageNumber,
ClassID styleProviderClassID,
bool16 bContinueFromPrevSection = kFalse,
int32 offsetFromPrevSection = 0 
)
pure virtual

Set all the attributes of a section.

Parameters
sectionNamea PMString reference to the name of the new section
sectionMarkera PMString reference to the section marker of the new section
startPageUIDa UID of the page to associate this section with.
startPageNumberthe starting page number of the section
styleProviderClassIDthe class id for the page numbering style
bContinueFromPrevSectionthe section numbering to continue or not from previous section.
offsetFromPrevSectionoffset from previous section for page numbering
See Also
kNewSectionCmdBoss
kSetSectionPaginationOptionsBoss
IPageList.h
virtual void ISection::SetContinueFromPrevSection (bool16 bContinueFromPrevSection,
int32 offset = 0 
)
pure virtual

Set the section numbering to continue from previous section.

Parameters
bContinueFromPrevSectionkTrue or kFalse
offsetint32 value
virtual void ISection::SetMarker (PMStringmarkerName)
pure virtual

Set the name of the section marker, can be used on the page as a special character, kTextChar_SectionName.

Parameters
markerNamethe name of the marker.
virtual void ISection::SetName (PMStringsectionName)
pure virtual

Set the name of the section (the prefix). May be empty.

Parameters
sectionNamethe name of the section.
virtual void ISection::SetNamedLayout (const PMStringnamedLayout)
pure virtual

Set the name of a named layout. May be empty.

Parameters
namedLayoutthe name for the named layout.
virtual void ISection::SetNonHiddenStartPageNumber (int32 nonHiddenStartPageNumber)
pure virtual

(For Internal Use Only) Set the non hidden starting page number of the section. Ranges from kMinPageNumber to kMaxPageNumber. The non-hidden starting page number is based on the setting that determines whether the section's page numbering continues from the previous section.

  • If the section's page numbering continues from the previous section, the non-hidden starting page number is the total number of non-hidden pages up to the previous section + 1.
  • If the section's page numbering does not continue from the previous section, the non-hidden starting page number is the same as the starting page number of the section.
    Parameters
    nonHiddenStartPageNumber
    Returns
    int32 The non-hidden starting page number of the section.
virtual void ISection::SetPageNumberIncludeSectionPrefix (bool16 includeSectionPrefix)
pure virtual

Whether the section prefix (name) should be used when making page numbers for the section.

Parameters
includeSectionPrefix
virtual void ISection::SetPaginationMaster (UID masterUID)
pure virtual

Set the master page to use when pages are added when doing HTML5 pagination.

Parameters
UID,theUID of a specific master spread, or kInvalidUID to automatically apply a master page.
virtual void ISection::SetPaginationOption (PaginationOption option)
pure virtual

Set the pagination option for how pages are added and removed when doing HTML5 pagination.

Parameters
PaginationOption,oneof the values from this enum
virtual void ISection::SetStartPageNumber (int32 startPageNumber)
pure virtual

Set the starting page number of the section. Ranges from kMinPageNumber to kMaxPageNumber.

Parameters
startPageNumber
virtual void ISection::SetStartPageUID (UID startPageUID)
pure virtual

The starting page UID for this section. kInvalidUID is assigned to the section on first page of document.

Parameters
startPageUID
virtual void ISection::SetStyleInfo (ClassID styleProviderClassID)
pure virtual

Set the class id for the page numbering style. This is the class id of the boss with a INumberConverter.h implementation. kArabicPageNumberingStyleServiceBoss is the default.

Parameters
styleProviderClassID
See Also
INumberConverter.h
SectionClass.fr