VR-Forces 5.0.2 Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
rangeLineSettingsRecord.h
Go to the documentation of this file.
1 /*****************************************************************************
2  * Copyright (c) 2019 MAK Technologies, Inc.
3  * All rights reserved.
4  *****************************************************************************/
5 
6 #pragma once
7 
9 #include <boost/serialization/access.hpp>
10 #include <boost/serialization/nvp.hpp>
11 #include <boost/serialization/list.hpp>
12 #include <boost/serialization/map.hpp>
13 #include <boost/serialization/vector.hpp>
14 #include <boost/serialization/string.hpp>
15 
16 namespace makVrf
17 {
18 
21  {
22  public:
23 
26 
29 
31  DtRangeLineSettingsRecord& operator = ( const DtRangeLineSettingsRecord& obj );
32 
35 
37  bool operator == ( const DtRangeLineSettingsRecord& rhs ) const;
38 
40  inline bool operator != ( const DtRangeLineSettingsRecord& rhs ) const
41  {
42  return !( *this == rhs );
43  }
44 
47 
49  void setRangeLinesVisible( bool enabled );
51  bool rangeLinesVisible() const;
52 
54  void setColor( float r, float g, float b, float a );
56  void color( float& r, float& g, float& b, float& a ) const;
57 
59  void setRangeInfoLabelBackgroundColor( float r, float g, float b, float a );
61  void rangeInfoLabelBackgroundColor( float& r, float& g, float& b, float& a ) const;
62 
64  void setFontColor( float r, float g, float b, float a );
66  void fontColor( float& r, float& g, float& b, float& a ) const;
67 
69  void setFontSize(int);
71  int fontSize() const;
72 
74  void setLineWidth(int);
76  int lineWidth() const;
77 
79  void setHatLinesEnabled( bool hatEnabled );
81  bool hatLinesEnabled() const;
82 
84  void setHatLinesOnSelectionOnly( bool selOnly );
86  bool hatLinesOnSelectionOnly() const;
87 
90  void setRangeLineCreatedOnMiddleMouseClick(bool);
91  bool rangeLineCreatedOnMiddleMouseClick() const;
93 
94  protected:
95 
96  friend class boost::serialization::access;
97 
101  template<class Archive>
102  void serialize(Archive & ar, const unsigned int version)
103  {
104  ar & BOOST_SERIALIZATION_NVP(myColorR);
105  ar & BOOST_SERIALIZATION_NVP(myColorG);
106  ar & BOOST_SERIALIZATION_NVP(myColorB);
107  ar & BOOST_SERIALIZATION_NVP(myColorA);
108  ar & BOOST_SERIALIZATION_NVP(myLineWidth);
109  ar & BOOST_SERIALIZATION_NVP(myHatLinesEnabled);
110  ar & BOOST_SERIALIZATION_NVP(myHatLinesOnSelectionOnly);
111 
112  ar & BOOST_SERIALIZATION_NVP(myFontColorR);
113  ar & BOOST_SERIALIZATION_NVP(myFontColorG);
114  ar & BOOST_SERIALIZATION_NVP(myFontColorB);
115  ar & BOOST_SERIALIZATION_NVP(myFontColorA);
116  ar & BOOST_SERIALIZATION_NVP( myFontSize );
117 
118  ar & BOOST_SERIALIZATION_NVP( myRangeInfoLabelBackgroundColorR );
119  ar & BOOST_SERIALIZATION_NVP( myRangeInfoLabelBackgroundColorG );
120  ar & BOOST_SERIALIZATION_NVP( myRangeInfoLabelBackgroundColorB );
121  ar & BOOST_SERIALIZATION_NVP( myRangeInfoLabelBackgroundColorA );
122 
123  ar & BOOST_SERIALIZATION_NVP( myRangeLinesEnabled );
124 
125  if (version >= 2)
126  {
127  ar & BOOST_SERIALIZATION_NVP( myRangeLineCreatedOnMiddleMouseClick );
128  }
129  }
130 
131  protected:
132  float myColorR, myColorG, myColorB, myColorA;
133  float myFontColorR, myFontColorG, myFontColorB, myFontColorA;
134  float myBackgroundColorR, myBackgroundColorG, myBackgroundColorB, myBackgroundColorA;
135  float myRangeInfoLabelBackgroundColorR, myRangeInfoLabelBackgroundColorG;
136  float myRangeInfoLabelBackgroundColorB, myRangeInfoLabelBackgroundColorA;
137 
141 
144  bool myRangeLineCreatedOnMiddleMouseClick = true;
145  };
146 
147 }
148 
BOOST_CLASS_VERSION(makArchives::DtDiGuySettingsRecord, 3)
int myLineWidth
Definition: rangeLineSettingsRecord.h:140
DT_DLL_VRFGUICORE bool operator==(const std::vector< makArchives::DtEnvironmentRecord::DtElevationalConfigurationRecord > &lhs, const std::vector< makArchives::DtEnvironmentRecord::DtElevationalConfigurationRecord > &rhs)
#define DT_DLL_VRFGUICORE
Contains DLL export macros.
Definition: vrfGuiCore.h:25
Record class for Range Line settings.
Definition: rangeLineSettingsRecord.h:20
float myRangeInfoLabelBackgroundColorR
Definition: rangeLineSettingsRecord.h:135
int myFontSize
Definition: rangeLineSettingsRecord.h:139
bool myRangeLinesEnabled
Definition: rangeLineSettingsRecord.h:138
bool myHatLinesEnabled
Definition: rangeLineSettingsRecord.h:142
float myColorR
Definition: rangeLineSettingsRecord.h:132
DT_DLL_VRFGUICORE bool operator!=(const std::vector< makArchives::DtEnvironmentRecord::DtElevationalConfigurationRecord > &lhs, const std::vector< makArchives::DtEnvironmentRecord::DtElevationalConfigurationRecord > &rhs)
float myFontColorR
Definition: rangeLineSettingsRecord.h:133
void serialize(Archive &ar, const unsigned int version)
When the class Archive corresponds to an output archive, the &amp; operator is defined similar to &lt;&lt;...
Definition: rangeLineSettingsRecord.h:102
float myRangeInfoLabelBackgroundColorB
Definition: rangeLineSettingsRecord.h:136
float myBackgroundColorR
Definition: rangeLineSettingsRecord.h:134
bool myHatLinesOnSelectionOnly
Definition: rangeLineSettingsRecord.h:143

Document ID: Generated on Sun Dec 4 20:22:03 EST 2022 from SVN revision 249613
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)