VCF::Window Class Reference
A frame with min. More...
#include <vcf/ApplicationKit/Window.h>
Inheritance diagram for VCF::Window:

Public Types | |
| enum | WindowEvents { weRestore } |
Public Member Functions | |
| Window () | |
| Window (Control *control) | |
| virtual | ~Window () |
| virtual WindowMinimize void | setCaption (const String &caption) |
| Sets the caption for the frame. | |
| virtual void | paint (GraphicsContext *context) |
| Paints the control. | |
| virtual void | resizeChildren (Control *control) |
| overridden to take into account client bounds | |
| virtual Rect | getClientBounds (const bool &includeBorder=true) |
| returns the client bounds of a window. | |
| virtual void | setClientBounds (Rect *bounds) |
| Sets the client bounds only. | |
| MenuBar * | getMenuBar () |
| Returns the menu bar for the window. | |
| void | setMenuBar (MenuBar *menuBar) |
| Sets the menu bar for the window. | |
| virtual void | beforeDestroy (ComponentEvent *event) |
| called just prior to completely destroying the control and it's associated memory. | |
| virtual void | close () |
| Closes the Frame. | |
| virtual void | setFrameStyle (const FrameStyleType &frameStyle) |
| Sets the frame style @ see FrameStyleType. | |
| virtual void | setFrameTopmost (const bool &isTopmost) |
| Makes this frame a topmost floating window. | |
| virtual double | getPreferredWidth () |
| returns the preferred width for this control. | |
| virtual double | getPreferredHeight () |
| returns the preferred height for this control. | |
| bool | isMaximized () |
| indicates whether or not the window is maximized. | |
| void | setMaximized (const bool maximized) |
| Sets whether or not the window is maximized. | |
| bool | isMinimized () |
| returns whether or not teh window is minimized | |
| void | setMinimized (const bool &minimized) |
| Sets whether or not the window is minimized. | |
| void | restore () |
| restores the window to it's original position prior to being minimized or maximized. | |
| virtual bool | allowsActivation () |
| Indicates to the framework whether or not this frame should allow activation. | |
| virtual void | setIconImage (Image *icon) |
| Sets the icon image. | |
| virtual Image * | getIconImage () |
| Returns the current image for the frames icon. | |
| virtual bool | isActiveFrame () |
| virtual void | setBorderPath (Path *path) |
| modifies the border of the frame to follow the series of points contained in the path. | |
| void | handleEvent (Event *event) |
| This gets called by the ControlPeer for any windowing system mouse events, as well as for any windowing system keyboard events and for any windowing system events like size changes, position changes, etc. | |
Public Attributes | |
| VCF::Delegate | WindowDelegate |
| WindowRestore VCF::Delegate | WindowDelegate |
| WindowMaximize VCF::Delegate | WindowDelegate |
Protected Member Functions | |
| void | postClose (Event *event) |
| void | onClose (FrameEvent *e) |
| virtual void | destroy () |
| called by the free() method. | |
Protected Attributes | |
| WindowPeer * | windowPeer_ |
| MenuBar * | menuBar_ |
Detailed Description
A frame with min.max, restore, and system buttons. Has a caption of the standard height.
- Event Delegates for this class:
- Window::WindowRestore
- Window::WindowMaximize
- Window::WindowMinimize
Member Enumeration Documentation
|
|
|
Constructor & Destructor Documentation
|
|
|
|
|
|
|
|
|
Member Function Documentation
|
|
Indicates to the framework whether or not this frame should allow activation. Som frames do not support becoming activated, for example the tooltip frame, or the frame that houses the dropdown list for the ComboBoxControl. Must be implemented by derived classes. Implements VCF::Frame. |
|
|
called just prior to completely destroying the control and it's associated memory.
Reimplemented from VCF::Control. |
|
|
Closes the Frame. Must be implemented by classes that derive from Frame. Implements VCF::Frame. |
|
|
called by the free() method. Should be overriden and any clean up code performed here Reimplemented from VCF::Frame. |
|
|
returns the client bounds of a window. This excludes the areas such as the nonclient border, the caption bar, etc. Reimplemented from VCF::Control. |
|
|
Returns the current image for the frames icon.
Implements VCF::Frame. |
|
|
Returns the menu bar for the window. While this is partially dependent on how the underlying windowing system implements menu bars, in general (at least on Win32 and most X11 window managers) the menu bar is attached to the window, and displayed directly under the caption bar. It is not considered part of the client region. By default, a newly created window has no menu bar.
|
|
|
returns the preferred height for this control. This is used when determing the height of the control when it is first created. Override it to provide a different value that is more acceptable for your control's initial display size. Reimplemented from VCF::Control. |
|
|
returns the preferred width for this control. This is used when determing the width of the control when it is first created. Override it to provide a different value that is more acceptable for your control's initial display size. Reimplemented from VCF::Control. |
|
|
This gets called by the ControlPeer for any windowing system mouse events, as well as for any windowing system keyboard events and for any windowing system events like size changes, position changes, etc. Once inside the event the Control determines the type, and behaves accordingly, as well as notifying any appropriate listeners. Reimplemented from VCF::Control. |
|
|
Implements VCF::Frame. |
|
|
indicates whether or not the window is maximized.
|
|
|
returns whether or not teh window is minimized
|
|
|
|
|
|
Paints the control. Called by the underlying windowing system whenever the control needs to be painted. Note that in some cases the GraphicsContext passed in to this method may not be the same pointer as the GraphicsContext that the control holds itself. During the paint() method you should only use the context value for all your drawing and not the one returned in getContext(). The value returned by getContext() should be used for drawing that takes place outside of the paint() method. If the control allows paint notification, then the framework will fire an event to the BeforeControlPainted delegate prior to calling the control's paint() method. After the paint() method has returned, if the control allows paint notification, the framework will fire an event to the AfterControlPainted delegate. This allows outside observers to take part in the paint cycle, but beware that this does come at a bit of a cost, so use this feature sparingly. Note: This should NEVER be called by programmers using the VCF, it will be called for you during the course of your applications native event loop, and is only here for providing custom drawing routines for controls. In other words: you implement it, you never call it yourself.
Reimplemented from VCF::Frame. |
|
|
|
|
|
overridden to take into account client bounds
Reimplemented from VCF::DelegatedContainer< Frame >. |
|
|
restores the window to it's original position prior to being minimized or maximized.
|
|
|
modifies the border of the frame to follow the series of points contained in the path.
Reimplemented from VCF::Frame. |
|
|
Sets the caption for the frame. While the exact effects of calling this method depend on windowing system the VCF is running on, in general a caption is displayed on the top of the frame, and is generally a non client area. This method will change the text that is displayed there.
Reimplemented from VCF::Frame. |
|
|
Sets the client bounds only.
Implements VCF::Frame. |
|
|
Sets the frame style @ see FrameStyleType.
Implements VCF::Frame. |
|
|
Makes this frame a topmost floating window. This is typically used for frames that want to behave like toolbars. Reimplemented from VCF::Frame. |
|
|
Sets the icon image. The behaviour of this is partially windowing system dependent, and some systems (Mac OSX, for example, or some X11 window managers) may choose to ignore this. However, typically the icon is displayed in the top left corner of the frame, in the non client area that houses the caption. Implements VCF::Frame. |
|
|
Sets whether or not the window is maximized.
|
|
|
Sets the menu bar for the window. Note, that this currently does not add the menuBar as a component of the window. |
|
|
Sets whether or not the window is minimized.
|
Member Data Documentation
|
|
|
|
|
Reimplemented from VCF::Frame. |
|
|
Reimplemented from VCF::Frame. |
|
|
Reimplemented from VCF::Frame. |
|
|
|
The documentation for this class was generated from the following file:
- vcf/ApplicationKit/Window.h
