Archicad 30 C++ API
Loading...
Searching...
No Matches
DG::RawAndDisplayText Class Reference

Class contains both raw and display text, and conversion between them. More...

#include <DGRawAndDisplayText.hpp>

Public Member Functions

 RawAndDisplayText ()
 Constructor for RawAndDisplayText.
 
 RawAndDisplayText (GS::UniString _rawText)
 Constructor for RawAndDisplayText.
 
 ~RawAndDisplayText ()
 Destructor for RawAndDisplayText.
 
RawAndDisplayText & SetRawText (const GS::UniString &_rawText)
 Updates the raw text, and derives the associated display text.
 
RawAndDisplayText & SetDisplayText (const GS::UniString &_displayText)
 Updates the display text, and derives the associated raw text.
 
const GS::UniString & GetRawText () const
 Gets the raw text.
 
const GS::UniString & GetDisplayText () const
 Gets the display text.
 

Detailed Description

Class contains both raw and display text, and conversion between them.

  • Windows uses raw text to specify the accelerator keys using ampersands in front of the key.
  • A double ampersand in the raw text is used to display a single ampersand.
  • The accelerator keys are displayed with an underline.
  • For example "&Save" has an accelerator key 's' and this letter is displayed with an underscore.
  • Mac does not use accelerator keys and displays text as given.

Constructor & Destructor Documentation

◆ RawAndDisplayText()

DG::RawAndDisplayText::RawAndDisplayText ( GS::UniString _rawText)

Constructor for RawAndDisplayText.

Parameters
_rawTextThe raw text.

Member Function Documentation

◆ GetDisplayText()

const GS::UniString & DG::RawAndDisplayText::GetDisplayText ( ) const

Gets the display text.

Returns
The display text associated with the object.

◆ GetRawText()

const GS::UniString & DG::RawAndDisplayText::GetRawText ( ) const

Gets the raw text.

Returns
The raw text associated with the object.

◆ SetDisplayText()

RawAndDisplayText & DG::RawAndDisplayText::SetDisplayText ( const GS::UniString & _displayText)

Updates the display text, and derives the associated raw text.

Parameters
_displayTextThe new display text.
Returns
A reference to the object.

◆ SetRawText()

RawAndDisplayText & DG::RawAndDisplayText::SetRawText ( const GS::UniString & _rawText)

Updates the raw text, and derives the associated display text.

Parameters
_rawTextThe new raw text.
Returns
A reference to the object.