#include <sgline2.h>
Inheritance diagram for LineNoArrowItem:
Protected Member Functions | |
LineNoArrowItem (const String &strDescription) | |
Constructs a "no-arrowhead" line gallery item. | |
Private Member Functions | |
virtual MILLIPOINT | GetWidth () const |
Forces a "no-arrow" item to be full-width. | |
virtual MILLIPOINT | GetHeight () const |
Called by the line gallery formatting code. | |
virtual MILLIPOINT | GetVertGap () const |
Called by the formatting code of the line gallery. | |
virtual void | SetAttributes (RenderRegion *pRegion) const |
Overrides attribute setting for arrowheads to set NO attribute. | |
virtual void | DrawItem (RenderRegion *pRegion, const DocRect &drBounds) const |
Formats and draws an arrowhead/tail. |
Definition at line 227 of file sgline2.h.
|
Constructs a "no-arrowhead" line gallery item.
Definition at line 742 of file sgline2.cpp. 00743 : LineArrowItem((StockArrow) -1, 0, strDescription) 00744 { 00745 // Empty. 00746 }
|
|
Formats and draws an arrowhead/tail.
Reimplemented from LineArrowItem. Definition at line 845 of file sgline2.cpp. 00846 { 00847 // Work out the difference in width between the text string and the bounding box. 00848 MILLIPOINT nWidthDiff = drBounds.Width() - (GetDescription().Length() * c_nAveCharWidth); 00849 00850 // Draw the item's description centred within the new bounding box, if it will fit. 00851 DocRect drTextBounds(drBounds); 00852 if (nWidthDiff > 0) drTextBounds.Inflate(-nWidthDiff / 2, 0); 00853 pRegion->DrawFixedSystemText(&((String&) GetDescription()), drTextBounds); 00854 }
|
|
Called by the line gallery formatting code.
Reimplemented from LineArrowItem. Definition at line 783 of file sgline2.cpp. 00784 { 00785 return LineAttrItem::GetHeight(); 00786 }
|
|
Called by the formatting code of the line gallery.
Reimplemented from LineArrowItem. Definition at line 804 of file sgline2.cpp. 00805 { 00806 return LineArrowItem::GetVertGap() / 3; 00807 }
|
|
Forces a "no-arrow" item to be full-width.
Reimplemented from LineArrowItem. Definition at line 763 of file sgline2.cpp. 00764 { 00765 return 2 * LineArrowItem::GetWidth(); 00766 }
|
|
Overrides attribute setting for arrowheads to set NO attribute.
Reimplemented from LineArrowItem. Definition at line 824 of file sgline2.cpp.
|