CFx SDK Documentation 2024 SP0
Loading...
Searching...
No Matches
Public Member Functions | List of all members
CFxUILabel Class Reference

#include <FxUILabel.h>

Inheritance diagram for CFxUILabel:
CFxUIBaseView CFxUIObject

Public Member Functions

 CFxUILabel ()
 
 ~CFxUILabel ()
 
void setIcon (const CFxUIIcon &icon)
 
void setPixmap (const CFxUIPixmap &pixmap)
 
void setResourceImage (const QString &path)
 
void setIconSize (const CFxUISize &size)
 
CFxUIString text () const
 
void setText (const CFxUIString &str)
 
void setBuddy (CFxUIBaseView *widget)
 
void setBoldText (bool bBold)
 
void setFontSize (int px)
 
void setItalic (int bItalic)
 
bool wordWrap () const
 
void setWordWrap (bool bWordWrap)
 
void clear ()
 
void setTextAlignment (TextAlignment iAlignment)
 
void setTextSelectable (bool bSelectable)
 
bool isTextSelectable () const
 
void setElideTextEnabled (const bool &bElided)
 
- Public Member Functions inherited from CFxUIBaseView
 CFxUIBaseView ()
 
virtual ~CFxUIBaseView ()
 
void setDisabled (bool on)
 
void setEnabled (bool on)
 
bool isEnabled () const
 
CFxUIPalette::ColorRole backgroundRole ()
 
void setPalette (const CFxUIPalette &)
 
const CFxUIPalettepalette () const
 
bool isVisible ()
 
void setVisible (bool bVisible)
 
bool hasFocus () const
 
void setFocus ()
 
void setFocus (int iReason)
 
void setFocusPolicy (int iPolicy)
 
int width ()
 
void setWidth (int w)
 
int height ()
 
void setHeight (int h)
 
void update ()
 
void setBusyState (bool bBusy=false)
 
void resize (int w, int h)
 
void setCornerRadius (float radius)
 
void setBorderWidth (float width)
 
void setBorderWidth (float left, float top, float right, float bottom)
 
void setBorderColor (int r, int g, int b)
 
virtual void showEvent (CFxUIShowEvent *event)
 
virtual void hideEvent (CFxUIHideEvent *event)
 
virtual void paintEvent (CFxUIPaintEvent *event)
 
virtual void resizeEvent (CFxUIResizeEvent *event)
 
virtual void focusInEvent (CFxUIFocusEvent *focusInEvent)
 
virtual void focusOutEvent (CFxUIFocusEvent *focusOutEvent)
 
void setEventAccepted (bool bAccepted=false)
 
void addView (CFxUIBaseView *pChild, float fWeight=0.0)
 
void insertView (CFxUIBaseView *pChild, int index=0, float fWeight=0.0)
 
int indexOf (CFxUIBaseView *pChild)
 
void removeView (CFxUIBaseView *pChild)
 
void setPreferableSize (int w, int h)
 
void setMinimumWidth (int iWidth)
 
void setMinimumHeight (int iHeight)
 
void setMinimumSize (const CFxUISize &size)
 
void setMaximumWidth (int iWidth)
 
void setMaximumHeight (int iHeight)
 
void setMaximumSize (const CFxUISize &size)
 
int minimumWidth ()
 
int minimumHeight ()
 
int maximumWidth ()
 
int maximumHeight ()
 
void setToolTip (const CFxUIString &sToolTip)
 
const CFxUIString toolTip ()
 
CFxUISignal< void(void)> & aboutToPassEventToParent ()
 
CFxUISignal< void(void)> & aboutToShow ()
 
CFxUISignal< void(void)> & hoverEnter ()
 
CFxUISignal< void(void)> & hoverLeave ()
 
CFxUISignal< void(bool)> & visibilityChanged ()
 
- Public Member Functions inherited from CFxUIObject
 CFxUIObject ()
 
virtual ~CFxUIObject ()
 
FxNativeHandle getHandle () const
 
void setHandle (FxNativeHandle handle)
 
void setParent (CFxUIObject *parent)
 
CFxUIObjectparent ()
 
const CFxUIObjectparent () const
 
void setObjectName (const CFxUIString &objectName)
 
CFxUIString objectName () const
 
bool setProperty (const char *name, const CFxUIVariant &value)
 
CFxUIVariant property (const char *name)
 
CFxUIList< CFxUIObject * > children () const
 
template<typename T >
CFxUIList< T > findChildren (const CFxUIString &name=CFxUIString())
 
