OpenTwin 0.1
OpenTwin
 
Loading...
Searching...
No Matches
ot::TextEditorCfg Class Reference

#include "TextEditorCfg.h"

Inheritance diagram for ot::TextEditorCfg:
ot::WidgetViewBase ot::BasicEntityInformation ot::Serializable

Public Member Functions

 TextEditorCfg ()
 
 TextEditorCfg (const TextEditorCfg &_other)
 
virtual ~TextEditorCfg ()
 
TextEditorCfgoperator= (const TextEditorCfg &_other)
 
virtual void addToJsonObject (ot::JsonValue &_object, ot::JsonAllocator &_allocator) const override
 Add the object contents to the provided JSON object.
 
virtual void setFromJsonObject (const ot::ConstJsonObject &_object) override
 Set the object contents from the provided JSON object.
 
void setPlainText (const std::string &_text)
 
const std::string & getPlainText (void) const
 
void setDocumentSyntax (DocumentSyntax _syntax)
 
DocumentSyntax getDocumentSyntax (void) const
 
- Public Member Functions inherited from ot::WidgetViewBase
 WidgetViewBase (ViewType _type, ViewFlags _flags=ViewFlags())
 
 WidgetViewBase (const std::string &_entityName, const std::string &_title, ViewType _type, ViewFlags _flags=ViewFlags())
 
 WidgetViewBase (const std::string &_entityName, const std::string &_title, ViewDockLocation _dockLocation, ViewType _type, ViewFlags _flags=ViewFlags())
 
 WidgetViewBase (const WidgetViewBase &_other)
 
virtual ~WidgetViewBase ()
 
WidgetViewBaseoperator= (const WidgetViewBase &_other)
 
void setTitle (const std::string &_title)
 
const std::string & getTitle (void) const
 
void setViewFlag (ViewFlag _flag, bool _active=true)
 Set the widget view flag.
 
void setViewFlags (ViewFlags _flags)
 Replace the current flags with the flags provided.
 
ViewFlags getViewFlags (void) const
 Returns the current flags.
 
void setViewType (ViewType _type)
 
ViewType getViewType (void) const
 
void setDockLocation (ViewDockLocation _dockLocation)
 Set the dock location.
 
ViewDockLocation getDockLocation (void) const
 Returns the dock location.
 
void setEntityInformation (const BasicEntityInformation &_info)
 
- Public Member Functions inherited from ot::BasicEntityInformation
 BasicEntityInformation ()
 
 BasicEntityInformation (const std::string &_entityName)
 
 BasicEntityInformation (const std::string &_entityName, UID _entityId, UID _entityVersion)
 
 BasicEntityInformation (const BasicEntityInformation &_other)
 
virtual ~BasicEntityInformation ()
 
BasicEntityInformationoperator= (const BasicEntityInformation &_other)
 
void setEntityName (const std::string &_entityName)
 
const std::string & getEntityName (void) const
 
void setEntityID (UID _entityId)
 
UID getEntityID (void) const
 
void setEntityVersion (UID _entityVersion)
 
UID getEntityVersion (void) const
 
- Public Member Functions inherited from ot::Serializable
 Serializable ()
 
virtual ~Serializable ()
 

Additional Inherited Members

- Public Types inherited from ot::WidgetViewBase
enum  ViewFlag {
  NoViewFlags = 0x00 , ViewIsCloseable = 0x01 , ViewDefaultCloseHandling = 0x02 , ViewIsPinnable = 0x04 ,
  ViewIsCentral = 0x10 , ViewIsSide = 0x20 , ViewIsTool = 0x40
}
 ViewFlags are used to describe the view behaviour in the frontend. More...
 
enum  ViewDockLocation {
  Default , Left , Top , Right ,
  Bottom
}
 /ref ViewFlag "ViewFlag" More...
 
enum  ViewType {
  View3D , View1D , ViewText , ViewTable ,
  ViewVersion , ViewGraphics , ViewGraphicsPicker , ViewProperties ,
  ViewNavigation , CustomView
}
 
typedef Flags< ViewFlagViewFlags
 
- Static Public Member Functions inherited from ot::WidgetViewBase
static std::string toString (ViewFlag _flag)
 Returns a string representation of the provided view flag.
 
static ViewFlag stringToViewFlag (const std::string &_flag)
 Returns The view flag represented by the provided string.
 
static std::list< std::string > toStringList (ViewFlags _flags)
 Returns a string list contaning a string representation of every set flag in the provided view flags.
 
static ViewFlags stringListToViewFlags (const std::list< std::string > &_flags)
 Returns the view flags represented by the provided string list.
 
static std::string toString (ViewDockLocation _dockLocation)
 Returns the string representation of the provided view dock location.
 
static ViewDockLocation stringToDockLocation (const std::string &_dockLocation)
 Returns the view dock location represented by the provided string.
 
static std::string toString (ViewType _type)
 Returns the string representation of the provided view type.
 
static ViewType stringToViewType (const std::string &_type)
 Returns the view type represented by the provided string.
 

Constructor & Destructor Documentation

◆ TextEditorCfg() [1/2]

ot::TextEditorCfg::TextEditorCfg ( )

◆ TextEditorCfg() [2/2]

ot::TextEditorCfg::TextEditorCfg ( const TextEditorCfg & _other)

◆ ~TextEditorCfg()

ot::TextEditorCfg::~TextEditorCfg ( )
virtual

Member Function Documentation

◆ addToJsonObject()

void ot::TextEditorCfg::addToJsonObject ( ot::JsonValue & _object,
ot::JsonAllocator & _allocator ) const
overridevirtual

Add the object contents to the provided JSON object.

Parameters
_objectJson object reference to write the data to.
_allocatorAllocator.

Reimplemented from ot::WidgetViewBase.

◆ getDocumentSyntax()

DocumentSyntax ot::TextEditorCfg::getDocumentSyntax ( void ) const
inline

◆ getPlainText()

const std::string & ot::TextEditorCfg::getPlainText ( void ) const
inline

◆ operator=()

ot::TextEditorCfg & ot::TextEditorCfg::operator= ( const TextEditorCfg & _other)

◆ setDocumentSyntax()

void ot::TextEditorCfg::setDocumentSyntax ( DocumentSyntax _syntax)
inline

◆ setFromJsonObject()

void ot::TextEditorCfg::setFromJsonObject ( const ot::ConstJsonObject & _object)
overridevirtual

Set the object contents from the provided JSON object.

Parameters
_objectThe JSON object containing the information.
Exceptions
Maythrow an exception if the provided object is not valid (members missing or invalid types).

Reimplemented from ot::WidgetViewBase.

◆ setPlainText()

void ot::TextEditorCfg::setPlainText ( const std::string & _text)
inline

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