Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(115)

Side by Side Diff: xfa/fxfa/parser/cxfa_widgetdata.h

Issue 1861353002: Split fxfa_objectacc.h into pieces. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « xfa/fxfa/parser/cxfa_value.cpp ('k') | xfa/fxfa/parser/cxfa_widgetdata.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2016 PDFium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6
7 #ifndef XFA_FXFA_PARSER_CXFA_WIDGETDATA_H_
8 #define XFA_FXFA_PARSER_CXFA_WIDGETDATA_H_
9
10 #include "core/fxcrt/include/fx_string.h"
11 #include "core/fxcrt/include/fx_system.h"
12 #include "xfa/fxfa/parser/cxfa_assist.h"
13 #include "xfa/fxfa/parser/cxfa_bind.h"
14 #include "xfa/fxfa/parser/cxfa_border.h"
15 #include "xfa/fxfa/parser/cxfa_calculate.h"
16 #include "xfa/fxfa/parser/cxfa_caption.h"
17 #include "xfa/fxfa/parser/cxfa_data.h"
18 #include "xfa/fxfa/parser/cxfa_font.h"
19 #include "xfa/fxfa/parser/cxfa_margin.h"
20 #include "xfa/fxfa/parser/cxfa_para.h"
21 #include "xfa/fxfa/parser/cxfa_validate.h"
22 #include "xfa/fxfa/parser/xfa_object.h"
23
24 enum XFA_CHECKSTATE {
25 XFA_CHECKSTATE_On = 0,
26 XFA_CHECKSTATE_Off = 1,
27 XFA_CHECKSTATE_Neutral = 2,
28 };
29
30 enum XFA_VALUEPICTURE {
31 XFA_VALUEPICTURE_Raw = 0,
32 XFA_VALUEPICTURE_Display,
33 XFA_VALUEPICTURE_Edit,
34 XFA_VALUEPICTURE_DataBind,
35 };
36
37 class CXFA_Node;
38 class IFX_Locale;
39
40 class CXFA_WidgetData : public CXFA_Data {
41 public:
42 explicit CXFA_WidgetData(CXFA_Node* pNode);
43
44 CXFA_Node* GetUIChild();
45 XFA_ELEMENT GetUIType();
46 CFX_WideString GetRawValue();
47 int32_t GetAccess(FX_BOOL bTemplate = FALSE);
48 int32_t GetRotate();
49 CXFA_Border GetBorder(FX_BOOL bModified = FALSE);
50 CXFA_Caption GetCaption(FX_BOOL bModified = FALSE);
51 CXFA_Font GetFont(FX_BOOL bModified = FALSE);
52 CXFA_Margin GetMargin(FX_BOOL bModified = FALSE);
53 CXFA_Para GetPara(FX_BOOL bModified = FALSE);
54 void GetEventList(CXFA_NodeArray& events);
55 int32_t GetEventByActivity(int32_t iActivity,
56 CXFA_NodeArray& events,
57 FX_BOOL bIsFormReady = FALSE);
58 CXFA_Value GetDefaultValue(FX_BOOL bModified = FALSE);
59 CXFA_Value GetFormValue(FX_BOOL bModified = FALSE);
60 CXFA_Calculate GetCalculate(FX_BOOL bModified = FALSE);
61 CXFA_Validate GetValidate(FX_BOOL bModified = FALSE);
62 CXFA_Bind GetBind(FX_BOOL bModified = FALSE);
63 CXFA_Assist GetAssist(FX_BOOL bModified = FALSE);
64 uint32_t GetRelevantStatus();
65 FX_BOOL GetWidth(FX_FLOAT& fWidth);
66 FX_BOOL GetHeight(FX_FLOAT& fHeight);
67 FX_BOOL GetMinWidth(FX_FLOAT& fMinWidth);
68 FX_BOOL GetMinHeight(FX_FLOAT& fMinHeight);
69 FX_BOOL GetMaxWidth(FX_FLOAT& fMaxWidth);
70 FX_BOOL GetMaxHeight(FX_FLOAT& fMaxHeight);
71 CXFA_Border GetUIBorder(FX_BOOL bModified = FALSE);
72 CXFA_Margin GetUIMargin(FX_BOOL bModified = FALSE);
73 void GetUIMargin(CFX_RectF& rtUIMargin);
74 int32_t GetButtonHighlight();
75 FX_BOOL GetButtonRollover(CFX_WideString& wsRollover, FX_BOOL& bRichText);
76 FX_BOOL GetButtonDown(CFX_WideString& wsDown, FX_BOOL& bRichText);
77 int32_t GetCheckButtonShape();
78 int32_t GetCheckButtonMark();
79 FX_FLOAT GetCheckButtonSize();
80 FX_BOOL IsAllowNeutral();
81 FX_BOOL IsRadioButton();
82 XFA_CHECKSTATE GetCheckState();
83 void SetCheckState(XFA_CHECKSTATE eCheckState, FX_BOOL bNotify = TRUE);
84 CXFA_Node* GetExclGroupNode();
85 CXFA_Node* GetSelectedMember();
86 CXFA_Node* SetSelectedMember(const CFX_WideStringC& wsName,
87 FX_BOOL bNotify = TRUE);
88 void SetSelectedMemberByValue(const CFX_WideStringC& wsValue,
89 FX_BOOL bNotify = TRUE,
90 FX_BOOL bScriptModify = FALSE,
91 FX_BOOL bSyncData = TRUE);
92 CXFA_Node* GetExclGroupFirstMember();
93 CXFA_Node* GetExclGroupNextMember(CXFA_Node* pNode);
94 int32_t GetChoiceListCommitOn();
95 FX_BOOL IsChoiceListAllowTextEntry();
96 int32_t GetChoiceListOpen();
97 FX_BOOL IsListBox();
98 int32_t CountChoiceListItems(FX_BOOL bSaveValue = FALSE);
99 FX_BOOL GetChoiceListItem(CFX_WideString& wsText,
100 int32_t nIndex,
101 FX_BOOL bSaveValue = FALSE);
102 void GetChoiceListItems(CFX_WideStringArray& wsTextArray,
103 FX_BOOL bSaveValue = FALSE);
104 int32_t CountSelectedItems();
105 int32_t GetSelectedItem(int32_t nIndex = 0);
106 void GetSelectedItems(CFX_Int32Array& iSelArray);
107 void GetSelectedItemsValue(CFX_WideStringArray& wsSelTextArray);
108 FX_BOOL GetItemState(int32_t nIndex);
109 void SetItemState(int32_t nIndex,
110 FX_BOOL bSelected,
111 FX_BOOL bNotify = FALSE,
112 FX_BOOL bScriptModify = FALSE,
113 FX_BOOL bSyncData = TRUE);
114 void SetSelectdItems(CFX_Int32Array& iSelArray,
115 FX_BOOL bNotify = FALSE,
116 FX_BOOL bScriptModify = FALSE,
117 FX_BOOL bSyncData = TRUE);
118 void ClearAllSelections();
119 void InsertItem(const CFX_WideString& wsLabel,
120 const CFX_WideString& wsValue,
121 int32_t nIndex = -1,
122 FX_BOOL bNotify = FALSE);
123 void GetItemLabel(const CFX_WideStringC& wsValue, CFX_WideString& wsLabel);
124 void GetItemValue(const CFX_WideStringC& wsLabel, CFX_WideString& wsValue);
125 FX_BOOL DeleteItem(int32_t nIndex,
126 FX_BOOL bNotify = FALSE,
127 FX_BOOL bScriptModify = FALSE,
128 FX_BOOL bSyncData = TRUE);
129 int32_t GetHorizontalScrollPolicy();
130 int32_t GetNumberOfCells();
131 FX_BOOL SetValue(const CFX_WideString& wsValue, XFA_VALUEPICTURE eValueType);
132 FX_BOOL GetPictureContent(CFX_WideString& wsPicture,
133 XFA_VALUEPICTURE ePicture);
134 IFX_Locale* GetLocal();
135 FX_BOOL GetValue(CFX_WideString& wsValue, XFA_VALUEPICTURE eValueType);
136 FX_BOOL GetNormalizeDataValue(const CFX_WideStringC& wsValue,
137 CFX_WideString& wsNormalizeValue);
138 FX_BOOL GetFormatDataValue(const CFX_WideStringC& wsValue,
139 CFX_WideString& wsFormatedValue);
140 void NormalizeNumStr(const CFX_WideString& wsValue, CFX_WideString& wsOutput);
141 CFX_WideString GetBarcodeType();
142 FX_BOOL GetBarcodeAttribute_CharEncoding(int32_t& val);
143 FX_BOOL GetBarcodeAttribute_Checksum(int32_t& val);
144 FX_BOOL GetBarcodeAttribute_DataLength(int32_t& val);
145 FX_BOOL GetBarcodeAttribute_StartChar(FX_CHAR& val);
146 FX_BOOL GetBarcodeAttribute_EndChar(FX_CHAR& val);
147 FX_BOOL GetBarcodeAttribute_ECLevel(int32_t& val);
148 FX_BOOL GetBarcodeAttribute_ModuleWidth(int32_t& val);
149 FX_BOOL GetBarcodeAttribute_ModuleHeight(int32_t& val);
150 FX_BOOL GetBarcodeAttribute_PrintChecksum(FX_BOOL& val);
151 FX_BOOL GetBarcodeAttribute_TextLocation(int32_t& val);
152 FX_BOOL GetBarcodeAttribute_Truncate(FX_BOOL& val);
153 FX_BOOL GetBarcodeAttribute_WideNarrowRatio(FX_FLOAT& val);
154 void GetPasswordChar(CFX_WideString& wsPassWord);
155 FX_BOOL IsMultiLine();
156 int32_t GetVerticalScrollPolicy();
157 int32_t GetMaxChars(XFA_ELEMENT& eType);
158 FX_BOOL GetFracDigits(int32_t& iFracDigits);
159 FX_BOOL GetLeadDigits(int32_t& iLeadDigits);
160
161 CFX_WideString NumericLimit(const CFX_WideString& wsValue,
162 int32_t iLead,
163 int32_t iTread) const;
164
165 FX_BOOL m_bIsNull;
166 FX_BOOL m_bPreNull;
167
168 protected:
169 void SyncValue(const CFX_WideString& wsValue, FX_BOOL bNotify);
170 void InsertListTextItem(CXFA_Node* pItems,
171 const CFX_WideStringC& wsText,
172 int32_t nIndex = -1);
173 void FormatNumStr(const CFX_WideString& wsValue,
174 IFX_Locale* pLocale,
175 CFX_WideString& wsOutput);
176
177 CXFA_Node* m_pUiChildNode;
178 XFA_ELEMENT m_eUIType;
179 };
180
181 #endif // XFA_FXFA_PARSER_CXFA_WIDGETDATA_H_
OLDNEW
« no previous file with comments | « xfa/fxfa/parser/cxfa_value.cpp ('k') | xfa/fxfa/parser/cxfa_widgetdata.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698