CFx SDK Documentation 2024 SP0
Loading...
Searching...
No Matches
DbGsManager.h
Go to the documentation of this file.
1
2// Copyright (C) 2002-2022, Open Design Alliance (the "Alliance").
3// All rights reserved.
4//
5// This software and its documentation and related materials are owned by
6// the Alliance. The software may only be incorporated into application
7// programs owned by members of the Alliance, subject to a signed
8// Membership Agreement and Supplemental Software License Agreement with the
9// Alliance. The structure and organization of this software are the valuable
10// trade secrets of the Alliance and its suppliers. The software is also
11// protected by copyright law and international treaty provisions. Application
12// programs incorporating this software must include the following statement
13// with their copyright notices:
14//
15// This application incorporates Open Design Alliance software pursuant to a license
16// agreement with Open Design Alliance.
17// Open Design Alliance Copyright (C) 2002-2022 by Open Design Alliance.
18// All rights reserved.
19//
20// By use of this software, its documentation or related materials, you
21// acknowledge and accept the above terms.
23
24#ifndef __DBGSMANAGER_H_INCLUDED_
25#define __DBGSMANAGER_H_INCLUDED_
26
27class OdDbObjectId;
28class OdDbViewport;
29class OdDbDatabase;
31
32#include "Gs/Gs.h"
33#include "DbExport.h"
34
35#include "TD_PackPush.h"
36
42{
43public:
48 virtual OdDbObjectId layoutId() const = 0;
52 virtual OdGsViewPtr activeView() const = 0;
57 virtual void makeViewActive(OdGsView* pView) = 0;
61 virtual OdGsModel* gsModel() = 0;
62
66 virtual OdGsDevicePtr underlyingDevice() const = 0;
67
72 virtual bool setActiveViewport(const OdGePoint2d& screenPt) = 0;
73
77 virtual bool setActiveViewport(const OdDbObjectId& id) = 0;
78
82 virtual void restoreGsViewDbLinkState() = 0;
83
87 virtual bool supportLayoutGsStateSaving() const = 0;
93 virtual bool storeLayoutGsState(OdStreamBuf* pStream, OdUInt32 nFlags = 0) const = 0;
101 static bool extractLayoutIdForGsState(OdStreamBuf* pStream, OdDbDatabase *pDb, OdDbObjectId &layoutObjId, OdUInt32 nFlags = 0);
108 virtual bool restoreLayoutGsState(OdStreamBuf* pStream, OdUInt32 nFlags = 0) = 0;
109};
110
112
113
119{
120public:
122
123 virtual OdGsViewPtr overallView() const = 0;
124 virtual void makeViewOverall(OdGsView* pView) = 0;
125 virtual void initGsView(OdGsView* pView, const OdDbViewport* pVp) = 0;
126
128 virtual OdGsViewPtr insertViewport(int viewIndex, const OdDbViewport* pVp);
129
130 // Viewport filters behavior
131
136 {
137 kVpScreenFilter = (1 << 0), // Check does viewport is visible on screen.
138 kVpSizeFilter = (1 << 1), // Check does viewport dimensions larger corresponding value.
139 kVpMaxActFilter = (1 << 2) // Check does viewport number does not exceeds MAXACTVP variable.
140 };
145 {
146 kVpBrDefault = 1, // Default branch.
147 kVpBrPlot = 2, // Plot generation branch.
148 kVpBrAll = 3 // All viewport filter branches.
149 };
154 {
155 kVpFilterVisible = 3, // Apply filter with visible effect (default).
156 kVpFilterInvisible = 1, // Apply filter without visible effect.
157 kVpFilterDisable = 0 // Avoid filter application.
158 };
166 virtual void setViewportFilter(ViewportFilter vpFilter, ViewportFilterBranch filterBranch = kVpBrAll,
167 ViewportFilterMode filterMode = kVpFilterVisible, OdUInt32 filterParam = 0);
168};
169
171
178{
179public:
181};
182
184
185
191{
198
205
210 OdDbStub* layoutId = 0, ODCOLORREF palBackground = ODRGBA(0,0,0,0));
211}
212
213#include "TD_PackPop.h"
214
215#endif // __DBGSMANAGER_H_INCLUDED_
216
#define TOOLKIT_EXPORT
Definition: DbExport.h:40
OdSmartPtr< OdGsPaperLayoutHelper > OdGsPaperLayoutHelperPtr
Definition: DbGsManager.h:170
OdSmartPtr< OdGsModelLayoutHelper > OdGsModelLayoutHelperPtr
Definition: DbGsManager.h:183
OdSmartPtr< OdGsLayoutHelper > OdGsLayoutHelperPtr
Definition: DbGsManager.h:111
#define ODCOLORREF
Definition: OdPlatform.h:933
#define ODRGBA(r, g, b, a)
Definition: OdPlatform.h:935
unsigned int OdUInt32
virtual OdGsModel * gsModel()=0
virtual bool supportLayoutGsStateSaving() const =0
virtual bool storeLayoutGsState(OdStreamBuf *pStream, OdUInt32 nFlags=0) const =0
virtual bool setActiveViewport(const OdDbObjectId &id)=0
virtual void restoreGsViewDbLinkState()=0
virtual bool restoreLayoutGsState(OdStreamBuf *pStream, OdUInt32 nFlags=0)=0
static bool extractLayoutIdForGsState(OdStreamBuf *pStream, OdDbDatabase *pDb, OdDbObjectId &layoutObjId, OdUInt32 nFlags=0)
virtual bool setActiveViewport(const OdGePoint2d &screenPt)=0
virtual OdGsDevicePtr underlyingDevice() const =0
virtual void makeViewActive(OdGsView *pView)=0
virtual OdGsViewPtr activeView() const =0
ODRX_DECLARE_MEMBERS(OdGsLayoutHelper)
virtual OdDbObjectId layoutId() const =0
ODRX_DECLARE_MEMBERS(OdGsModelLayoutHelper)
virtual OdGsViewPtr overallView() const =0
virtual void makeViewOverall(OdGsView *pView)=0
virtual OdGsViewPtr insertViewport(int viewIndex, const OdDbViewport *pVp)
ODRX_DECLARE_MEMBERS(OdGsPaperLayoutHelper)
virtual void initGsView(OdGsView *pView, const OdDbViewport *pVp)=0
virtual void setViewportFilter(ViewportFilter vpFilter, ViewportFilterBranch filterBranch=kVpBrAll, ViewportFilterMode filterMode=kVpFilterVisible, OdUInt32 filterParam=0)
virtual OdGsViewPtr addViewport(const OdDbViewport *pVp)
Definition: Gs.h:140
TOOLKIT_EXPORT OdGsLayoutHelperPtr setupLayoutViews(OdDbObjectId layoutId, OdGsDevice *pDevice, OdGiContextForDbDatabase *pGiCtx)
TOOLKIT_EXPORT void setupPalette(OdGsDevice *device, OdGiContextForDbDatabase *giContext, OdDbStub *layoutId=0, ODCOLORREF palBackground=ODRGBA(0, 0, 0, 0))
TOOLKIT_EXPORT OdGsLayoutHelperPtr setupActiveLayoutViews(OdGsDevice *pDevice, OdGiContextForDbDatabase *pGiCtx)