OpendTect  7.0
Public Member Functions | Protected Attributes | Private Member Functions | Private Attributes | List of all members
uiScaleBarItem Class Reference

It adds a graphic scale made from polygons. More...

Inheritance diagram for uiScaleBarItem:
[legend]

Public Member Functions

 uiScaleBarItem (int pxwidth=100, int pxheight=6)
 
 ~uiScaleBarItem ()
 
float getLength () const
 
int getPxHeight () const
 
int getPxWidth () const
 
void setAnnotPos (OD::Edge)
 
void setLength (float len)
 
void setPxHeight (int pxh)
 
void setPxWidth (int pxw)
 
void setUnit (const uiString &unit)
 
void setWorld2Ui (const uiWorld2Ui &)
 
void update ()
 
- Public Member Functions inherited from uiGraphicsItem
 uiGraphicsItem ()
 
 ~uiGraphicsItem ()
 
virtual OD::ButtonState acceptedMouseButtonsEnabled () const
 
void addChild (uiGraphicsItem *)
 
void addChildSet (uiGraphicsItemSet &)
 
void addChildWithoutCheck (uiGraphicsItem *)
 
virtual uiRect boundingRect () const
 
virtual uiGraphicsItemfindItem (QGraphicsItem *)
 
uiGraphicsItemgetChild (int)
 
Geom::Point2D< float > getPos () const
 
float getRotation ()
 
void getScale (float &sx, float &sy)
 
float getTransparency () const
 
int getZValue () const
 
void hide ()
 
int id () const
 
virtual bool isFiltersChildEventsEnabled () const
 
virtual bool isHoverEventsAccepted () const
 
bool isItemIgnoresTransformationsEnabled () const
 
virtual bool isMovable () const
 
bool isPresent (const uiGraphicsItem &) const
 
virtual bool isSelectable () const
 
virtual bool isSelected () const
 
virtual bool isVisible () const
 
void moveBy (float x, float y)
 
int nrChildren () const
 
QGraphicsItem * qGraphicsItem ()
 
const QGraphicsItem * qGraphicsItem () const
 
void removeAll (bool withdelete)
 
void removeChild (uiGraphicsItem *, bool withdelete)
 
void removeChildSet (uiGraphicsItemSet &)
 
void rotate (float angle)
 
void scale (float sx, float sy)
 
virtual void setAcceptedMouseButtons (OD::ButtonState)
 
virtual void setAcceptHoverEvents (bool)
 
void setCursor (const MouseCursor &)
 
virtual void setFillColor (const OD::Color &, bool usetransp=false)
 
virtual void setFillPattern (const FillPattern &)
 
virtual void setFiltersChildEvents (bool)
 
virtual void setGradientFill (int x1, int y1, int x2, int y2, const TypeSet< float > &stops, const TypeSet< OD::Color > &colors)
 
void setItemIgnoresTransformations (bool)
 
virtual void setMovable (bool)
 
virtual void setPenColor (const OD::Color &, bool usetransp=false)
 
virtual void setPenStyle (const OD::LineStyle &, bool usetransp=false)
 
void setPos (const Geom::Point2D< float > &)
 
void setPos (const uiPoint &p)
 
void setPos (const uiWorldPoint &)
 
void setPos (float x, float y)
 
void setRotation (float angle)
 
void setScale (float sx, float sy)
 
virtual void setScene (uiGraphicsScene *)
 
virtual void setSelectable (bool)
 
virtual void setSelected (bool)
 
void setToolTip (const uiString &)
 
virtual void setTransparency (float)
 
virtual void setVisible (bool)
 
void setZValue (int)
 
void show ()
 
uiPoint transformToScenePos (const uiPoint &itmpos) const
 
virtual void translateText ()
 
- Public Member Functions inherited from CallBacker
 CallBacker ()
 
 CallBacker (const CallBacker &)
 
virtual ~CallBacker ()
 
bool attachCB (const NotifierAccess &, const CallBack &, bool onlyifnew=false) const
 
bool attachCB (const NotifierAccess *notif, const CallBack &cb, bool onlyifnew=false) const
 
void detachAllNotifiers () const
 Call from the destructor of your inherited object. More...
 
void detachCB (const NotifierAccess &, const CallBack &) const
 
void detachCB (const NotifierAccess *notif, const CallBack &cb) const
 
virtual bool isCapsule () const
 
bool isNotifierAttached (const NotifierAccess *) const
 Only for debugging purposes, don't use. More...
 
void stopReceivingNotifications () const
 
virtual CallBackertrueCaller ()
 

Protected Attributes

uiRectItemlowerleft_
 
