OpenClonk
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros
C4GUI::ComponentAligner Class Reference

#include <C4Gui.h>

Collaboration diagram for C4GUI::ComponentAligner:
[legend]

Public Member Functions

 ComponentAligner (const C4Rect &rcArea, int32_t iMarginX, int32_t iMarginY, bool fZeroAreaXY=false)
 
bool GetFromTop (int32_t iHgt, int32_t iWdt, C4Rect &rcOut)
 
bool GetFromLeft (int32_t iWdt, int32_t iHgt, C4Rect &rcOut)
 
bool GetFromRight (int32_t iWdt, int32_t iHgt, C4Rect &rcOut)
 
bool GetFromBottom (int32_t iHgt, int32_t iWdt, C4Rect &rcOut)
 
void GetAll (C4Rect &rcOut)
 
bool GetCentered (int32_t iWdt, int32_t iHgt, C4Rect &rcOut)
 
C4RectGetFromTop (int32_t iHgt, int32_t iWdt=-1)
 
C4RectGetFromLeft (int32_t iWdt, int32_t iHgt=-1)
 
C4RectGetFromRight (int32_t iWdt, int32_t iHgt=-1)
 
C4RectGetFromBottom (int32_t iHgt, int32_t iWdt=-1)
 
C4RectGetAll ()
 
C4RectGetCentered (int32_t iWdt, int32_t iHgt)
 
C4RectGetGridCell (int32_t iSectX, int32_t iSectXMax, int32_t iSectY, int32_t iSectYMax, int32_t iSectSizeX=-1, int32_t iSectSizeY=-1, bool fCenterPos=false, int32_t iSectNumX=1, int32_t iSectNumY=1)
 
int32_t GetWidth () const
 
int32_t GetHeight () const
 
int32_t GetHMargin () const
 
int32_t GetVMargin () const
 
int32_t GetInnerWidth () const
 
int32_t GetInnerHeight () const
 
void ExpandTop (int32_t iByHgt)
 
void ExpandLeft (int32_t iByWdt)
 
void ExpandRight (int32_t iByWdt)
 
void ExpandBottom (int32_t iByHgt)
 
void LogIt (const char *szName)
 

Protected Attributes

C4Rect rcClientArea
 
int32_t iMarginX
 
int32_t iMarginY
 

Static Protected Attributes

static C4Rect rcTemp
 

Detailed Description

Definition at line 2771 of file C4Gui.h.

Constructor & Destructor Documentation

C4GUI::ComponentAligner::ComponentAligner ( const C4Rect rcArea,
int32_t  iMarginX,
int32_t  iMarginY,
bool  fZeroAreaXY = false 
)
inline

Definition at line 2780 of file C4Gui.h.

References C4Rect::x, and C4Rect::y.

2782  { if (fZeroAreaXY) rcClientArea.x=rcClientArea.y=0; }
int32_t y
Definition: C4Rect.h:32
int32_t x
Definition: C4Rect.h:32

Member Function Documentation

void C4GUI::ComponentAligner::ExpandBottom ( int32_t  iByHgt)
inline

Definition at line 2811 of file C4Gui.h.

References C4Rect::Hgt.

2811 { rcClientArea.Hgt+=iByHgt; } // enlarge client rect
int32_t Hgt
Definition: C4Rect.h:32
void C4GUI::ComponentAligner::ExpandLeft ( int32_t  iByWdt)
inline

Definition at line 2809 of file C4Gui.h.

References C4Rect::Wdt, and C4Rect::x.

Referenced by C4StartupPlrPropertiesDlg::C4StartupPlrPropertiesDlg(), C4GUI::InputDialog::InputDialog(), C4GUI::LabeledEdit::LabeledEdit(), and C4GUI::MessageDialog::MessageDialog().

2809 { rcClientArea.x-=iByWdt; rcClientArea.Wdt+=iByWdt; } // enlarge client rect
int32_t Wdt
Definition: C4Rect.h:32
int32_t x
Definition: C4Rect.h:32