void blockSignals (bool block)
 
bool signalsBlocked () const
 

Additional Inherited Members

- Public Types inherited from CFxUIBaseView
enum  TextAlignment {
  AlignLeft = 0x0001 , AlignRight = 0x0002 , AlignHCenter = 0x0004 , AlignJustify = 0x0008 ,
  AlignTop = 0x0020 , AlignBottom = 0x0040 , AlignVCenter = 0x0080 , AlignBaseline = 0x0100 ,
  AlignCenter = AlignVCenter | AlignHCenter
}
 
enum  FocusPolicyType {
  eNoFocus = 0 , eTabFocus = 0x1 , eClickFocus = 0x2 , eStrongFocus = eTabFocus | eClickFocus | 0x8 ,
  eWheelFocus = eStrongFocus | 0x4 , eKeyboardOnSetfocus = 0x10
}
 
enum  UIWidthSizePolicy {
  eExpanding = -1 , eXS = 0 , eS , eM ,
  eL , eXL
}
 
- Static Public Member Functions inherited from CFxUIBaseView
static void setTabOrder (CFxUIObject *first, CFxUIObject *second)
 
- Protected Member Functions inherited from CFxUIObject
CFxUIObjectsender ()
 
- Protected Attributes inherited from CFxUIObject
CFxUIObjectImpl * m_pImpl
 
CFxUIObjectData * m_pData
 

Detailed Description

Class CFxUILabel provides a text or image display.

Definition at line 27 of file FxUILabel.h.

Constructor & Destructor Documentation

◆ CFxUILabel()

CFxUILabel::CFxUILabel ( )
explicit

Constructor

◆ ~CFxUILabel()

CFxUILabel::~CFxUILabel ( )

Destructor

Member Function Documentation

◆ clear()

void CFxUILabel::clear ( )

Clears the content of label.

◆ isTextSelectable()

bool CFxUILabel::isTextSelectable ( ) const

Returns the bool for selectable property.

Returns
bool The value returned is true if text interaction is selectable, otherwise false.

◆ setBoldText()

void CFxUILabel::setBoldText ( bool  bBold)

Sets font of text in push button as bold.

Parameters
bBoldIf parameter is true font is set to bold, otherwise not.

◆ setBuddy()

void CFxUILabel::setBuddy ( CFxUIBaseView widget)

◆ setElideTextEnabled()

void CFxUILabel::setElideTextEnabled ( const bool &  bElided)

◆ setFontSize()

void CFxUILabel::setFontSize ( int  px)

Sets font size of text on label.

Parameters
pxInput.

◆ setIcon()

void CFxUILabel::setIcon ( const CFxUIIcon icon)

Sets the icon.

Parameters
icon

◆ setIconSize()

void CFxUILabel::setIconSize ( const CFxUISize size)

Sets the size of icon.

Parameters
sizeThe icon is resized to the value passed in parameter.

◆ setItalic()

void CFxUILabel::setItalic ( int  bItalic)

Sets italic text on label.

Parameters
bItalicInput.

◆ setPixmap()

void CFxUILabel::setPixmap ( const CFxUIPixmap pixmap)

Sets the pixmap.

Parameters
pixmap

◆ setResourceImage()

void CFxUILabel::setResourceImage ( const QString &  path)

Sets the image.

Parameters
Imagepath

◆ setText()

void CFxUILabel::setText ( const CFxUIString str)

Sets the text.

Parameters
strInput

◆ setTextAlignment()

void CFxUILabel::setTextAlignment ( TextAlignment  iAlignment)

Sets alignment of text on label.

Parameters
iAlignmentThe value is to be from enums defined in TextAlignment.

◆ setTextSelectable()

void CFxUILabel::setTextSelectable ( bool  bSelectable)

Sets the text interaction to selectable.

Parameters
bSelectableif true the text interaction is selectable else no interaction.

◆ setWordWrap()

void CFxUILabel::setWordWrap ( bool  bWordWrap)

Sets label's word-wrapping policy.

Parameters
bWordWrapIf the value passed is true then label text is wrapped where necessary at word-breaks otherwise it is not wrapped at all.

◆ text()

CFxUIString CFxUILabel::text ( ) const

Returns the text.

Returns
string

◆ wordWrap()

bool CFxUILabel::wordWrap ( ) const

Returns if word-wrap mode is on for label.

Returns
bool The value returned is true if wordWrap is on , otherwise false.

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