BaseWindow.h
Go to the documentation of this file.
1 /*--------------------------------------------------------------------------------------+
2 |
3 | Supplied under applicable software license agreement.
4 |
5 | Copyright (c) 2018 Bentley Systems, Incorporated. All rights reserved.
6 |
7 +---------------------------------------------------------------------------------------*/
8 #pragma once
9 
10 #include <Mstn\MstnDefs.h>
11 #include <Mstn\MdlApi\mstypes.h>
12 
13 #if defined (_WINDOWS_)
14 typedef HWND WinHWnd;
15 typedef HDC WinDC;
16 #else
17 typedef void* WinHWnd;
18 typedef void* WinDC;
19 #endif
20 
21 typedef WinHWnd Window;
22 
23 
24 //=======================================================================================
31 //=======================================================================================
32 struct WindowInfo
33  {
35  MSCORE_EXPORT WindowInfo* GetNext ();
37  MSCORE_EXPORT WindowInfo* GetPrevious ();
39  MSCORE_EXPORT Window GetGraphHandle ();
41  MSCORE_EXPORT int GetScreenNumber ();
42 
43  };
44 
45 //=======================================================================================
52 //=======================================================================================
54  {
56  MSCORE_EXPORT bool IsDisplayed ();
57 
59  MSCORE_EXPORT bool Maximized ();
60 
62  MSCORE_EXPORT bool Minimized ();
63 
65  MSCORE_EXPORT Point2d GetDockExtent ();
66 
69  MSCORE_EXPORT DockPosition GetDockPosition ();
70 
73  MSCORE_EXPORT DockPriority GetDockPriority ();
74 
81  MSCORE_EXPORT BSIRect const& GetContentRect ();
82 
89  MSCORE_EXPORT BSIRect const& GetGlobalRect ();
90 
92  MSCORE_EXPORT WinDC GetScreenContext ();
93 
95  MSCORE_EXPORT WinDC GetDoubleBufferContext ();
96 
98  MSCORE_EXPORT WCharCP GetTitleCP ();
99 
102  MSCORE_EXPORT void GetTitle (WStringR title);
103 
106  MSCORE_EXPORT StatusInt SetTitle (WCharCP title);
107 
108  };
109 
bool IsDisplayed()
Determines whether the Window has been displayed initially.
BSIRect const & GetContentRect()
Returns the content rectangle for the Window.
HANDLE HWND
Definition: msnativewindow.h:27
void * WinHWnd
Definition: BaseWindow.h:17
DockPriority
Definition: MicroStation.r.h:614
void * WinDC
Definition: BaseWindow.h:18
int GetScreenNumber()
Returns the screen number for the Window.
WindowInfo * GetNext()
Returns the next Window in the linked list.
wchar_t const * WCharCP
Definition: Bentley.h:224
struct Bentley::WString & WStringR
Definition: Bentley.h:239
bool Maximized()
Determines whether the Window is currently maximized.
WinDC GetScreenContext()
Returns the screen device context for the Window.
BaseWindow maintains low-level information about the state of a Microstation/PowerPlatform desktop-ba...
Definition: BaseWindow.h:53
StatusInt SetTitle(WCharCP title)
Sets the title for the Window.
WinDC GetDoubleBufferContext()
Returns the double-buffer context for the Window.
Point2d GetDockExtent()
Returns the size of the Window as docked.
DockPosition
Definition: MicroStation.r.h:602
bool Minimized()
Determines whether the Window is currently minimized.
WindowInfo * GetPrevious()
Returns the previous Window in the linked list.
WCharCP GetTitleCP()
Returns a pointer to the title for the Window.
WinHWnd Window
Definition: BaseWindow.h:21
void GetTitle(WStringR title)
Gets the title for the Window.
int StatusInt
Definition: Bentley.h:222
WindowInfo maintains low-level information about a Microstation/PowerPlatform desktop-based window...
Definition: BaseWindow.h:32
DockPosition GetDockPosition()
Returns the dock position of the Window.
BSIRect const & GetGlobalRect()
Returns the global rectangle for the Window.
DockPriority GetDockPriority()
Returns the dock priority of the Window.
Window GetGraphHandle()
Returns the Graphics Handle for the Window. In Microsoft Windows, this is an HWND.

Copyright © 2017 Bentley Systems, Incorporated. All rights reserved.