Here is the caller graph for this function:

void C4GUI::ComponentAligner::ExpandRight ( int32_t  iByWdt)
inline

Definition at line 2810 of file C4Gui.h.

References C4Rect::Wdt.

2810 { rcClientArea.Wdt+=iByWdt; } // enlarge client rect
int32_t Wdt
Definition: C4Rect.h:32
void C4GUI::ComponentAligner::ExpandTop ( int32_t  iByHgt)
inline

Definition at line 2808 of file C4Gui.h.

References C4Rect::Hgt, and C4Rect::y.

Referenced by C4GameOverDlg::C4GameOverDlg(), C4Network2ClientListDlg::C4Network2ClientListDlg(), C4StartupPlrPropertiesDlg::C4StartupPlrPropertiesDlg(), and C4GUI::LabeledEdit::LabeledEdit().

2808 { rcClientArea.y-=iByHgt; rcClientArea.Hgt+=iByHgt; } // enlarge client rect
int32_t y
Definition: C4Rect.h:32
int32_t Hgt
Definition: C4Rect.h:32

Here is the caller graph for this function:

void C4GUI::ComponentAligner::GetAll ( C4Rect rcOut)

Definition at line 1128 of file C4Gui.cpp.

References C4Rect::Hgt, iMarginX, iMarginY, rcClientArea, C4Rect::Wdt, C4Rect::x, and C4Rect::y.

Referenced by C4ChartDialog::C4ChartDialog(), C4GameOverDlg::C4GameOverDlg(), C4Network2ClientListDlg::C4Network2ClientListDlg(), C4Network2StartWaitDlg::C4Network2StartWaitDlg(), C4StartupNetDlg::C4StartupNetDlg(), C4StartupOptionsDlg::C4StartupOptionsDlg(), C4StartupPlrSelDlg::C4StartupPlrSelDlg(), C4GUI::InfoDialog::CreateSubComponents(), C4FileSelDlg::DefaultListItem::DefaultListItem(), C4FileSelDlg::InitElements(), C4GUI::InputDialog::InputDialog(), C4GUI::LabeledEdit::LabeledEdit(), C4GameLobby::MainDlg::MainDlg(), C4GUI::ProgressDialog::ProgressDialog(), C4GameLobby::ScenDesc::ScenDesc(), C4ChatControl::ChatSheet::NickItem::UpdateOwnPos(), C4FileSelDlg::DefaultListItem::UpdateOwnPos(), and C4ChatDlg::UpdateSize().

1129  {
1130  rcOut.x = rcClientArea.x + iMarginX;
1131  rcOut.y = rcClientArea.y + iMarginY;
1132  rcOut.Wdt = rcClientArea.Wdt - iMarginX * 2;
1133  rcOut.Hgt = rcClientArea.Hgt - iMarginY * 2;
1134  }
int32_t Wdt
Definition: C4Rect.h:32
int32_t y
Definition: C4Rect.h:32
int32_t x
Definition: C4Rect.h:32
int32_t Hgt
Definition: C4Rect.h:32

Here is the caller graph for this function:

C4Rect& C4GUI::ComponentAligner::GetAll ( )
inline

Definition at line 2795 of file C4Gui.h.

References GetAll(), and rcTemp.

Referenced by GetAll().

2795 { GetAll(rcTemp); return rcTemp; } // get remaining client are
static C4Rect rcTemp
Definition: C4Gui.h:2777
C4Rect & GetAll()
Definition: C4Gui.h:2795

Here is the call graph for this function:

Here is the caller graph for this function:

bool C4GUI::ComponentAligner::GetCentered ( int32_t  iWdt,
int32_t  iHgt,
C4Rect rcOut 
)

Definition at line 1136 of file C4Gui.cpp.

References C4Rect::GetMiddleX(), C4Rect::GetMiddleY(), C4Rect::Hgt, iMarginX, iMarginY, rcClientArea, C4Rect::Wdt, C4Rect::x, and C4Rect::y.

