Alphabetical Class Index  Class Hierarchy   File Members   Compound Members   File List  

HIOUtilityPDF.h
1 //
2 // Copyright (c) 2000 by Tech Soft 3D, LLC.
3 // The information contained herein is confidential and proprietary to
4 // Tech Soft 3D, LLC., and considered a trade secret as defined under
5 // civil and criminal statutes. Tech Soft 3D shall pursue its civil
6 // and criminal remedies in the event of unauthorized use or misappropriation
7 // of its trade secrets. Use of this information by anyone other than
8 // authorized employees of Tech Soft 3D, LLC. is granted only under a
9 // written non-disclosure agreement, expressly prescribing the scope and
10 // manner of such use.
11 //
12 // $Id: fc0e33caf1f494e3229a5b95240fc2d33074ddaa $
13 //
14 
15 #ifndef _HIOUTILITYPDF_H
16 #define _HIOUTILITYPDF_H
17 
18 #ifdef H_PACK_8
19 #pragma pack(push)
20 #pragma pack(8)
21 #endif
22 
23 #include "HTools.h"
24 #include "HIOManager.h"
25 #include "HDB.h"
26 #include <string>
27 #include <map>
28 #include "vlist.h"
29 
30 
31 
38 class MVO_API HU3DOptions
39 {
40 public:
42  HU3DOptions() {Reset();};
44  void Reset(){
45  m_bExportLines = m_bExportAnnotations = false;
46  };
47 
49  bool m_bExportLines;
52 
54  bool ExportLines() const {return m_bExportLines;};
56  void ExportLines(bool onoff) {m_bExportLines = onoff;};
58  bool ExportAnnotations() const {return m_bExportAnnotations;};
60  void ExportAnnotations(bool onoff) {m_bExportAnnotations = onoff;};
61 };
62 
63 
66 class MVO_API HIOUtilityPDF: public HOutputHandler
67 {
68 public:
71  SetOutputOps(HOutputOpFileOutputByKey);
72  };
73 
74  ~HIOUtilityPDF() {;};
75 
78  const char * GetOutputName() { return "HIOUtilityPDF"; }
79 
82  HC_Begin_Segment_Search("/driver/pdf");{
83  char seg[100];
84  while(HC_Find_Segment(seg)){
85  if(strieq(seg, "/driver/pdf")){
86  HIORegisterOutputType("pdf",this);
87  break;
88  }
89  }
91  };
92 
94  const char * GetOutputTypesString() {return "pdf";};
97 
99  const char * GetOutputDefaultHSRA() {return "painters";};
100 
104  bool Has3dSupport(){
105  return (HDB::GetHIOManager()->GetOutputHandler("u3d") != (HOutputHandler*)0);
106  }
107 
114  HFileOutputResult FileOutputByKey(const __wchar_t * filename, HC_KEY key, HOutputHandlerOptions * options);
115 
116 #ifdef _MSC_VER
117  HFileOutputResult FileOutputByKey(const unsigned short * filename, HC_KEY key, HOutputHandlerOptions * options){
118  H_UTF16 utf16;
119  utf16.encodedText((utf16_char const*) filename);
120  return FileOutputByKey(H_WCS(utf16).encodedText(), key, options);
121  }
122 #endif
123 
124  HFileOutputResult FileOutputByKey(const char * filename, HC_KEY key, HOutputHandlerOptions * options){
125  return FileOutputByKey(H_WCS(filename).encodedText(), key, options);
126  }
127 
128 protected:
135  HFileOutputResult FileOutputByKey2D(const __wchar_t * filename, HC_KEY key, HOutputHandlerOptions * options);
136  HFileOutputResult FileOutputByKey2D(const char * filename, HC_KEY key, HOutputHandlerOptions * options){
137  return FileOutputByKey2D((__wchar_t*)H_WCS(filename).encodedText(), key, options);
138  }
139 
140 
141 };
142 
143 
144 
145 
146 
147 
148 
149 #ifdef H_PACK_8
150 #pragma pack(pop)
151 #endif
152 
153 #endif
bool ExportLines() const
Definition: HIOUtilityPDF.h:54
void ExportLines(bool onoff)
Definition: HIOUtilityPDF.h:56
HIOUtilityPDF()
Definition: HIOUtilityPDF.h:70
void ExportAnnotations(bool onoff)
Definition: HIOUtilityPDF.h:60
#define HOutputOpFileOutputByKey
This HOutputHandler supports output from a segment key.
Definition: HIOManager.h:75
void HC_End_Segment_Search(void)
Definition: HIOUtilityPDF.h:66
bool ExportAnnotations() const
Definition: HIOUtilityPDF.h:58
HOutputHandlerStyle
Definition: HIOManager.h:858
Specifies an #HOutputHandler for an image.
Definition: HIOManager.h:862
void RegisterOutputHandlerTypes()
Definition: HIOUtilityPDF.h:81
#define HIORegisterOutputType(type, output_object)
HIORegisterOutputType(type,output_object) Used by a HOutputHandler to set extension types that it han...
Definition: HIOManager.h:92
const char * GetOutputDefaultHSRA()
Definition: HIOUtilityPDF.h:99
HOutputHandlerStyle GetOutputStyle()
Definition: HIOUtilityPDF.h:96
const char * GetOutputName()
Definition: HIOUtilityPDF.h:78
Definition: HIOUtilityPDF.h:38
HU3DOptions()
Definition: HIOUtilityPDF.h:42
static HIOManager * GetHIOManager()
bool m_bExportAnnotations
Definition: HIOUtilityPDF.h:51
const char * GetOutputTypesString()
Definition: HIOUtilityPDF.h:94
A header file containing the HIO classes for passing to HBaseView::FileInput and HBaseView::FileOutpu...
HC_BOOLEAN HC_Find_Segment(char *segment)
void Reset()
Definition: HIOUtilityPDF.h:44
void HC_Begin_Segment_Search(const char *segspec)
bool Has3dSupport()
Definition: HIOUtilityPDF.h:104