7#ifndef FPDFSDK_CPDFSDK_INTERACTIVEFORM_H_
8#define FPDFSDK_CPDFSDK_INTERACTIVEFORM_H_
15#include "core/fpdfdoc/cpdf_action.h"
16#include "core/fpdfdoc/cpdf_interactiveform.h"
17#include "core/fxcrt/unowned_ptr.h"
18#include "core/fxge/dib/fx_dib.h"
19#include "fpdfsdk/cpdfsdk_widget.h"
20#include "third_party/abseil-cpp/absl/types/optional.h"
26class CPDFSDK_FormFillEnvironment;
28class CPDFSDK_InteractiveForm
final
35 return m_pInteractiveForm.get();
40 std::vector<ObservedPtr<CPDFSDK_Widget>>* widgets)
const;
42 std::vector<ObservedPtr<CPDFSDK_Widget>>* widgets)
const;
51 void XfaEnableCalculate(
bool bEnabled);
52 bool IsXfaCalculateEnabled()
const;
53 bool IsXfaValidationsEnabled();
54 void XfaSetValidationsEnabled(
bool bEnabled);
55 void SynchronizeField(CPDF_FormField* pFormField);
64 absl::optional<WideString> sValue);
72 const std::vector<RetainPtr<
const CPDF_Object>>& objects)
const;
74 const std::vector<CPDF_FormField*>& fields,
75 bool bIncludeOrExclude,
77 bool SubmitForm(
const WideString& sDestination);
80 const std::vector<CPDF_FormField*>& fields,
81 bool bIncludeOrExclude);
94 const WideString& csValue)
override;
97 const WideString& csValue)
override;
103 const CPDF_Dictionary* pAnnotDict)
const;
105 UnownedPtr<CPDFSDK_FormFillEnvironment>
const m_pFormFillEnv;
106 std::unique_ptr<CPDF_InteractiveForm>
const m_pInteractiveForm;
107 std::map<UnownedPtr<
const CPDF_FormControl>,
108 UnownedPtr<CPDFSDK_Widget>,
112 bool m_bXfaCalculate =
true;
113 bool m_bXfaValidationsEnabled =
true;
115 bool m_bCalculate =
true;
116 bool m_bBusy =
false;
117 uint8_t m_HighlightAlpha = 0;
118 FX_COLORREF m_HighlightColor[kFormFieldTypeCount];
119 bool m_NeedsHighlight[kFormFieldTypeCount];
CFX_FloatRect GetCenterSquare() const
constexpr CFX_FloatRect(float l, float b, float r, float t)
void ScaleFromCenterPoint(float fScale)
CFX_FloatRect & operator=(const CFX_FloatRect &that)=default
CFX_FloatRect GetDeflated(float x, float y) const
CFX_Matrix(float a1, float b1, float c1, float d1, float e1, float f1)
void SetAsTextField(absl::optional< WideString > sValue)
CPDFSDK_AppStream(CPDFSDK_Widget *widget, CPDF_Dictionary *dict)
void SetAsComboBox(absl::optional< WideString > sValue)
bool IsModifiedAPStream(const CPDF_Stream *stream) const
RetainPtr< CPDF_Stream > CreateModifiedAPStream()
bool GetFittingBounds() const
void SetAt(int32_t nWordIndex)
bool GetWord(CPVT_Word &word) const
bool GetLine(CPVT_Line &line) const
const CPVT_WordPlace & GetAt() const
ByteString GetPDFWordString(int32_t nFontIndex, uint16_t Word, uint16_t SubWord)
IPVT_FontMap * GetFontMap()
CreateParams(CFX_Timer::HandlerIface *timer_handler, IPWL_FillerNotify *filler_notify, ProviderIface *provider)
virtual ByteString GetPDFFontAlias(int32_t nFontIndex)=0
ByteString & operator+=(const ByteString &str)
ByteString & operator=(const ByteString &that)
ByteString & operator=(ByteString &&that) noexcept
WideString & operator=(WideString &&that) noexcept
CharType operator[](const size_t index) const
WideString & operator=(const WideString &that)
#define FXSYS_IsFloatBigger(fa, fb)
#define FXSYS_IsFloatZero(f)
ByteString operator+(const ByteString &str1, const ByteString &str2)
CFX_Color operator/(float fColorDivide) const
CFX_Color operator-(float fColorSub) const
CFX_Color & operator=(const CFX_Color &that)=default
constexpr CFX_Color(Type type=CFX_Color::Type::kTransparent, float color1=0.0f, float color2=0.0f, float color3=0.0f, float color4=0.0f)
int32_t LineCmp(const CPVT_WordPlace &wp) const
CPWL_Dash(int32_t dash, int32_t gap, int32_t phase)