Referenced by C4GameOptionButtons::C4GameOptionButtons(), C4StartupNetDlg::C4StartupNetDlg(), C4StartupOptionsDlg::C4StartupOptionsDlg(), and C4StartupScenSelDlg::C4StartupScenSelDlg().

1137  {
1138  rcOut.x = rcClientArea.GetMiddleX() - iWdt/2;
1139  rcOut.y = rcClientArea.GetMiddleY() - iHgt/2;
1140  rcOut.Wdt = iWdt;
1141  rcOut.Hgt = iHgt;
1142  // range check
1143  return rcOut.Wdt+iMarginX*2 <= rcClientArea.Wdt && rcOut.Hgt+iMarginY*2 <= rcClientArea.Hgt;
1144  }
int32_t GetMiddleX() const
Definition: C4Rect.h:58
int32_t Wdt
Definition: C4Rect.h:32
int32_t y
Definition: C4Rect.h:32
int32_t GetMiddleY() const
Definition: C4Rect.h:59
int32_t x
Definition: C4Rect.h:32
int32_t Hgt
Definition: C4Rect.h:32

Here is the call graph for this function:

Here is the caller graph for this function:

C4Rect& C4GUI::ComponentAligner::GetCentered ( int32_t  iWdt,
int32_t  iHgt 
)
inline

Definition at line 2796 of file C4Gui.h.

References GetCentered(), and rcTemp.

Referenced by GetCentered().

2796 { GetCentered(iWdt, iHgt, rcTemp); return rcTemp; } // get centered subregion within area (w/o size checks)
static C4Rect rcTemp
Definition: C4Gui.h:2777
bool GetCentered(int32_t iWdt, int32_t iHgt, C4Rect &rcOut)
Definition: C4Gui.cpp:1136

Here is the call graph for this function:

Here is the caller graph for this function:

bool C4GUI::ComponentAligner::GetFromBottom ( int32_t  iHgt,
int32_t  iWdt,
C4Rect rcOut 
)

Definition at line 1112 of file C4Gui.cpp.

References C4Rect::Hgt, iMarginX, iMarginY, rcClientArea, C4Rect::Wdt, C4Rect::x, and C4Rect::y.

Referenced by C4GameOverDlg::C4GameOverDlg(), C4Network2ClientListDlg::C4Network2ClientListDlg(), C4Network2StartWaitDlg::C4Network2StartWaitDlg(), C4StartupAboutDlg::C4StartupAboutDlg(), C4StartupNetDlg::C4StartupNetDlg(), C4StartupOptionsDlg::C4StartupOptionsDlg(), C4StartupPlrColorPickerDlg::C4StartupPlrColorPickerDlg(), C4StartupPlrPropertiesDlg::C4StartupPlrPropertiesDlg(), C4StartupPlrSelDlg::C4StartupPlrSelDlg(), C4StartupScenSelDlg::C4StartupScenSelDlg(), C4GUI::InfoDialog::CreateSubComponents(), C4FileSelDlg::InitElements(), C4GUI::InputDialog::InputDialog(), C4GameLobby::MainDlg::MainDlg(), and C4GUI::ProgressDialog::ProgressDialog().

1113  {
1114  rcOut.x = rcClientArea.x + iMarginX;
1115  rcOut.y = rcClientArea.y + rcClientArea.Hgt - iHgt - iMarginY;
1116  rcOut.Wdt = rcClientArea.Wdt - iMarginX * 2;
1117  rcOut.Hgt = iHgt;
1118  rcClientArea.Hgt -= iHgt + iMarginY * 2;
1119  // get centered in width as specified
1120  if (iWdt >= 0)
1121  {
1122  rcOut.x += (rcOut.Wdt - iWdt) / 2;
1123  rcOut.Wdt = iWdt;
1124  }
1125  return rcClientArea.Hgt >= 0;
1126  }
int32_t Wdt
Definition: C4Rect.h:32
int32_t y
Definition: C4Rect.h:32
int32_t x
Definition: C4Rect.h:32
int32_t Hgt
Definition: C4Rect.h:32