uiRectItemlowermid_
 
uiRectItemlowerright_
 
uiAdvancedTextItemmidnr_
 
int pxheight_
 
int pxwidth_
 
uiAdvancedTextItemstartnr_
 
uiAdvancedTextItemstopnr_
 
uiString unitstr_
 
uiRectItemupperleft_
 
uiRectItemuppermid_
 
uiRectItemupperright_
 
float worldwidth_
 
- Protected Attributes inherited from uiGraphicsItem
ObjectSet< uiGraphicsItemchildren_
 
uiGraphicsItemparent_
 
QGraphicsItem * qgraphicsitem_
 
uiGraphicsScenescene_
 
bool selected_
 

Private Member Functions

void adjustValues ()
 
void initDefaultScale ()
 
void setPolygons (int, int)
 

Private Attributes

OD::Edge annotpos_
 
int preferablepxwidth_
 
uiWorld2Ui w2ui_
 

Additional Inherited Members

- Static Public Member Functions inherited from CallBacker
static void createReceiverForCurrentThread ()
 
static void removeReceiverForCurrentThread ()
 
- Public Attributes inherited from uiGraphicsItem
CNotifier< uiGraphicsItem, const MouseEvent & > leftClicked
 
CNotifier< uiGraphicsItem, const MouseEvent & > rightClicked
 
- Protected Member Functions inherited from uiGraphicsItem
 uiGraphicsItem (QGraphicsItem *)
 
virtual QGraphicsItem * mkQtObj ()
 
virtual void stPos (float, float)
 

Detailed Description

It adds a graphic scale made from polygons.

<>

Constructor & Destructor Documentation

◆ uiScaleBarItem()

uiScaleBarItem::uiScaleBarItem ( int  pxwidth = 100,
int  pxheight = 6 
)

◆ ~uiScaleBarItem()

uiScaleBarItem::~uiScaleBarItem ( )

Member Function Documentation

◆ adjustValues()

void uiScaleBarItem::adjustValues ( )
private

◆ getLength()

float uiScaleBarItem::getLength ( ) const
inline

◆ getPxHeight()

int uiScaleBarItem::getPxHeight ( ) const
inline

◆ getPxWidth()

int uiScaleBarItem::getPxWidth ( ) const
inline

◆ initDefaultScale()

void uiScaleBarItem::initDefaultScale ( )
private

◆ setAnnotPos()

void uiScaleBarItem::setAnnotPos ( OD::Edge  )

◆ setLength()

void uiScaleBarItem::setLength ( float  len)
inline

◆ setPolygons()

void uiScaleBarItem::setPolygons ( int  ,
int   
)
private

◆ setPxHeight()

void uiScaleBarItem::setPxHeight ( int  pxh)
inline

◆ setPxWidth()

void uiScaleBarItem::setPxWidth ( int  pxw)
inline

◆ setUnit()

void uiScaleBarItem::setUnit ( const uiString unit)
inline

◆ setWorld2Ui()

void uiScaleBarItem::setWorld2Ui ( const uiWorld2Ui )

◆ update()

void uiScaleBarItem::update ( )

Member Data Documentation

◆ annotpos_

OD::Edge uiScaleBarItem::annotpos_
private

◆ lowerleft_

uiRectItem* uiScaleBarItem::lowerleft_
protected

◆ lowermid_

uiRectItem* uiScaleBarItem::lowermid_
protected

◆ lowerright_

uiRectItem* uiScaleBarItem::lowerright_
protected

◆ midnr_

uiAdvancedTextItem* uiScaleBarItem::midnr_
protected

◆ preferablepxwidth_

int uiScaleBarItem::preferablepxwidth_
private

◆ pxheight_

int uiScaleBarItem::pxheight_
protected

◆ pxwidth_

int uiScaleBarItem::pxwidth_
protected

◆ startnr_

uiAdvancedTextItem* uiScaleBarItem::startnr_
protected

◆ stopnr_

uiAdvancedTextItem* uiScaleBarItem::stopnr_
protected

◆ unitstr_

uiString uiScaleBarItem::unitstr_
protected

◆ upperleft_

uiRectItem* uiScaleBarItem::upperleft_
protected

◆ uppermid_

uiRectItem* uiScaleBarItem::uppermid_
protected

◆ upperright_

uiRectItem* uiScaleBarItem::upperright_
protected

◆ w2ui_

uiWorld2Ui uiScaleBarItem::w2ui_
private

◆ worldwidth_

float uiScaleBarItem::worldwidth_
protected

Generated at for the OpendTect seismic interpretation project. Copyright (C): dGB Beheer B.V. 1995-2024