Open CASCADE Technology
6.5.4
|
This class allows the definition of a window
Warning: The position and size for the creation of the window
are defined in Device Screen Unit (DSU)
floating [0,1] space.
#include <Aspect_Window.hxx>
Public Member Functions | |
virtual void | SetBackground (const Aspect_Background &ABack)=0 |
Modifies the window background. | |
virtual void | SetBackground (const Quantity_NameOfColor BackColor)=0 |
Modifies the window background from a Named Color. | |
virtual void | SetBackground (const Quantity_Color &color)=0 |
Modifies the window background. | |
virtual Standard_Boolean | SetBackground (const Standard_CString aName, const Aspect_FillMethod aMethod=Aspect_FM_CENTERED)=0 |
Loads the window background from an image file <aName> defined with a supported format XWD,GIF or BMP and returns TRUE if the operation is successfull. | |
virtual void | SetBackground (const Aspect_Handle aBitmap)=0 |
Loads the window background from a predefined bitmap. Warning: the bitmap and window must have the same depth. | |
virtual void | SetBackground (const Aspect_GradientBackground &ABackground)=0 |
Modifies the window gradient background. | |
virtual void | SetDoubleBuffer (const Standard_Boolean DBmode)=0 |
Activates/Deactivates the Double Buffering capability for this window. Warning: Double Buffering is always DISABLE by default If there is not enought ressources to activate the double-buffering the DB mode flag can be set to FALSE. | |
virtual void | Flush () const =0 |
Flushs all graphics to the screen and Swap the Double buffer if Enable | |
virtual void | Map () const =0 |
Opens the window <me>. | |
virtual void | Unmap () const =0 |
Closes the window <me>. | |
virtual Aspect_TypeOfResize | DoResize () const =0 |
Apply the resizing to the window <me>. | |
virtual Standard_Boolean | DoMapping () const =0 |
Apply the mapping change to the window <me>. and returns TRUE if the window is mapped at screen. | |
virtual void | Destroy ()=0 |
Destroy the Window | |
virtual void | Clear () const =0 |
Clear The Window in the Background Color | |
virtual void | ClearArea (const Standard_Integer XCenter, const Standard_Integer YCenter, const Standard_Integer Width, const Standard_Integer Height) const =0 |
Clear The Window Area defined in PIXELS in the Background Color | |
virtual void | Restore () const =0 |
Restore the BackingStored Window <me>. | |
virtual void | RestoreArea (const Standard_Integer XCenter, const Standard_Integer YCenter, const Standard_Integer Width, const Standard_Integer Height) const =0 |
Restore the BackingStored Window Area defined in PIXELS. | |
virtual Standard_Boolean | Dump (const Standard_CString aFilename, const Standard_Real aGammaValue=1.0) const =0 |
Dumps the Window to an image file (PNG, BMP, JPEG, GIF) with | |
virtual Standard_Boolean | DumpArea (const Standard_CString aFilename, const Standard_Integer Xc, const Standard_Integer Yc, const Standard_Integer Width, const Standard_Integer Height, const Standard_Real aGammaValue=1.0) const =0 |
Dumps the Window Area defined by his center and PIXEL size to an image file with an optional gamma correction value according to the graphic system | |
virtual Standard_Boolean | Load (const Standard_CString aFilename) const =0 |
Loads the XWD file to this Window. Returns TRUE if the loading occurs normaly. Warning: Note that the Window is enlarged automatically | |
virtual Standard_Boolean | LoadArea (const Standard_CString aFilename, const Standard_Integer Xc, const Standard_Integer Yc, const Standard_Integer Width, const Standard_Integer Height) const =0 |
Loads the XWD file to Window Area defined by his center | |
Aspect_Background | Background () const |
Returns the window background. | |
Standard_CString | BackgroundImage () const |
Returns the current image background string or NULL if nothing is defined. | |
Aspect_FillMethod | BackgroundFillMethod () const |
Returns the current image background fill mode. | |
Aspect_GradientBackground | GradientBackground () const |
Returns the window gradient background. | |
Aspect_Handle | HBackground () const |
Returns the background bitmap handle or 0 when nothing is defined | |
Handle_Aspect_GraphicDevice | GraphicDevice () const |
Returns the Graphic Device associated to this Window. | |
virtual Standard_Boolean | IsMapped () const =0 |
Returns True if the window <me> is opened and False if the window is closed. | |
Standard_Boolean | IsVirtual () const |
Returns True if the window <me> is virtual | |
void | SetVirtual (const Standard_Boolean theVirtual) |
Setup the virtual state | |
virtual Quantity_Ratio | Ratio () const =0 |
Returns The Window RATIO equal to the physical WIDTH/HEIGHT dimensions | |
virtual void | Position (Quantity_Parameter &X1, Quantity_Parameter &Y1, Quantity_Parameter &X2, Quantity_Parameter &Y2) const =0 |
Returns The Window POSITION in DSU | |
virtual void | Position (Standard_Integer &X1, Standard_Integer &Y1, Standard_Integer &X2, Standard_Integer &Y2) const =0 |
Returns The Window POSITION in PIXEL | |
virtual void | Size (Quantity_Parameter &Width, Quantity_Parameter &Height) const =0 |
Returns The Window SIZE in DSU | |
virtual void | Size (Standard_Integer &Width, Standard_Integer &Height) const =0 |
Returns The Window SIZE in PIXEL | |
virtual void | MMSize (Standard_Real &Width, Standard_Real &Height) const =0 |
Returns The Window SIZE in MM | |
virtual Quantity_Parameter | Convert (const Standard_Integer PV) const =0 |
Returns the DSU value depending of the PIXEL value. | |
virtual Standard_Integer | Convert (const Quantity_Parameter DV) const =0 |
Returns the PIXEL value depending of the DSU value. | |
virtual void | Convert (const Standard_Integer PX, const Standard_Integer PY, Quantity_Parameter &DX, Quantity_Parameter &DY) const =0 |
Returns the DSU position depending of the PIXEL position. | |
virtual void | Convert (const Quantity_Parameter DX, const Quantity_Parameter DY, Standard_Integer &PX, Standard_Integer &PY) const =0 |
Returns the PIXEL position depending of the DSU position. | |
virtual Standard_Boolean | BackingStore () const =0 |
Returns the BackingStore capability for this Window . If Answer is True Exposure can be recovered by Restore RestoreArea methods . If Answer is False,Application must Redraw the exposed area. | |
virtual Standard_Boolean | DoubleBuffer () const =0 |
Returns the DoubleBuffer state. | |
Protected Member Functions | |
Aspect_Window (const Handle< Aspect_GraphicDevice > &aGraphicDevice) | |
Initializes the datas of a Window. | |
Protected Attributes | |
Handle_Aspect_GraphicDevice | MyGraphicDevice |
Aspect_Background | MyBackground |
TCollection_AsciiString | MyBackgroundImage |
Aspect_FillMethod | MyBackgroundFillMethod |
Aspect_Handle | MyHBackground |
Aspect_GradientBackground | MyGradientBackground |
Standard_Boolean | MyIsVirtual |
Aspect_Window::Aspect_Window | ( | const Handle< Aspect_GraphicDevice > & | aGraphicDevice | ) | [protected] |
Aspect_Background Aspect_Window::Background | ( | ) | const |
virtual Standard_Boolean Aspect_Window::BackingStore | ( | ) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::Clear | ( | ) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::ClearArea | ( | const Standard_Integer | XCenter, |
const Standard_Integer | YCenter, | ||
const Standard_Integer | Width, | ||
const Standard_Integer | Height | ||
) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual Quantity_Parameter Aspect_Window::Convert | ( | const Standard_Integer | PV | ) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual Standard_Integer Aspect_Window::Convert | ( | const Quantity_Parameter | DV | ) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::Convert | ( | const Standard_Integer | PX, |
const Standard_Integer | PY, | ||
Quantity_Parameter & | DX, | ||
Quantity_Parameter & | DY | ||
) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::Convert | ( | const Quantity_Parameter | DX, |
const Quantity_Parameter | DY, | ||
Standard_Integer & | PX, | ||
Standard_Integer & | PY | ||
) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::Destroy | ( | ) | [pure virtual] |
Implemented in Xw_Window, WNT_Window, Xw_IconBox, and WNT_IconBox.
virtual Standard_Boolean Aspect_Window::DoMapping | ( | ) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual Aspect_TypeOfResize Aspect_Window::DoResize | ( | ) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual Standard_Boolean Aspect_Window::DoubleBuffer | ( | ) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual Standard_Boolean Aspect_Window::Dump | ( | const Standard_CString | aFilename, |
const Standard_Real | aGammaValue = 1.0 |
||
) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual Standard_Boolean Aspect_Window::DumpArea | ( | const Standard_CString | aFilename, |
const Standard_Integer | Xc, | ||
const Standard_Integer | Yc, | ||
const Standard_Integer | Width, | ||
const Standard_Integer | Height, | ||
const Standard_Real | aGammaValue = 1.0 |
||
) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::Flush | ( | ) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
Handle_Aspect_GraphicDevice Aspect_Window::GraphicDevice | ( | ) | const |
Aspect_Handle Aspect_Window::HBackground | ( | ) | const |
virtual Standard_Boolean Aspect_Window::IsMapped | ( | ) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
Standard_Boolean Aspect_Window::IsVirtual | ( | ) | const |
virtual Standard_Boolean Aspect_Window::Load | ( | const Standard_CString | aFilename | ) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual Standard_Boolean Aspect_Window::LoadArea | ( | const Standard_CString | aFilename, |
const Standard_Integer | Xc, | ||
const Standard_Integer | Yc, | ||
const Standard_Integer | Width, | ||
const Standard_Integer | Height | ||
) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::Map | ( | ) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::MMSize | ( | Standard_Real & | Width, |
Standard_Real & | Height | ||
) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::Position | ( | Quantity_Parameter & | X1, |
Quantity_Parameter & | Y1, | ||
Quantity_Parameter & | X2, | ||
Quantity_Parameter & | Y2 | ||
) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::Position | ( | Standard_Integer & | X1, |
Standard_Integer & | Y1, | ||
Standard_Integer & | X2, | ||
Standard_Integer & | Y2 | ||
) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual Quantity_Ratio Aspect_Window::Ratio | ( | ) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::Restore | ( | ) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::RestoreArea | ( | const Standard_Integer | XCenter, |
const Standard_Integer | YCenter, | ||
const Standard_Integer | Width, | ||
const Standard_Integer | Height | ||
) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::SetBackground | ( | const Aspect_Background & | ABack | ) | [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::SetBackground | ( | const Quantity_NameOfColor | BackColor | ) | [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::SetBackground | ( | const Quantity_Color & | color | ) | [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual Standard_Boolean Aspect_Window::SetBackground | ( | const Standard_CString | aName, |
const Aspect_FillMethod | aMethod = Aspect_FM_CENTERED |
||
) | [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::SetBackground | ( | const Aspect_Handle | aBitmap | ) | [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::SetBackground | ( | const Aspect_GradientBackground & | ABackground | ) | [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::SetDoubleBuffer | ( | const Standard_Boolean | DBmode | ) | [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
void Aspect_Window::SetVirtual | ( | const Standard_Boolean | theVirtual | ) |
virtual void Aspect_Window::Size | ( | Quantity_Parameter & | Width, |
Quantity_Parameter & | Height | ||
) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::Size | ( | Standard_Integer & | Width, |
Standard_Integer & | Height | ||
) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
virtual void Aspect_Window::Unmap | ( | ) | const [pure virtual] |
Implemented in Xw_Window, and WNT_Window.
Aspect_Background Aspect_Window::MyBackground [protected] |
Handle_Aspect_GraphicDevice Aspect_Window::MyGraphicDevice [protected] |
Aspect_Handle Aspect_Window::MyHBackground [protected] |
Standard_Boolean Aspect_Window::MyIsVirtual [protected] |