Here is the caller graph for this function:

C4Rect& C4GUI::ComponentAligner::GetFromBottom ( int32_t  iHgt,
int32_t  iWdt = -1 
)
inline

Definition at line 2794 of file C4Gui.h.

References GetFromBottom(), and rcTemp.

Referenced by GetFromBottom().

2794 { GetFromBottom(iHgt, iWdt, rcTemp); return rcTemp; } // get a portion from the bottom
static C4Rect rcTemp
Definition: C4Gui.h:2777
bool GetFromBottom(int32_t iHgt, int32_t iWdt, C4Rect &rcOut)
Definition: C4Gui.cpp:1112

Here is the call graph for this function:

Here is the caller graph for this function:

bool C4GUI::ComponentAligner::GetFromLeft ( int32_t  iWdt,
int32_t  iHgt,
C4Rect rcOut 
)

Definition at line 1079 of file C4Gui.cpp.

References C4Rect::Hgt, iMarginX, iMarginY, rcClientArea, C4Rect::Wdt, C4Rect::x, and C4Rect::y.

Referenced by C4LeagueSignupDialog::C4LeagueSignupDialog(), C4StartupMainDlg::C4StartupMainDlg(), C4StartupNetDlg::C4StartupNetDlg(), C4StartupOptionsDlg::C4StartupOptionsDlg(), C4FileSelDlg::DefaultListItem::DefaultListItem(), C4GUI::InputDialog::InputDialog(), C4GUI::LabeledEdit::LabeledEdit(), C4GUI::MessageDialog::MessageDialog(), C4GUI::ProgressDialog::ProgressDialog(), C4ChatControl::ChatSheet::NickItem::UpdateOwnPos(), and C4FileSelDlg::DefaultListItem::UpdateOwnPos().

1080  {
1081  rcOut.x = rcClientArea.x + iMarginX;
1082  rcOut.y = rcClientArea.y + iMarginY;
1083  rcOut.Wdt = iWdt;
1084  rcOut.Hgt = rcClientArea.Hgt - iMarginY * 2;
1085  int32_t d = iWdt + iMarginX * 2;
1086  rcClientArea.x += d; rcClientArea.Wdt -= d;
1087  // get centered in height as specified
1088  if (iHgt >= 0)
1089  {
1090  rcOut.y += (rcOut.Hgt - iHgt) / 2;
1091  rcOut.Hgt = iHgt;
1092  }
1093  return rcClientArea.Wdt >= 0;
1094  }
int32_t Wdt
Definition: C4Rect.h:32
int32_t y
Definition: C4Rect.h:32
int32_t x
Definition: C4Rect.h:32
int32_t Hgt
Definition: C4Rect.h:32

Here is the caller graph for this function:

C4Rect& C4GUI::ComponentAligner::GetFromLeft ( int32_t  iWdt,
int32_t  iHgt = -1 
)
inline

Definition at line 2792 of file C4Gui.h.

References GetFromLeft(), and rcTemp.

Referenced by GetFromLeft().

2792 { GetFromLeft(iWdt, iHgt, rcTemp); return rcTemp; } // get a portion from the left
static C4Rect rcTemp
Definition: C4Gui.h:2777
bool GetFromLeft(int32_t iWdt, int32_t iHgt, C4Rect &rcOut)
Definition: C4Gui.cpp:1079

Here is the call graph for this function:

Here is the caller graph for this function:

bool C4GUI::ComponentAligner::GetFromRight ( int32_t  iWdt,
int32_t  iHgt,
C4Rect rcOut 
)

Definition at line 1096 of file C4Gui.cpp.

References C4Rect::Hgt, iMarginX, iMarginY, rcClientArea, C4Rect::Wdt, C4Rect::x, and C4Rect::y.

