Dillo v3.1.1-11-g8f0909b7
No Matches
dw::oof::OOFAwareWidget::OOFAwareWidgetIterator Class Referenceabstract

#include <oofawarewidget.hh>

Public Member Functions

 OOFAwareWidgetIterator (OOFAwareWidget *widget, core::Content::Type mask, bool atEnd, int numContentsInFlow)
void intoStringBuffer (lout::misc::StringBuffer *sb)
 Store a textual representation of the object in a misc::StringBuffer.
int compareTo (lout::object::Comparable *other)
 Compare two objects, this and other.
bool next ()
 Move iterator forward and store content it.
bool prev ()
 Move iterator backward and store content it.
- Public Member Functions inherited from dw::core::Iterator
bool equals (Object *other)
 Returns, whether two objects are equal.
WidgetgetWidget ()
ContentgetContent ()
Content::Type getMask ()
virtual void unref ()
 Delete the iterator.
virtual void highlight (int start, int end, HighlightLayer layer)=0
 Extend highlighted region to contain part of the current content.
virtual void unhighlight (int direction, HighlightLayer layer)=0
 Shrink highlighted region to no longer contain the current content.
virtual void getAllocation (int start, int end, Allocation *allocation)=0
 Return the shape, which a part of the item, the iterator points on, allocates.
IteratorcloneIterator ()
- Public Member Functions inherited from lout::object::Object
virtual ~Object ()
 The destructor is defined as virtual (but not abstract), so that destruction of Object's works properly.
virtual int hashValue ()
 Return a hash value for the object.
virtual Objectclone ()
 Return an exact copy of the object.
const char * toString ()
 Use object::Object::intoStringBuffer to return a textual representation of the object.
virtual size_t sizeOf ()
 Return the number of bytes, this object totally uses.

Protected Member Functions

virtual int numContentsInFlow ()=0
virtual void getContentInFlow (int index, core::Content *content)=0
void setValues (int sectionIndex, int index)
void cloneValues (OOFAwareWidgetIterator *other)
bool inFlow ()
int getInFlowIndex ()
void highlightOOF (int start, int end, core::HighlightLayer layer)
void unhighlightOOF (int direction, core::HighlightLayer layer)
void getAllocationOOF (int start, int end, core::Allocation *allocation)
- Protected Member Functions inherited from dw::core::Iterator
 Iterator (Widget *widget, Content::Type mask, bool atEnd)
 Iterator (Iterator &it)
 ~Iterator ()

Private Types

enum  { NUM_SECTIONS = NUM_OOFM + 1 }

Private Member Functions

int numParts (int sectionIndex, int numContentsInFlow=-1)
void getPart (int sectionIndex, int index, core::Content *content)

Private Attributes

int sectionIndex
int index

Additional Inherited Members

- Static Public Member Functions inherited from dw::core::Iterator
static void scrollTo (Iterator *it1, Iterator *it2, int start, int end, HPosition hpos, VPosition vpos)
 Scrolls the viewport, so that the region between it1 and it2 is seen, according to hpos and vpos.
- Protected Attributes inherited from dw::core::Iterator
Content content

Detailed Description

Definition at line 85 of file oofawarewidget.hh.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum

Definition at line 88 of file oofawarewidget.hh.

Constructor & Destructor Documentation

◆ OOFAwareWidgetIterator()

