1 \section{\class{wxLayoutConstraints
}}\label{wxlayoutconstraints
}
3 {\bf Note:
} constraints are now deprecated and you should use
\helpref{sizers
}{sizeroverview
} instead.
5 Objects of this class can be associated with a window to define its
6 layout constraints, with respect to siblings or its parent.
8 The class consists of the following eight constraints of class wxIndividualLayoutConstraint,
9 some or all of which should be accessed directly to set the appropriate
12 \begin{itemize
}\itemsep=
0pt
13 \item {\bf left:
} represents the left hand edge of the window
14 \item {\bf right:
} represents the right hand edge of the window
15 \item {\bf top:
} represents the top edge of the window
16 \item {\bf bottom:
} represents the bottom edge of the window
17 \item {\bf width:
} represents the width of the window
18 \item {\bf height:
} represents the height of the window
19 \item {\bf centreX:
} represents the horizontal centre point of the window
20 \item {\bf centreY:
} represents the vertical centre point of the window
23 Most constraints are initially set to have the relationship wxUnconstrained,
24 which means that their values should be calculated by looking at known constraints.
25 The exceptions are
{\it width
} and
{\it height
}, which are set to wxAsIs to
26 ensure that if the user does not specify a constraint, the existing
27 width and height will be used, to be compatible with panel items which often
28 have take a default size. If the constraint is wxAsIs, the dimension will
31 \perlnote{In wxPerl the constraints are accessed as
33 constraint = Wx::LayoutConstraints->new();
34 constraint->centreX->AsIs();
35 constraint->centreY->Unconstrained();
39 \wxheading{Derived from
}
41 \helpref{wxObject
}{wxobject
}
43 \wxheading{Include files
}
49 \helpref{wxCore
}{librarieslist
}
53 \helpref{Overview and examples
}{constraintsoverview
},
\rtfsp
54 \helpref{wxIndividualLayoutConstraint
}{wxindividuallayoutconstraint
},
\helpref{wxWindow::SetConstraints
}{wxwindowsetconstraints
}
56 \latexignore{\rtfignore{\wxheading{Members
}}}
58 \membersection{wxLayoutConstraints::wxLayoutConstraints
}\label{wxlayoutconstraintsctor
}
60 \func{}{wxLayoutConstraints
}{\void}
64 \membersection{wxLayoutConstraints::bottom
}\label{wxlayoutconstraintsbottom
}
66 \member{wxIndividualLayoutConstraint
}{bottom
}
68 Constraint for the bottom edge.
70 \membersection{wxLayoutConstraints::centreX
}\label{wxlayoutconstraintscentrex
}
72 \member{wxIndividualLayoutConstraint
}{centreX
}
74 Constraint for the horizontal centre point.
76 \membersection{wxLayoutConstraints::centreY
}\label{wxlayoutconstraintscentrey
}
78 \member{wxIndividualLayoutConstraint
}{centreY
}
80 Constraint for the vertical centre point.
82 \membersection{wxLayoutConstraints::height
}\label{wxlayoutconstraintsheight
}
84 \member{wxIndividualLayoutConstraint
}{height
}
86 Constraint for the height.
88 \membersection{wxLayoutConstraints::left
}\label{wxlayoutconstraintsleft
}
90 \member{wxIndividualLayoutConstraint
}{left
}
92 Constraint for the left-hand edge.
94 \membersection{wxLayoutConstraints::right
}\label{wxlayoutconstraintsright
}
96 \member{wxIndividualLayoutConstraint
}{right
}
98 Constraint for the right-hand edge.
100 \membersection{wxLayoutConstraints::top
}\label{wxlayoutconstraintstop
}
102 \member{wxIndividualLayoutConstraint
}{top
}
104 Constraint for the top edge.
106 \membersection{wxLayoutConstraints::width
}\label{wxlayoutconstraintswidth
}
108 \member{wxIndividualLayoutConstraint
}{width
}
110 Constraint for the width.