Referenced by C4LeagueSignupDialog::C4LeagueSignupDialog(), C4StartupNetDlg::C4StartupNetDlg(), C4StartupOptionsDlg::C4StartupOptionsDlg(), C4FileSelDlg::InitElements(), C4GameLobby::MainDlg::MainDlg(), C4GUI::MessageDialog::MessageDialog(), and C4StartupScenSelDlg::ScenListItem::UpdateOwnPos().

1097  {
1098  rcOut.x = rcClientArea.x + rcClientArea.Wdt - iWdt - iMarginX;
1099  rcOut.y = rcClientArea.y + iMarginY;
1100  rcOut.Wdt = iWdt;
1101  rcOut.Hgt = rcClientArea.Hgt - iMarginY * 2;
1102  rcClientArea.Wdt -= iWdt + iMarginX * 2;
1103  // get centered in height as specified
1104  if (iHgt >= 0)
1105  {
1106  rcOut.y += (rcOut.Hgt - iHgt) / 2;
1107  rcOut.Hgt = iHgt;
1108  }
1109  return rcClientArea.Wdt >= 0;
1110  }
int32_t Wdt
Definition: C4Rect.h:32
int32_t y
Definition: C4Rect.h:32
int32_t x
Definition: C4Rect.h:32
int32_t Hgt
Definition: C4Rect.h:32

Here is the caller graph for this function:

C4Rect& C4GUI::ComponentAligner::GetFromRight ( int32_t  iWdt,
int32_t  iHgt = -1 
)
inline

Definition at line 2793 of file C4Gui.h.

References GetFromRight(), and rcTemp.

Referenced by GetFromRight().

2793 { GetFromRight(iWdt, iHgt, rcTemp); return rcTemp; } // get a portion from the right
static C4Rect rcTemp
Definition: C4Gui.h:2777
bool GetFromRight(int32_t iWdt, int32_t iHgt, C4Rect &rcOut)
Definition: C4Gui.cpp:1096

Here is the call graph for this function:

Here is the caller graph for this function:

bool C4GUI::ComponentAligner::GetFromTop ( int32_t  iHgt,
int32_t  iWdt,
C4Rect rcOut 
)

Definition at line 1062 of file C4Gui.cpp.

References C4Rect::Hgt, iMarginX, iMarginY, rcClientArea, C4Rect::Wdt, C4Rect::x, and C4Rect::y.

Referenced by C4GameOverDlg::C4GameOverDlg(), C4LeagueSignupDialog::C4LeagueSignupDialog(), C4Network2ClientListDlg::C4Network2ClientListDlg(), C4Network2StartWaitDlg::C4Network2StartWaitDlg(), C4StartupOptionsDlg::C4StartupOptionsDlg(), C4StartupPlrColorPickerDlg::C4StartupPlrColorPickerDlg(), C4StartupPlrPropertiesDlg::C4StartupPlrPropertiesDlg(), C4GUI::LabeledEdit::LabeledEdit(), C4GUI::MessageDialog::MessageDialog(), and C4GoalDisplay::SetGoals().

1063  {
1064  rcOut.x = rcClientArea.x + iMarginX;
1065  rcOut.y = rcClientArea.y + iMarginY;
1066  rcOut.Wdt = rcClientArea.Wdt - iMarginX * 2;
1067  rcOut.Hgt = iHgt;
1068  int32_t d = iHgt + iMarginY * 2;
1069  rcClientArea.y += d; rcClientArea.Hgt -= d;
1070  // get centered in width as specified
1071  if (iWdt >= 0)
1072  {
1073  rcOut.x += (rcOut.Wdt - iWdt) / 2;
1074  rcOut.Wdt = iWdt;
1075  }
1076  return rcClientArea.Hgt >= 0;
1077  }
int32_t Wdt
Definition: C4Rect.h:32
int32_t y
Definition: C4Rect.h:32
int32_t x
Definition: C4Rect.h:32
int32_t Hgt
Definition: C4Rect.h:32

Here is the caller graph for this function:

C4Rect& C4GUI::ComponentAligner::GetFromTop ( int32_t  iHgt,
int32_t  iWdt = -1 
)
inline

Definition at line 2791 of file C4Gui.h.

References GetFromTop(), and rcTemp.

Referenced by GetFromTop().

2791 { GetFromTop(iHgt, iWdt, rcTemp); return rcTemp; } // get a portion from the top
static C4Rect rcTemp
Definition: C4Gui.h:2777
bool GetFromTop(int32_t iHgt, int32_t iWdt, C4Rect &rcOut)
Definition: C4Gui.cpp:1062

Here is the call graph for this function:

Here is the caller graph for this function:

C4Rect & C4GUI::ComponentAligner::GetGridCell ( int32_t  iSectX,
int32_t  iSectXMax,
int32_t  iSectY,
int32_t  iSectYMax,
int32_t  iSectSizeX = -1,
int32_t  iSectSizeY = -1,
bool  fCenterPos = false,
int32_t  iSectNumX = 1,
int32_t  iSectNumY = 1 
)

Definition at line 1151 of file C4Gui.cpp.

References C4Rect::Hgt, iMarginX, iMarginY, rcClientArea, rcTemp, C4Rect::Wdt, C4Rect::x, and C4Rect::y.

Referenced by C4StartupAboutDlg::C4StartupAboutDlg().

1152  {
1153  int32_t iSectSizeXO = iSectSizeX, iSectSizeYO = iSectSizeY;
1154  int32_t iSectSizeXMax = (rcClientArea.Wdt-iMarginX) / iSectXMax - iMarginX;
1155  int32_t iSectSizeYMax = (rcClientArea.Hgt-iMarginY) / iSectYMax - iMarginY;
1156  if (iSectSizeX<0 || fCenterPos) iSectSizeX=iSectSizeXMax; else iSectSizeX=std::min<int32_t>(iSectSizeX, iSectSizeXMax);
1157  if (iSectSizeY<0 || fCenterPos) iSectSizeY=iSectSizeYMax; else iSectSizeY=std::min<int32_t>(iSectSizeY, iSectSizeYMax);
1158  rcTemp.x = iSectX * (iSectSizeX+iMarginX) + iMarginX + rcClientArea.x;
1159  rcTemp.y = iSectY * (iSectSizeY+iMarginY) + iMarginY + rcClientArea.y;
1160  rcTemp.Wdt = iSectSizeX * iSectNumX + iMarginX*(iSectNumX-1); rcTemp.Hgt = iSectSizeY * iSectNumY + iMarginY*(iSectNumY-1);
1161  if (iSectSizeXO>=0 && fCenterPos)
1162  {
1163  rcTemp.x += (iSectSizeX - iSectSizeXO)/2;
1164  rcTemp.Wdt = iSectSizeXO;
1165  }
1166  if (iSectSizeYO>=0 && fCenterPos)
1167  {
1168  rcTemp.y += (iSectSizeY - iSectSizeYO)/2;
1169  rcTemp.Hgt = iSectSizeYO;
1170  }
1171  return rcTemp;
1172  }
static C4Rect rcTemp
Definition: C4Gui.h:2777
int32_t Wdt
Definition: C4Rect.h:32
int32_t y
Definition: C4Rect.h:32
int32_t x
Definition: C4Rect.h:32
int32_t Hgt
Definition: C4Rect.h:32

Here is the caller graph for this function:

int32_t C4GUI::ComponentAligner::GetHeight ( ) const
inline

Definition at line 2801 of file C4Gui.h.

References C4Rect::Hgt.

Referenced by C4LeagueSignupDialog::C4LeagueSignupDialog(), C4StartupAboutDlg::C4StartupAboutDlg(), C4StartupNetDlg::C4StartupNetDlg(), C4StartupOptionsDlg::C4StartupOptionsDlg(), C4StartupPlrSelDlg::C4StartupPlrSelDlg(), C4StartupScenSelDlg::C4StartupScenSelDlg(), C4GUI::MessageDialog::MessageDialog(), and C4StartupScenSelDlg::ScenListItem::UpdateOwnPos().

2801 { return rcClientArea.Hgt; }
int32_t Hgt
Definition: C4Rect.h:32

Here is the caller graph for this function:

int32_t C4GUI::ComponentAligner::GetHMargin ( ) const
inline

Definition at line 2802 of file C4Gui.h.

References iMarginX.

2802 { return iMarginX; }
int32_t C4GUI::ComponentAligner::GetInnerHeight ( ) const
inline

Definition at line 2806 of file C4Gui.h.

References C4Rect::Hgt, and iMarginY.

Referenced by C4GameOverDlg::C4GameOverDlg(), C4Network2ClientListDlg::C4Network2ClientListDlg(), C4FileSelDlg::DefaultListItem::DefaultListItem(), C4ChatControl::ChatSheet::NickItem::UpdateOwnPos(), and C4FileSelDlg::DefaultListItem::UpdateOwnPos().

2806 { return rcClientArea.Hgt-2*iMarginY; }
int32_t Hgt
Definition: C4Rect.h:32

Here is the caller graph for this function:

int32_t C4GUI::ComponentAligner::GetInnerWidth ( ) const
inline

Definition at line 2805 of file C4Gui.h.

References iMarginX, and C4Rect::Wdt.

Referenced by C4GameOverDlg::C4GameOverDlg(), C4LeagueSignupDialog::C4LeagueSignupDialog(), C4StartupAboutDlg::C4StartupAboutDlg(), C4StartupOptionsDlg::C4StartupOptionsDlg(), and C4GUI::MessageDialog::MessageDialog().

2805 { return rcClientArea.Wdt-2*iMarginX; }
int32_t Wdt
Definition: C4Rect.h:32

Here is the caller graph for this function:

int32_t C4GUI::ComponentAligner::GetVMargin ( ) const
inline

Definition at line 2803 of file C4Gui.h.

References iMarginY.

2803 { return iMarginY; }
int32_t C4GUI::ComponentAligner::GetWidth ( ) const
inline

Definition at line 2800 of file C4Gui.h.

References C4Rect::Wdt.

Referenced by C4GameOverDlg::C4GameOverDlg(), C4StartupNetDlg::C4StartupNetDlg(), C4StartupOptionsDlg::C4StartupOptionsDlg(), C4StartupPlrSelDlg::C4StartupPlrSelDlg(), and C4StartupScenSelDlg::C4StartupScenSelDlg().

2800 { return rcClientArea.Wdt; }
int32_t Wdt
Definition: C4Rect.h:32

Here is the caller graph for this function:

void C4GUI::ComponentAligner::LogIt ( const char *  szName)

Definition at line 1146 of file C4Gui.cpp.

References C4Rect::Hgt, iMarginX, iMarginY, LogF(), rcClientArea, C4Rect::Wdt, C4Rect::x, and C4Rect::y.

1147  {
1148  LogF("ComponentAligner %s: (%d,%d)+(%d,%d), Margin (%d,%d)", szName, rcClientArea.x, rcClientArea.y, rcClientArea.Wdt, rcClientArea.Hgt, iMarginX, iMarginY);
1149  }
int32_t Wdt
Definition: C4Rect.h:32
int32_t y
Definition: C4Rect.h:32
int32_t x
Definition: C4Rect.h:32
int32_t Hgt
Definition: C4Rect.h:32
bool LogF(const char *strMessage,...)
Definition: C4Log.cpp:253

Here is the call graph for this function:

Member Data Documentation

int32_t C4GUI::ComponentAligner::iMarginX
protected
int32_t C4GUI::ComponentAligner::iMarginY
protected
C4Rect C4GUI::ComponentAligner::rcClientArea
protected
C4Rect C4GUI::ComponentAligner::rcTemp
staticprotected

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