dw::oof::OOFAwareWidget::OOFAwareWidgetIterator::OOFAwareWidgetIterator ( OOFAwareWidget widget,
core::Content::Type  mask,
bool  atEnd,
int  numContentsInFlow 

Member Function Documentation

◆ cloneValues()

void dw::oof::OOFAwareWidget::OOFAwareWidgetIterator::cloneValues ( OOFAwareWidgetIterator other)

Definition at line 100 of file oofawarewidget.hh.

References index, sectionIndex, and setValues().

◆ compareTo()

int dw::oof::OOFAwareWidget::OOFAwareWidgetIterator::compareTo ( lout::object::Comparable other)

Compare two objects, this and other.

Return a value < 0, when this is less than other, a value > 0, when this is greater than other, or 0, when this and other are equal.

If c1.equals(c2) (as defined in Object), c1.compareTo(c2) must be 0, but, unlike you may expect, the reversed is not necessarily true. This method returns 0, if, according to the rules for sorting, there is no difference, but there may still be differences (not relevant for sorting), which "equals" will care about.

Implements lout::object::Comparable.

Definition at line 118 of file oofawarewidget_iterator.cc.

References index, and sectionIndex.

◆ getAllocationOOF()

void dw::oof::OOFAwareWidget::OOFAwareWidgetIterator::getAllocationOOF ( int  start,
int  end,
core::Allocation allocation 

◆ getContentInFlow()

virtual void dw::oof::OOFAwareWidget::OOFAwareWidgetIterator::getContentInFlow ( int  index,
core::Content content 
protectedpure virtual

◆ getInFlowIndex()

int dw::oof::OOFAwareWidget::OOFAwareWidgetIterator::getInFlowIndex ( )

Definition at line 104 of file oofawarewidget.hh.

References index, and inFlow().

◆ getPart()

void dw::oof::OOFAwareWidget::OOFAwareWidgetIterator::getPart ( int  sectionIndex,
int  index,
core::Content content 

◆ highlightOOF()

void dw::oof::OOFAwareWidget::OOFAwareWidgetIterator::highlightOOF ( int  start,
int  end,
core::HighlightLayer  layer 

Definition at line 225 of file oofawarewidget_iterator.cc.

◆ inFlow()

bool dw::oof::OOFAwareWidget::OOFAwareWidgetIterator::inFlow ( )

Definition at line 103 of file oofawarewidget.hh.

References sectionIndex.

Referenced by getInFlowIndex().

◆ intoStringBuffer()

void dw::oof::OOFAwareWidget::OOFAwareWidgetIterator::intoStringBuffer ( lout::misc::StringBuffer sb)

Store a textual representation of the object in a misc::StringBuffer.

This is used by object::Object::toString.

Reimplemented from dw::core::Iterator.

Definition at line 109 of file oofawarewidget_iterator.cc.

References lout::misc::StringBuffer::append(), lout::misc::StringBuffer::appendInt(), and dw::core::Iterator::intoStringBuffer().

◆ next()

bool dw::oof::OOFAwareWidget::OOFAwareWidgetIterator::next ( )

◆ numContentsInFlow()

virtual int dw::oof::OOFAwareWidget::OOFAwareWidgetIterator::numContentsInFlow ( )
protectedpure virtual

◆ numParts()

int dw::oof::OOFAwareWidget::OOFAwareWidgetIterator::numParts ( int  sectionIndex,
int  numContentsInFlow = -1 

◆ prev()

bool dw::oof::OOFAwareWidget::OOFAwareWidgetIterator::prev ( )

◆ setValues()

void dw::oof::OOFAwareWidget::OOFAwareWidgetIterator::setValues ( int  sectionIndex,
int  index 

◆ unhighlightOOF()

void dw::oof::OOFAwareWidget::OOFAwareWidgetIterator::unhighlightOOF ( int  direction,
core::HighlightLayer  layer 

Definition at line 231 of file oofawarewidget_iterator.cc.

Member Data Documentation

◆ index

int dw::oof::OOFAwareWidget::OOFAwareWidgetIterator::index

Definition at line 90 of file oofawarewidget.hh.

Referenced by cloneValues(), compareTo(), getInFlowIndex(), and OOFAwareWidgetIterator().

◆ sectionIndex

int dw::oof::OOFAwareWidget::OOFAwareWidgetIterator::sectionIndex

Definition at line 89 of file oofawarewidget.hh.

Referenced by cloneValues(), compareTo(), inFlow(), and OOFAwareWidgetIterator().

The documentation for this class was generated from the following files: