VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DtWindowText.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2022 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 
9 
10 #pragma once
11 
12 #include <vrvCore/vrvCore.h>
13 #include <vrvCore/DtUniqueID.h>
14 #include <vrvCore/DtWindowObject.h>
15 
16 #include <vector>
17 #include <string>
18 
19 namespace makVrv
20 {
21  class DtDe;
22  class DtWindowTextInstance;
23 
39  {
40  public:
42  {
43  Left = 0,
44  Center = 1,
45  Right = 2,
46  Justify = 3,
47  };
48 
50  DtWindowText(DtDe& de, DtUniqueID id);
51 
53  virtual ~DtWindowText();
54 
58  virtual void setTopLeftCorner( float x, float y);
59 
60  virtual bool calculateSize(float& width, float& height) const;
61 
63  virtual void setVisible(bool isVisible);
64 
66  virtual void setColor(float r,float g,float b,float a);
67 
69  virtual void setText(const std::string& textString);
70 
75  virtual void setFont(const std::string& fontFile, float sizeInPoints);
76 
78  virtual void setTextBoxWidth(float widthInPixels);
79 
81  virtual void setAlignment(unsigned int alignment);
82 
85  virtual void setInstance(DtWindowTextInstance* instance);
86 
88  virtual DtWindowTextInstance* findInstance();
89 
92  virtual void setGroup( int groupId );
93 
98  virtual void setChannelOverlay( const std::string& displayName,
99  const std::string& windowName, const std::string& channelName ) override;
100  protected:
102  virtual void update();
103 
105  virtual void needsUpdate();
106  protected:
109  };
110 }
111 
Interface for a DtWindowTextInstance An object that draws a 2D text.
Definition: DtWindowTextInstance.h:24
Base class for a graphical object that exists in a window Implements a parenting system for DtWindowO...
Definition: DtWindowObject.h:24
#define DT_DLL_VRVCORE
Definition: vrvCore.h:20
unsigned long long DtUniqueID
Definition: DtUniqueID.h:19
bool myConnectedToPostUpdate
Definition: DtWindowText.h:108
Contains makVrv::DtUniqueID type.
The DtDe is the core component of any VR-Vantage application. It owns a DtRenderer, DtDeCommunicator, as well as a DtDisplay and other things.
Definition: DtDe.h:72
DtWindowTextInstance * myInstance
Definition: DtWindowText.h:107
Contains makVrv::DtWindowObject class.
A model-like object that draws a 2D text on screen. This window text class inherits from DtWindowObje...
Definition: DtWindowText.h:38
TextAlignment
Definition: DtWindowText.h:41
Contains DLL export macros.

Document ID: Generated on Wed Mar 27 22:49:11 EDT 2024 from SVN revision 264633
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)