unioffice/common/axcontrol/axcontrol.go

237 lines
72 KiB
Go
Raw Normal View History

2022-01-15 21:17:38 +00:00
//
// Copyright 2020 FoxyUtils ehf. All rights reserved.
//
// This is a commercial product and requires a license to operate.
// A trial license can be obtained at https://unidoc.io
//
// DO NOT EDIT: generated by unitwist Go source code obfuscator.
//
// Use of this source code is governed by the UniDoc End User License Agreement
// terms that can be accessed at https://unidoc.io/eula/
2022-02-25 19:20:45 +00:00
package axcontrol ;import (_d "bytes";_bb "encoding/binary";_g "errors";_da "fmt";_df "github.com/unidoc/unioffice/common/tempstorage";_bf "github.com/unidoc/unioffice/internal/mscfb";_a "github.com/unidoc/unioffice/internal/mscfb/rw";_ga "github.com/unidoc/unioffice/schema/schemas.microsoft.com/office/activeX";_b "io";);
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// FmPictureSizeMode represents one of the three picture size modes according to MS-OFORMS document.
type FmPictureSizeMode byte ;func _bbgc (_ec *_a .Reader )(*CommandButtonControl ,error ){_cd :=&CommandButtonControl {};if _gcc :=_cd .readPropMask (_ec );_gcc !=nil {return nil ,_gcc ;};if _edee :=_cd .readDataBlock (_ec );_edee !=nil {return nil ,_edee ;};if _abd :=_cd .readExtraDataBlock (_ec );_abd !=nil {return nil ,_abd ;};if _efab :=_cd .readStreamDataPM (_ec ,_cd ._bcca ._gba ,_cd ._bcca ._bgf );_efab !=nil {return nil ,_efab ;};if _febc :=_cd .readTheRest (_ec );_febc !=nil {return nil ,_febc ;};return _cd ,nil ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// TextBoxDataControl is a representation of a text box ActiveX form.
type TextBoxDataControl struct{*morphDataControlStringValue };
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetValue sets a value for a control which value can be represented as boolean (on/off).
func (_dda *morphDataControlBoolValue )SetValue (value bool ){_dda .setValueBool (value )};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetHeight returns height of the ScrollBar in HIMETRIC (0.01mm)
func (_ccd *ScrollBarControl )GetHeight ()uint32 {return _ccd ._abag ._gafc };func (_ebfa *ImageControl )export (_bdd *_a .Writer )error {if _cbeg :=_ebfa .writePropMask (_bdd );_cbeg !=nil {return _cbeg ;};if _eggg :=_ebfa .writeDataBlock (_bdd );_eggg !=nil {return _eggg ;};if _gdgg :=_ebfa .writeExtraDataBlock (_bdd );_gdgg !=nil {return _gdgg ;};_ebfa ._ggc =uint16 (_bdd .Len ()-4);if _fced :=_ebfa .writeStreamDataPM (_bdd );_fced !=nil {return _fced ;};return _ebfa .writeTheRest (_bdd );};type scrollBarDataBlock struct{_gdd uint32 ;_dcf uint32 ;_fafa uint32 ;_gbge uint8 ;_fgcc int32 ;_aedd int32 ;_ffeb int32 ;_ageg int32 ;_efgce int32 ;_aaeg int32 ;_cbba int32 ;_fbcg uint32 ;_ddea uint32 ;_ecab uint32 ;_faec uint16 ;};func (_ccbf *ScrollBarControl )readExtraDataBlock (_cdcb *_a .Reader )error {_ccbf ._abag =&scrollBarExtraDataBlock {};if _ccbf ._gdfgc ._ebdd {var _afdag uint64 ;if _cef :=_cdcb .ReadPairProperty (&_afdag );_cef !=nil {return _cef ;};_ccbf ._abag ._gafc =uint32 (_afdag );_ccbf ._abag ._agga =uint32 (_afdag >>32);};return nil ;};type morphDataControlStringValue struct{*morphDataControl };func (_fgb *morphDataControl )writeColumnInfoDataBlock (_cdbf *_a .Writer )error {return nil };
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetPosition sets a button position value.
func (_bdgbf *ScrollBarControl )SetPosition (position int32 ){_bdgbf ._gdfgc ._caed =true ;_bdgbf ._dccg ._ffeb =position ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetHeight returns height of the morphDataControl in HIMETRIC (0.01mm)
func (_bfdb *morphDataControl )GetHeight ()uint32 {return _bfdb ._gabe ._cee };
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetForeColor sets a button text color value from a system palette for a scrollBar control.
func (_egd *ScrollBarControl )SetForeColor (foreColor uint32 ){_egd ._gdfgc ._daaad =true ;_egd ._dccg ._gdd =foreColor ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// CommandButtonControl is a representation of a commandButton ActiveX form.
type CommandButtonControl struct{controlBase ;_bcca *commandButtonPropMask ;_fbd *commandButtonDataBlock ;_ca *commandButtonExtraDataBlock ;_gef *streamData ;};func (_bdda *ScrollBarControl )readPropMask (_gbcb *_a .Reader )error {var _eba uint32 ;if _fdg :=_bb .Read (_gbcb ,_bb .LittleEndian ,&_eba );_fdg !=nil {return _fdg ;};_bdda ._gdfgc =&scrollBarPropMask {};_bdda ._gdfgc ._daaad ,_eba =_a .PopRightUI32 (_eba );_bdda ._gdfgc ._geba ,_eba =_a .PopRightUI32 (_eba );_bdda ._gdfgc ._fbgb ,_eba =_a .PopRightUI32 (_eba );_bdda ._gdfgc ._ebdd ,_eba =_a .PopRightUI32 (_eba );_bdda ._gdfgc ._ccdf ,_eba =_a .PopRightUI32 (_eba );_bdda ._gdfgc ._eacb ,_eba =_a .PopRightUI32 (_eba );_bdda ._gdfgc ._fffc ,_eba =_a .PopRightUI32 (_eba );_bdda ._gdfgc ._caed ,_eba =_a .PopRightUI32 (_eba );_eba >>=1;_bdda ._gdfgc ._acdf ,_eba =_a .PopRightUI32 (_eba );_bdda ._gdfgc ._ebbf ,_eba =_a .PopRightUI32 (_eba );_bdda ._gdfgc ._fae ,_eba =_a .PopRightUI32 (_eba );_bdda ._gdfgc ._fcaf ,_eba =_a .PopRightUI32 (_eba );_bdda ._gdfgc ._dgfa ,_eba =_a .PopRightUI32 (_eba );_bdda ._gdfgc ._dfad ,_eba =_a .PopRightUI32 (_eba );_bdda ._gdfgc ._agg ,_eba =_a .PopRightUI32 (_eba );_bdda ._gdfgc ._gfef ,_eba =_a .PopRightUI32 (_eba );return nil ;};func (_edfd *ScrollBarControl )readDataBlock (_gcbf *_a .Reader )error {_edfd ._dccg =&scrollBarDataBlock {};if _edfd ._gdfgc ._daaad {if _gecb :=_gcbf .ReadProperty (&_edfd ._dccg ._gdd );_gecb !=nil {return _gecb ;};};if _edfd ._gdfgc ._geba {if _baee :=_gcbf .ReadProperty (&_edfd ._dccg ._dcf );_baee !=nil {return _baee ;};};if _edfd ._gdfgc ._fbgb {if _cgdg :=_gcbf .ReadProperty (&_edfd ._dccg ._fafa );_cgdg !=nil {return _cgdg ;};};if _edfd ._gdfgc ._ccdf {if _deffc :=_gcbf .ReadProperty (&_edfd ._dccg ._gbge );_deffc !=nil {return _deffc ;};};if _edfd ._gdfgc ._eacb {if _bcfb :=_gcbf .ReadProperty (&_edfd ._dccg ._fgcc );_bcfb !=nil {return _bcfb ;};};if _edfd ._gdfgc ._fffc {if _ggdc :=_gcbf .ReadProperty (&_edfd ._dccg ._aedd );_ggdc !=nil {return _ggdc ;};};if _edfd ._gdfgc ._caed {if _abgd :=_gcbf .ReadProperty (&_edfd ._dccg ._ffeb );_abgd !=nil {return _abgd ;};};if _edfd ._gdfgc ._acdf {if _agfc :=_gcbf .ReadProperty (&_edfd ._dccg ._ageg );_agfc !=nil {return _agfc ;};};if _edfd ._gdfgc ._ebbf {if _fddg :=_gcbf .ReadProperty (&_edfd ._dccg ._efgce );_fddg !=nil {return _fddg ;};};if _edfd ._gdfgc ._fae {if _dacb :=_gcbf .ReadProperty (&_edfd ._dccg ._aaeg );_dacb !=nil {return _dacb ;};};if _edfd ._gdfgc ._fcaf {if _ceda :=_gcbf .ReadProperty (&_edfd ._dccg ._cbba );_ceda !=nil {return _ceda ;};};if _edfd ._gdfgc ._dgfa {if _agd :=_gcbf .ReadProperty (&_edfd ._dccg ._fbcg );_agd !=nil {return _agd ;};};if _edfd ._gdfgc ._dfad {if _dcebg :=_gcbf .ReadProperty (&_edfd ._dccg ._ddea );_dcebg !=nil {return _dcebg ;};};if _edfd ._gdfgc ._agg {if _fbdg :=_gcbf .ReadProperty (&_edfd ._dccg ._ecab );_fbdg !=nil {return _fbdg ;};};if _edfd ._gdfgc ._gfef {if _eee :=_gcbf .ReadProperty (&_edfd ._dccg ._faec );_eee !=nil {return _eee ;};};return nil ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetPosition gets a button position value.
func (_eefc *SpinButtonControl )GetPosition ()int32 {return _eefc ._gff ._abdb };func (_gfa *guidAndPicture )getStdPictureBytes ()[]byte {if _gfa !=nil &&_gfa ._bfb !=nil &&_gfa ._bfb ._dff !=nil {return _gfa ._bfb ._dff .Bytes ();};return nil ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetMin sets a button min value.
func (_fafe *SpinButtonControl )SetMin (min int32 ){_fafe ._eeba ._edeeg =true ;_fafe ._gff ._acfc =min };
2022-01-15 21:17:38 +00:00
// SetHeight sets height of the Label in HIMETRIC (0.01mm)
2022-02-25 19:20:45 +00:00
func (_aae *LabelControl )SetHeight (height uint32 ){_aae ._aac ._gca =true ;_aae ._bfba ._edc =height };
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetWidth returns width of the morphDataControl in HIMETRIC (0.01mm)
func (_aaa *morphDataControl )GetWidth ()uint32 {return _aaa ._gabe ._dccc };type streamData struct{_cbec *guidAndPicture ;_fcac *guidAndPicture ;};func (_dfdc *controlBase )getMouseIconBytes ()[]byte {return _dfdc ._fcb ._cbec .getStdPictureBytes ()};func _abe (_gabd uint32 ,_fa bool )uint32 {if _gabd ==0{return 0;};if _fa {_gabd |=1<<31;};return _gabd ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetPosition gets a button position value.
func (_gda *ScrollBarControl )GetPosition ()int32 {return _gda ._dccg ._ffeb };
2022-01-15 21:17:38 +00:00
// SetBackColor sets a button text color value from a system palette for a label control.
2022-02-25 19:20:45 +00:00
func (_efed *LabelControl )SetBackColor (backColor uint32 ){_efed ._aac ._dfa =true ;_efed ._eea ._baf =backColor ;};type labelPropMask struct{_gac bool ;_dfa bool ;_abec bool ;_agf bool ;_ddee bool ;_gca bool ;_cebg bool ;_fgag bool ;_fede bool ;_feec bool ;_edd bool ;_dea bool ;_fbb bool ;};type morphDataDataBlock struct{_age uint32 ;_fdcfa uint32 ;_dbeb uint32 ;_dcbg uint32 ;_ccfg byte ;_daga byte ;_ace byte ;_ecfe byte ;_bbdd rune ;_aaaf uint32 ;_eab uint16 ;_gce int16 ;_aea int16 ;_eag uint16 ;_fdce uint16 ;_dadd uint8 ;_gcg uint8 ;_agc uint8 ;_fdeg uint8 ;_fag uint8 ;_fdcfe uint32 ;_afa bool ;_dgea uint32 ;_ffa bool ;_dgeg uint32 ;_gfbdf uint32 ;_gdfff uint32 ;_adc uint16 ;_badc uint16 ;_gad rune ;_acae uint32 ;_eefd bool ;};func (_bgd *controlBase )writeStreamDataMP (_bddae *_a .Writer )error {if _bgd ._fcb !=nil {if _bgd ._fcb ._cbec !=nil {if _fega :=_bgd ._fcb ._cbec .export (_bddae );_fega !=nil {return _fega ;};};if _bgd ._fcb ._fcac !=nil {if _bcgaf :=_bgd ._fcb ._fcac .export (_bddae );_bcgaf !=nil {return _bcgaf ;};};};return nil ;};const _ecfa =2;
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetMax sets a button max value.
func (_cdga *ScrollBarControl )SetMax (max int32 ){_cdga ._gdfgc ._fffc =true ;_cdga ._dccg ._aedd =max };const _gebc =4;
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetPosition sets a button position value.
func (_efge *SpinButtonControl )SetPosition (position int32 ){_efge ._eeba ._ffeg =true ;_efge ._gff ._abdb =position ;};type imagePropMask struct{_eaf bool ;_ded bool ;_cdea bool ;_dbba bool ;_bged bool ;_bbgg bool ;_fga bool ;_bcf bool ;_bccb bool ;_bad bool ;_fff bool ;_eaed bool ;_ceb bool ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// ImportFromFile makes a Control from a file in a storage.
func ImportFromFile (storagePath string )(*Control ,error ){_dg ,_bc :=_df .Open (storagePath );if _bc !=nil {return nil ,_bc ;};defer _dg .Close ();_fg ,_bc :=_bf .New (_dg );if _bc !=nil {return nil ,_bc ;};_fd ,_bc :=_gg (_fg );if _bc !=nil {return nil ,_bc ;};_c ,_bc :=_fg .GetEntry ("\u0063\u006f\u006e\u0074\u0065\u006e\u0074\u0073");if _bc !=nil {return nil ,_bc ;};_eg :=make ([]byte ,_c .Size );_ ,_bc =_c .Read (_eg );if _bc !=nil {return nil ,_bc ;};_cb :=&Control {_bbc :storagePath };_ge ,_bc :=_a .NewReader (_eg );if _bc !=nil {return nil ,_bc ;};if _dd :=_bb .Read (_ge ,_bb .LittleEndian ,&_cb ._ab );_dd !=nil {return nil ,_dd ;};if _cf :=_bb .Read (_ge ,_bb .LittleEndian ,&_cb ._dfc );_cf !=nil {return nil ,_cf ;};if _fc :=_bb .Read (_ge ,_bb .LittleEndian ,&_cb ._e );_fc !=nil {return nil ,_fc ;};switch _fd {case "\u0043\u0068\u0065\u0063\u006b\u0042\u006f\u0078":_ce ,_aba :=_gcbe (_ge );if _aba !=nil {return nil ,_aba ;};_ce ._acd =true ;_cb .Choice =&ControlChoice {CheckBox :&CheckBoxDataControl {&morphDataControlBoolValue {_ce }}};case "\u0054e\u0078\u0074\u0042\u006f\u0078":_ef ,_dde :=_gcbe (_ge );if _dde !=nil {return nil ,_dde ;};_ef ._acd =true ;_cb .Choice =&ControlChoice {TextBox :&TextBoxDataControl {&morphDataControlStringValue {_ef }}};case "\u0043\u006f\u006d\u0062\u006f\u0042\u006f\u0078":_ad ,_bbf :=_gcbe (_ge );if _bbf !=nil {return nil ,_bbf ;};_ad ._acd =true ;_cb .Choice =&ControlChoice {ComboBox :&ComboBoxDataControl {&morphDataControlStringValue {_ad }}};case "\u004ci\u0073\u0074\u0042\u006f\u0078":_ba ,_ae :=_gcbe (_ge );if _ae !=nil {return nil ,_ae ;};_ba ._acd =true ;_cb .Choice =&ControlChoice {ListBox :&ListBoxDataControl {&morphDataControlStringValue {_ba }}};case "\u004f\u0070\u0074i\u006f\u006e\u0042\u0075\u0074\u0074\u006f\u006e":_bbg ,_af :=_gcbe (_ge );if _af !=nil {return nil ,_af ;};_bbg ._acd =true ;_cb .Choice =&ControlChoice {OptionButton :&OptionButtonDataControl {&morphDataControlBoolValue {_bbg }}};case "\u0054\u006f\u0067g\u006c\u0065\u0042\u0075\u0074\u0074\u006f\u006e":_gd ,_efd :=_gcbe (_ge );if _efd !=nil {return nil ,_efd ;};_gd ._acd =true ;_cb .Choice =&ControlChoice {ToggleButton :&ToggleButtonDataControl {&morphDataControlBoolValue {_gd }}};case "\u004c\u0061\u0062e\u006c":_bfc ,_fb :=_daed (_ge );if _fb !=nil {return nil ,_fb ;};_cb .Choice =&ControlChoice {Label :_bfc };case "\u0053\u0070\u0069\u006e\u0042\u0075\u0074\u0074\u006f\u006e":_dc ,_be :=_gggc (_ge );if _be !=nil {return nil ,_be ;};_cb .Choice =&ControlChoice {SpinButton :_dc };case "\u0043\u006f\u006d\u006d\u0061\u006e\u0064\u0042\u0075\u0074\u0074\u006f\u006e":_bcc ,_db :=_bbgc (_ge );if _db !=nil {return nil ,_db ;};_cb .Choice =&ControlChoice {CommandButton :_bcc };case "\u0053c\u0072\u006f\u006c\u006c\u0042\u0061r":_bba ,_gc :=_cabg (_ge );if _gc !=nil {return nil ,_gc ;};_cb .Choice =&ControlChoice {ScrollBar :_bba };default:_efb :=&controlBase {};if _ede :=_efb .readTheRest (_ge );_ede !=nil {return nil ,_ede ;};_cb .Choice =&ControlChoice {_ed :_efb };};return _cb ,nil ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetWidth sets width of the Label in HIMETRIC (0.01mm)
func (_bddd *LabelControl )SetWidth (width uint32 ){_bddd ._aac ._gca =true ;_bddd ._bfba ._eaeg =width };func (_fab *SpinButtonControl )writeExtraDataBlock (_caeb *_a .Writer )error {if _fab ._eeba ._ddeef {_gdcg :=uint64 (_fab ._feda ._becd )<<32|uint64 (_fab ._feda ._ebef );if _gafe :=_caeb .WritePropertyNoAlign (_gdcg );_gafe !=nil {return _gafe ;};};return nil ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetCaption sets a caption string for a morph control.
func (_bfgg *morphDataControl )SetCaption (caption string ){if _bfgg ._acd {_bfgg ._ebb ._feef =true ;_bfgg ._bgag ._dgea =uint32 (len (caption ));_bfgg ._gabe ._ceef =caption ;};};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetHeight returns height of the CommandButton in HIMETRIC (0.01mm)
func (_bef *CommandButtonControl )GetHeight ()uint32 {return _bef ._ca ._aeb };func (_ecgf *controlBase )readTheRest (_afd *_a .Reader )error {_gbag :=_d .NewBuffer ([]byte {});_ ,_abg :=_b .Copy (_gbag ,_afd );if _abg !=nil {return _abg ;};_ecgf ._dada =_gbag .Bytes ();return nil ;};func (_cfbd *ScrollBarControl )export (_cfafa *_a .Writer )error {if _gbga :=_cfbd .writePropMask (_cfafa );_gbga !=nil {return _gbga ;};if _babd :=_cfbd .writeDataBlock (_cfafa );_babd !=nil {return _babd ;};if _cdgd :=_cfbd .writeExtraDataBlock (_cfafa );_cdgd !=nil {return _cdgd ;};_cfbd ._ggc =uint16 (_cfafa .Len ()-4);if _gfdd :=_cfbd .writeStreamDataM (_cfafa );_gfdd !=nil {return _gfdd ;};return _cfbd .writeTheRest (_cfafa );};func (_efac *controlBase )readStreamDataMP (_daaag *_a .Reader ,_cggf ,_ebgf bool )error {_efac ._fcb =&streamData {};if _cggf {_efac ._fcb ._cbec =&guidAndPicture {};if _dedbg :=_efac ._fcb ._cbec .importFromReader (_daaag );_dedbg !=nil {return _dedbg ;};};if _ebgf {_efac ._fcb ._fcac =&guidAndPicture {};if _aaad :=_efac ._fcb ._fcac .importFromReader (_daaag );_aaad !=nil {return _aaad ;};};return nil ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetWidth returns width of the ScrollBar in HIMETRIC (0.01mm)
func (_dcee *ScrollBarControl )GetWidth ()uint32 {return _dcee ._abag ._agga };type spinButtonDataBlock struct{_ccede uint32 ;_bfbb uint32 ;_dgd uint32 ;_acfc int32 ;_gacc int32 ;_abdb int32 ;_bcad int32 ;_afed int32 ;_eed int32 ;_ggfdf uint32 ;_gccf uint32 ;_aace uint16 ;_dedbe uint8 ;};func (_gdb *morphDataControl )readExtraDataBlock (_deg *_a .Reader )error {_gdb ._gabe =&morphDataExtraDataBlock {};if _gdb ._ebb ._baba {var _ffef uint64 ;if _cae :=_deg .ReadPairProperty (&_ffef );_cae !=nil {return _cae ;};_gdb ._gabe ._cee =uint32 (_ffef );_gdb ._gabe ._dccc =uint32 (_ffef >>32);};if _gdb ._bgag ._fdcfe > 0{_fdab ,_cbcb :=_deg .ReadStringProperty (_gdb ._bgag ._fdcfe );if _cbcb !=nil {return _cbcb ;};_gdb ._gabe ._abbd =_fdab ;};if _gdb ._bgag ._dgea > 0{_cecb ,_eabc :=_deg .ReadStringProperty (_gdb ._bgag ._dgea );if _eabc !=nil {return _eabc ;};_gdb ._gabe ._ceef =_cecb ;};if _gdb ._bgag ._acae > 0{_eefb ,_eda :=_deg .ReadStringProperty (_gdb ._bgag ._acae );if _eda !=nil {return _eda ;};_gdb ._gabe ._cbdc =_eefb ;};return nil ;};func (_dbd *morphDataControl )setValueString (_ebbe string ){_dbd ._ebb ._bgfb =true ;_dbd ._bgag ._fdcfe =uint32 (len (_ebbe ));_dbd ._gabe ._abbd =_ebbe ;};func (_dgf *morphDataControl )readDataBlock (_cdgf *_a .Reader )error {_dgf ._bgag =&morphDataDataBlock {};if _dgf ._ebb ._aeeb {if _afga :=_cdgf .ReadProperty (&_dgf ._bgag ._age );_afga !=nil {return _afga ;};};if _dgf ._ebb ._cfce {if _geef :=_cdgf .ReadProperty (&_dgf ._bgag ._fdcfa );_geef !=nil {return _geef ;};};if _dgf ._ebb ._daa {if _bedc :=_cdgf .ReadProperty (&_dgf ._bgag ._dbeb );_bedc !=nil {return _bedc ;};};if _dgf ._ebb ._dbda {if _abdaa :=_cdgf .ReadProperty (&_dgf ._bgag ._dcbg );_abdaa !=nil {return _abdaa ;};};if _dgf ._ebb ._gfab {if _ccfc :=_cdgf .ReadProperty (&_dgf ._bgag ._ccfg );_ccfc !=nil {return _ccfc ;};};if _dgf ._ebb ._fbbb {if _fbcb :=_cdgf .ReadProperty (&_dgf ._bgag ._daga );_fbcb !=nil {return _fbcb ;};};if _dgf ._ebb ._dcbc {if _cbf :=_cdgf .ReadProperty (&_dgf ._bgag ._ace );_cbf !=nil {return _cbf ;};};if _dgf ._ebb ._afbe {if _egb :=_cdgf .ReadProperty (&_dgf ._bgag ._ecfe );_egb !=nil {return _egb ;};};if _dgf ._ebb ._agab {if _fafc :=_cdgf .ReadProperty (&_dgf ._bgag ._bbdd );_fafc !=nil {return _fafc ;};};if _dgf ._ebb ._ggfd {if _bgc :=_cdgf .ReadProperty (&_dgf ._bgag ._aaaf );_bgc !=nil {return _bgc ;};};if _dgf ._ebb ._cda {if _eaeae :=_cdgf .ReadProperty (&_dgf ._bgag ._eab );_eaeae !=nil {return _eaeae ;};};if _dgf ._ebb ._bcae {if _bbb :=_cdgf .ReadProperty (&_dgf ._bgag ._gce );_bbb !=nil {return _bbb ;};};if _dgf ._ebb ._cea {if _fbdd :=_cdgf .ReadProperty (&_dgf ._bgag ._aea );_fbdd !=nil {return _fbdd ;};};if _dgf ._ebb ._dagb {if _ffb :=_cdgf .ReadProperty (&_dgf ._bgag ._eag );_ffb !=nil {return _ffb ;};};if _dgf ._ebb ._gaab {if _daaa :=_cdgf .ReadProperty (&_dgf ._bgag ._fdce );_daaa !=nil {return _daaa ;};};if _dgf ._ebb ._efedc {if _adcc :=_cdgf .ReadProperty (&_dgf ._bgag ._dadd );_adcc !=nil {return _adcc ;};};if _dgf ._ebb ._cgga {if _feg :=_cdgf .ReadProperty (&_dgf ._bgag ._gcg );_feg !=nil {return _feg ;};};if _dgf ._ebb ._gbaa {if _fdd :=_cdgf .ReadProperty (&_dgf ._bgag ._agc );_fdd !=nil {return _fdd ;};};if _dgf ._ebb ._cga {if _gfag :=_cdgf .ReadProperty (&_dgf ._bgag ._fdeg );_gfag !=nil {return _gfag ;};};if _dgf ._ebb ._ece {if _cbc :=_cdgf .ReadProperty (&_dgf ._bgag ._fag );_cbc !=nil {return _cbc ;};};if _dgf ._ebb ._bgfb {var _cbgf uint32 ;if _fbbc :=_cdgf .ReadProperty (&_cbgf );_fbbc !=nil {return _fbbc ;};_dgf ._bgag ._afa ,_dgf ._bgag ._fdcfe =_dba (_cbgf );};if _dgf ._ebb ._feef {var _fgcg uint32 ;if _aef :=_cdgf .ReadProperty (&_fgcg );_aef !=nil {return _aef ;};_dgf ._bgag ._ffa ,_dgf ._bgag ._dgea =_dba (_fgcg );};if _dgf ._ebb ._aaf {if _abcc :=_cdgf .ReadProperty (&_dgf ._bgag ._dgeg );_abcc !=nil {return _abcc ;};};if _dgf ._ebb ._fcc {if _bffa :=_cdgf .ReadProperty (&_dgf ._bgag ._gfbdf );_bffa !=nil {return _bffa ;};};if _dgf ._ebb ._fgf {if _dcde :=_cdgf .ReadProperty (&_dgf ._bgag ._gdfff );_dcde !=nil {return _dcde ;};};if _dgf ._ebb ._gfd
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// Control represents an ActiveX control wrapper.
type Control struct{TargetAttr string ;Ocx *_ga .Ocx ;Choice *ControlChoice ;_bbc string ;_ab uint8 ;_dfc uint8 ;_e uint16 ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetWidth sets width of the SpinButton in HIMETRIC (0.01mm)
func (_eecg *SpinButtonControl )SetWidth (width uint32 ){_eecg ._eeba ._ddeef =true ;_eecg ._feda ._becd =width ;};func (_ccea *morphDataControl )readPropMask (_bcga *_a .Reader )error {var _aaed uint64 ;if _dac :=_bb .Read (_bcga ,_bb .LittleEndian ,&_aaed );_dac !=nil {return _dac ;};_ccea ._ebb =&morphDataPropMask {};_ccea ._ebb ._aeeb ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._cfce ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._daa ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._dbda ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._gfab ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._fbbb ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._dcbc ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._afbe ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._baba ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._agab ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._ggfd ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._cda ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._bcae ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._cea ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._dagb ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._gaab ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._efedc ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._cgga ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._gbaa ,_aaed =_a .PopRightUI64 (_aaed );_aaed >>=1;_ccea ._ebb ._cga ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._ece ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._bgfb ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._feef ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._aaf ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._fcc ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._fgf ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._gfd ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._bebc ,_aaed =_a .PopRightUI64 (_aaed );_ccea ._ebb ._dagd ,_aaed =_a .PopRightUI64 (_aaed );_aaed >>=1;_aaed >>=1;_ccea ._ebb ._cggd ,_aaed =_a .PopRightUI64 (_aaed );return nil ;};const _cgdb =3;const _fdcf =1;
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// ImageControl is a representation of an image ActiveX form.
type ImageControl struct{controlBase ;_afdg *imagePropMask ;_fdad *imageDataBlock ;_ecf *imageExtraDataBlock ;_bfe *streamData ;};type morphDataControl struct{controlBase ;_ebb *morphDataPropMask ;_bgag *morphDataDataBlock ;_gabe *morphDataExtraDataBlock ;_fbad *streamData ;_gfg *morphDataColumnInfo ;_fcba *morphDataColumnInfoPropMask ;_eefe *morphDataColumnInfoDataBlock ;};func (_dab *CommandButtonControl )writeDataBlock (_aee *_a .Writer )error {if _dab ._bcca ._dbb {if _bee :=_aee .WriteProperty (_dab ._fbd ._gfc );_bee !=nil {return _bee ;};};if _dab ._bcca ._dge {if _def :=_aee .WriteProperty (_dab ._fbd ._cdf );_def !=nil {return _def ;};};if _dab ._bcca ._dga {if _fda :=_aee .WriteProperty (_dab ._fbd ._dbed );_fda !=nil {return _fda ;};};if _dab ._bcca ._edg {_gde :=_abe (_dab ._fbd ._ccf ,_dab ._fbd ._fbgd );if _fdaf :=_aee .WriteProperty (_gde );_fdaf !=nil {return _fdaf ;};};if _dab ._bcca ._cdd {if _cac :=_aee .WriteProperty (_dab ._fbd ._egg );_cac !=nil {return _cac ;};};if _dab ._bcca ._fdf {if _gggg :=_aee .WriteProperty (_dab ._fbd ._ege );_gggg !=nil {return _gggg ;};};if _dab ._bcca ._gba {if _aad :=_aee .WriteProperty (_dab ._fbd ._bge );_aad !=nil {return _aad ;};};if _dab ._bcca ._gag {if _cce :=_aee .WriteProperty (_dab ._fbd ._afb );_cce !=nil {return _cce ;};};if _dab ._bcca ._bgf {if _cdfe :=_aee .WriteProperty (_dab ._fbd ._ddd );_cdfe !=nil {return _cdfe ;};};return _aee .AlignLength (4);};type morphDataExtraDataBlock struct{_dccc uint32 ;_cee uint32 ;_abbd string ;_ceef string ;_cbdc string ;};func (_gcfc *SpinButtonControl )export (_eeg *_a .Writer )error {if _aeda :=_gcfc .writePropMask (_eeg );_aeda !=nil {return _aeda ;};if _adgf :=_gcfc .writeDataBlock (_eeg );_adgf !=nil {return _adgf ;};if _eagg :=_gcfc .writeExtraDataBlock (_eeg );_eagg !=nil {return _eagg ;};_gcfc ._ggc =uint16 (_eeg .Len ()-4);if _aefg :=_gcfc .writeStreamDataM (_eeg );_aefg !=nil {return _aefg ;};return _gcfc .writeTheRest (_eeg );};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetBackColor sets a button text color value from a system palette for a scrollBar control.
func (_acbf *ScrollBarControl )SetBackColor (backColor uint32 ){_acbf ._gdfgc ._geba =true ;_acbf ._dccg ._dcf =backColor ;};func (_bgba *CommandButtonControl )readExtraDataBlock (_ac *_a .Reader )error {_bgba ._ca =&commandButtonExtraDataBlock {};if _bgba ._fbd ._ccf > 0{_ee ,_gga :=_ac .ReadStringProperty (_bgba ._fbd ._ccf );if _gga !=nil {return _gga ;};_bgba ._ca ._ecg =_ee ;};if _bgba ._bcca ._ebg {var _ggd uint64 ;if _ebd :=_ac .ReadPairProperty (&_ggd );_ebd !=nil {return _ebd ;};_bgba ._ca ._aeb =uint32 (_ggd );_bgba ._ca ._ggf =uint32 (_ggd >>32);};return nil ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetWidth returns width of the SpinButton in HIMETRIC (0.01mm)
func (_gebcc *SpinButtonControl )GetWidth ()uint32 {return _gebcc ._feda ._becd };
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// ExportToByteArray makes a byte array from a control as it is stored in .bin files.
func (_gb *Control )ExportToByteArray ()([]byte ,error ){_bd ,_gab :=_df .Open (_gb ._bbc );if _gab !=nil {return nil ,_gab ;};defer _bd .Close ();_cg ,_gab :=_bf .New (_bd );if _gab !=nil {return nil ,_gab ;};_cfc :=_a .NewWriter ();if _bfd :=_bb .Write (_cfc ,_bb .LittleEndian ,&_gb ._ab );_bfd !=nil {return nil ,_bfd ;};if _bg :=_bb .Write (_cfc ,_bb .LittleEndian ,&_gb ._dfc );_bg !=nil {return nil ,_bg ;};if _eae :=_bb .Write (_cfc ,_bb .LittleEndian ,uint16 (0));_eae !=nil {return nil ,_eae ;};var _gdg error ;if _ag :=_gb .Choice ;_ag !=nil {if _ag .CheckBox !=nil {_gdg =_ag .CheckBox .export (_cfc );}else if _ag .TextBox !=nil {_gdg =_ag .TextBox .export (_cfc );}else if _ag .ComboBox !=nil {_gdg =_ag .ComboBox .export (_cfc );}else if _ag .ListBox !=nil {_gdg =_ag .ListBox .export (_cfc );}else if _ag .OptionButton !=nil {_gdg =_ag .OptionButton .export (_cfc );}else if _ag .ToggleButton !=nil {_gdg =_ag .ToggleButton .export (_cfc );}else if _ag .Label !=nil {_gdg =_ag .Label .export (_cfc );}else if _ag .SpinButton !=nil {_gdg =_ag .SpinButton .export (_cfc );}else if _ag .CommandButton !=nil {_gdg =_ag .CommandButton .export (_cfc );}else if _ag .ScrollBar !=nil {_gdg =_ag .ScrollBar .export (_cfc );}else {_gdg =_ag ._ed .writeTheRest (_cfc );};};if _gdg !=nil {return nil ,_gdg ;};if _efa :=_cfc .WriteByteAt (byte (_gb ._e ),2);_efa !=nil {return nil ,_efa ;};if _fe :=_cfc .WriteByteAt (byte (_gb ._e >>8),3);_fe !=nil {return nil ,_fe ;};_dbf ,_gab :=_cg .GetEntry ("\u0063\u006f\u006e\u0074\u0065\u006e\u0074\u0073");if _gab !=nil {return nil ,_gab ;};if _cc :=_dbf .SetEntryContent (_cfc .Bytes ());_cc !=nil {return nil ,_cc ;};return _cg .Export ();};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetMin sets a button min value.
func (_cdfd *ScrollBarControl )SetMin (min int32 ){_cdfd ._gdfgc ._eacb =true ;_cdfd ._dccg ._fgcc =min };
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetHeight sets height of the SpinButton in HIMETRIC (0.01mm)
func (_bbec *SpinButtonControl )SetHeight (height uint32 ){_bbec ._eeba ._ddeef =true ;_bbec ._feda ._ebef =height ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// ComboBoxDataControl is a representation of a combo box ActiveX form.
type ComboBoxDataControl struct{*morphDataControlStringValue };
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetForeColor sets a button text color value from a system palette for a spinButton control.
func (_deb *SpinButtonControl )SetForeColor (foreColor uint32 ){_deb ._eeba ._dbdg =true ;_deb ._gff ._ccede =foreColor ;};func (_dfcd *LabelControl )writeDataBlock (_gcf *_a .Writer )error {if _dfcd ._aac ._gac {if _fdag :=_gcf .WriteProperty (_dfcd ._eea ._dfe );_fdag !=nil {return _fdag ;};};if _dfcd ._aac ._dfa {if _fgab :=_gcf .WriteProperty (_dfcd ._eea ._baf );_fgab !=nil {return _fgab ;};};if _dfcd ._aac ._abec {if _befa :=_gcf .WriteProperty (_dfcd ._eea ._aaec );_befa !=nil {return _befa ;};};if _dfcd ._aac ._agf {_bbca :=_abe (_dfcd ._eea ._bcgg ,_dfcd ._eea ._bga );if _edf :=_gcf .WriteProperty (_bbca );_edf !=nil {return _edf ;};};if _dfcd ._aac ._ddee {if _bdaf :=_gcf .WriteProperty (_dfcd ._eea ._fceg );_bdaf !=nil {return _bdaf ;};};if _dfcd ._aac ._cebg {if _bdfa :=_gcf .WriteProperty (_dfcd ._eea ._fbgf );_bdfa !=nil {return _bdfa ;};};if _dfcd ._aac ._fgag {if _ccc :=_gcf .WriteProperty (_dfcd ._eea ._cge );_ccc !=nil {return _ccc ;};};if _dfcd ._aac ._fede {if _gee :=_gcf .WriteProperty (_dfcd ._eea ._bab );_gee !=nil {return _gee ;};};if _dfcd ._aac ._feec {if _aab :=_gcf .WriteProperty (_dfcd ._eea ._ccgc );_aab !=nil {return _aab ;};};if _dfcd ._aac ._edd {if _fcf :=_gcf .WriteProperty (_dfcd ._eea ._aedf );_fcf !=nil {return _fcf ;};};if _dfcd ._aac ._dea {if _fde :=_gcf .WriteProperty (_dfcd ._eea ._ffg );_fde !=nil {return _fde ;};};if _dfcd ._aac ._fbb {if _abda :=_gcf .WriteProperty (_dfcd ._eea ._bdfd );_abda !=nil {return _abda ;};};return _gcf .AlignLength (4);};
2022-02-05 13:05:36 +00:00
2022-02-25 19:20:45 +00:00
// GetMax gets a button max value.
func (_baec *SpinButtonControl )GetMax ()int32 {return _baec ._gff ._gacc };
2022-02-05 13:05:36 +00:00
2022-02-25 19:20:45 +00:00
// GetForeColor gets a button text color value for a system palette from a commandButton control.
func (_cbg *CommandButtonControl )GetForeColor ()uint32 {return _cbg ._fbd ._gfc };func (_faadc *ScrollBarControl )writeDataBlock (_gbgbg *_a .Writer )error {if _faadc ._gdfgc ._daaad {if _dfefd :=_gbgbg .WriteProperty (_faadc ._dccg ._gdd );_dfefd !=nil {return _dfefd ;};};if _faadc ._gdfgc ._geba {if _ffcc :=_gbgbg .WriteProperty (_faadc ._dccg ._dcf );_ffcc !=nil {return _ffcc ;};};if _faadc ._gdfgc ._fbgb {if _efea :=_gbgbg .WriteProperty (_faadc ._dccg ._fafa );_efea !=nil {return _efea ;};};if _faadc ._gdfgc ._ccdf {if _cbgfa :=_gbgbg .WriteProperty (_faadc ._dccg ._gbge );_cbgfa !=nil {return _cbgfa ;};};if _faadc ._gdfgc ._eacb {if _acea :=_gbgbg .WriteProperty (_faadc ._dccg ._fgcc );_acea !=nil {return _acea ;};};if _faadc ._gdfgc ._fffc {if _bdae :=_gbgbg .WriteProperty (_faadc ._dccg ._aedd );_bdae !=nil {return _bdae ;};};if _faadc ._gdfgc ._caed {if _fdbcd :=_gbgbg .WriteProperty (_faadc ._dccg ._ffeb );_fdbcd !=nil {return _fdbcd ;};};if _faadc ._gdfgc ._acdf {if _eacf :=_gbgbg .WriteProperty (_faadc ._dccg ._ageg );_eacf !=nil {return _eacf ;};};if _faadc ._gdfgc ._ebbf {if _cfcc :=_gbgbg .WriteProperty (_faadc ._dccg ._efgce );_cfcc !=nil {return _cfcc ;};};if _faadc ._gdfgc ._fae {if _dabf :=_gbgbg .WriteProperty (_faadc ._dccg ._aaeg );_dabf !=nil {return _dabf ;};};if _faadc ._gdfgc ._fcaf {if _affdf :=_gbgbg .WriteProperty (_faadc ._dccg ._cbba );_affdf !=nil {return _affdf ;};};if _faadc ._gdfgc ._dgfa {if _aeddg :=_gbgbg .WriteProperty (_faadc ._dccg ._fbcg );_aeddg !=nil {return _aeddg ;};};if _faadc ._gdfgc ._dfad {if _bgage :=_gbgbg .WriteProperty (_faadc ._dccg ._ddea );_bgage !=nil {return _bgage ;};};if _faadc ._gdfgc ._agg {if _cbbe :=_gbgbg .WriteProperty (_faadc ._dccg ._ecab );_cbbe !=nil {return _cbbe ;};};if _faadc ._gdfgc ._gfef {if _beg :=_gbgbg .WriteProperty (_faadc ._dccg ._faec );_beg !=nil {return _beg ;};};return _gbgbg .AlignLength (4);};
// SetCaption sets a caption string for a commandButton control.
func (_egf *CommandButtonControl )SetCaption (caption string ){_egf ._bcca ._edg =true ;_egf ._fbd ._ccf =uint32 (len (caption ));_egf ._ca ._ecg =caption ;};func (_feeg *morphDataControl )getValueBool ()bool {return _feeg ._ebb ._bgfb &&_feeg ._gabe ._abbd =="\u0031";};
2022-02-05 13:05:36 +00:00
// GetValue gets a value from a control which value can be represented as boolean (on/off).
2022-02-25 19:20:45 +00:00
func (_ecc *morphDataControlBoolValue )GetValue ()bool {return _ecc .getValueBool ()};func (_cfaf *morphDataControl )writePropMask (_dcag *_a .Writer )error {_dfab :=uint64 (0);_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._aeeb );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._cfce );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._daa );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._dbda );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._gfab );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._fbbb );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._dcbc );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._afbe );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._baba );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._agab );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._ggfd );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._cda );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._bcae );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._cea );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._dagb );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._gaab );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._efedc );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._cgga );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._gbaa );_dfab >>=1;_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._cga );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._ece );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._bgfb );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._feef );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._aaf );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._fcc );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._fgf );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._gfd );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._bebc );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._dagd );_dfab >>=1;_dfab =_a .PushLeftUI64 (_dfab ,true );_dfab =_a .PushLeftUI64 (_dfab ,_cfaf ._ebb ._cggd );_dfab >>=31;return _bb .Write (_dcag ,_bb .LittleEndian ,_dfab );};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetCaption sets a caption string for a label control.
func (_cdg *LabelControl )SetCaption (caption string ){_cdg ._aac ._agf =true ;_cdg ._eea ._bcgg =uint32 (len (caption ));_cdg ._bfba ._geg =caption ;};func (_dabe *morphDataControl )writeDataBlock (_bfde *_a .Writer )error {if _dabe ._ebb ._aeeb {if _dbaa :=_bfde .WriteProperty (_dabe ._bgag ._age );_dbaa !=nil {return _dbaa ;};};if _dabe ._ebb ._cfce {if _geaf :=_bfde .WriteProperty (_dabe ._bgag ._fdcfa );_geaf !=nil {return _geaf ;};};if _dabe ._ebb ._daa {if _dceb :=_bfde .WriteProperty (_dabe ._bgag ._dbeb );_dceb !=nil {return _dceb ;};};if _dabe ._ebb ._dbda {if _dedb :=_bfde .WriteProperty (_dabe ._bgag ._dcbg );_dedb !=nil {return _dedb ;};};if _dabe ._ebb ._gfab {if _feba :=_bfde .WriteProperty (_dabe ._bgag ._ccfg );_feba !=nil {return _feba ;};};if _dabe ._ebb ._fbbb {if _gae :=_bfde .WriteProperty (_dabe ._bgag ._daga );_gae !=nil {return _gae ;};};if _dabe ._ebb ._dcbc {if _acee :=_bfde .WriteProperty (_dabe ._bgag ._ace );_acee !=nil {return _acee ;};};if _dabe ._ebb ._afbe {if _dedg :=_bfde .WriteProperty (_dabe ._bgag ._ecfe );_dedg !=nil {return _dedg ;};};if _dabe ._ebb ._agab {if _fefc :=_bfde .WriteProperty (_dabe ._bgag ._bbdd );_fefc !=nil {return _fefc ;};};if _dabe ._ebb ._ggfd {if _eafd :=_bfde .WriteProperty (_dabe ._bgag ._aaaf );_eafd !=nil {return _eafd ;};};if _dabe ._ebb ._cda {if _dbbd :=_bfde .WriteProperty (_dabe ._bgag ._eab );_dbbd !=nil {return _dbbd ;};};if _dabe ._ebb ._bcae {if _becb :=_bfde .WriteProperty (_dabe ._bgag ._gce );_becb !=nil {return _becb ;};};if _dabe ._ebb ._cea {if _cgeb :=_bfde .WriteProperty (_dabe ._bgag ._aea );_cgeb !=nil {return _cgeb ;};};if _dabe ._ebb ._dagb {if _afea :=_bfde .WriteProperty (_dabe ._bgag ._eag );_afea !=nil {return _afea ;};};if _dabe ._ebb ._gaab {if _cff :=_bfde .WriteProperty (_dabe ._bgag ._fdce );_cff !=nil {return _cff ;};};if _dabe ._ebb ._efedc {if _babaf :=_bfde .WriteProperty (_dabe ._bgag ._dadd );_babaf !=nil {return _babaf ;};};if _dabe ._ebb ._cgga {if _cgf :=_bfde .WriteProperty (_dabe ._bgag ._gcg );_cgf !=nil {return _cgf ;};};if _dabe ._ebb ._gbaa {if _ecfee :=_bfde .WriteProperty (_dabe ._bgag ._agc );_ecfee !=nil {return _ecfee ;};};if _dabe ._ebb ._cga {if _deff :=_bfde .WriteProperty (_dabe ._bgag ._fdeg );_deff !=nil {return _deff ;};};if _dabe ._ebb ._ece {if _eca :=_bfde .WriteProperty (_dabe ._bgag ._fag );_eca !=nil {return _eca ;};};if _dabe ._ebb ._bgfb {_aded :=_abe (_dabe ._bgag ._fdcfe ,_dabe ._bgag ._afa );if _fcfc :=_bfde .WriteProperty (_aded );_fcfc !=nil {return _fcfc ;};};if _dabe ._ebb ._feef {_ggef :=_abe (_dabe ._bgag ._dgea ,_dabe ._bgag ._ffa );if _feed :=_bfde .WriteProperty (_ggef );_feed !=nil {return _feed ;};};if _dabe ._ebb ._aaf {if _gcab :=_bfde .WriteProperty (_dabe ._bgag ._dgeg );_gcab !=nil {return _gcab ;};};if _dabe ._ebb ._fcc {if _gccad :=_bfde .WriteProperty (_dabe ._bgag ._gfbdf );_gccad !=nil {return _gccad ;};};if _dabe ._ebb ._fgf {if _gfbg :=_bfde .WriteProperty (_dabe ._bgag ._gdfff );_gfbg !=nil {return _gfbg ;};};if _dabe ._ebb ._gfd {if _gebf :=_bfde .WriteProperty (_dabe ._bgag ._adc );_gebf !=nil {return _gebf ;};};if _dabe ._ebb ._bebc {if _bgbe :=_bfde .WriteProperty (_dabe ._bgag ._badc );_bgbe !=nil {return _bgbe ;};};if _dabe ._ebb ._dagd {if _bfcd :=_bfde .WriteProperty (_dabe ._bgag ._gad );_bfcd !=nil {return _bfcd ;};};if _dabe ._ebb ._cggd {_fddd :=_abe (_dabe ._bgag ._acae ,_dabe ._bgag ._eefd );if _fada :=_bfde .WriteProperty (_fddd );_fada !=nil {return _fada ;};};return _bfde .AlignLength (4);};func (_adgg *LabelControl )writeExtraDataBlock (_bag *_a .Writer )error {if _adgg ._eea ._bcgg > 0{if _acb :=_bag .WriteStringProperty (_adgg ._bfba ._geg );_acb !=nil {return _acb ;};};if _adgg ._aac ._gca {_fbbf :=uint64 (_adgg ._bfba ._eaeg )<<32|uint64 (_adgg ._bfba ._edc );if _ddfb :=_bag .WritePropertyNoAlign (_fbbf );_ddfb !=nil {return _ddfb ;};};return nil ;};func (_ggb *LabelControl )readDataBlock (_gfcf *_a .Reader )error {_ggb ._eea =&labelDataBlock {};if _ggb ._aac ._gac {if _dedd :=_gfcf .ReadProperty (&_ggb ._eea ._dfe );_dedd !=nil {return _dedd
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetMax gets a button max value.
func (_dadba *ScrollBarControl )GetMax ()int32 {return _dadba ._dccg ._aedd };
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetBackColor gets a button text color value for a system palette from a label control.
func (_abafg *LabelControl )GetBackColor ()uint32 {return _abafg ._eea ._baf };type commandButtonPropMask struct{_dbb bool ;_dge bool ;_dga bool ;_edg bool ;_cdd bool ;_ebg bool ;_fdf bool ;_gba bool ;_gag bool ;_fcd bool ;_bgf bool ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetBackColor gets a button text color value for a system palette from a spinButton control.
func (_gaba *SpinButtonControl )GetBackColor ()uint32 {return _gaba ._gff ._bfbb };
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetValue sets a value for a control which value can be represented as a string.
func (_bbaf *morphDataControlStringValue )SetValue (value string ){_bbaf .setValueString (value )};func (_egfg *guidAndPicture )importFromReader (_beeg *_a .Reader )error {_geb :=_d .NewBuffer ([]byte {});if _ ,_aca :=_b .CopyN (_geb ,_beeg ,int64 (_faa ));_aca !=nil {return _aca ;};_cec :=_geb .Bytes ();for _bgg :=0;_bgg < _faa ;_bgg ++{if _cec [_bgg ]!=_bcec [_bgg ]{return _da .Errorf ("\u0049\u006e\u0076\u0061\u006c\u0069d\u0020\u0047\u0055\u0049\u0044\u0020\u0076\u0061\u006c\u0075\u0065\u0020\u0025v\u0020\u0061\u0074\u0020\u0069\u006e\u0064e\u0078\u0020\u0025\u0076",_cec [_bgg ],_bgg );};};_egfg ._ebf =_cec ;_egfg ._bfb =&stdPicture {};if _gaf :=_beeg .ReadProperty (&_egfg ._bfb ._abaf );_gaf !=nil {return _gaf ;};if _egfg ._bfb ._abaf !=_bdb {return _da .Errorf ("\u0049\u006e\u0076\u0061li\u0064\u0020\u0070\u0072\u0065\u0061\u006d\u0062\u006c\u0065\u0020\u0025\u0076",_egfg ._bfb ._abaf );};if _dae :=_beeg .ReadProperty (&_egfg ._bfb ._ccb );_dae !=nil {return _dae ;};if _egfg ._bfb ._ccb !=0{_fef :=_d .NewBuffer ([]byte {});if _ ,_ade :=_b .Copy (_fef ,_beeg );_ade !=nil {return _ade ;};_egfg ._bfb ._dff =_fef ;};return nil ;};type commandButtonExtraDataBlock struct{_ggf uint32 ;_aeb uint32 ;_ecg string ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetBackColor sets a button text color value from a system palette for a spinButton control.
func (_fbbfa *SpinButtonControl )SetBackColor (backColor uint32 ){_fbbfa ._eeba ._bbgd =true ;_fbbfa ._gff ._bfbb =backColor ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetMin gets a button min value.
func (_ggdca *SpinButtonControl )GetMin ()int32 {return _ggdca ._gff ._acfc };func (_bde *controlBase )readStreamDataM (_acgg *_a .Reader ,_gcdf bool )error {_bde ._fcb =&streamData {};if _gcdf {_bde ._fcb ._cbec =&guidAndPicture {};if _aega :=_bde ._fcb ._cbec .importFromReader (_acgg );_aega !=nil {return _aega ;};};return nil ;};func (_gbae *CommandButtonControl )readDataBlock (_bcg *_a .Reader )error {_gbae ._fbd =&commandButtonDataBlock {};if _gbae ._bcca ._dbb {if _bgb :=_bcg .ReadProperty (&_gbae ._fbd ._gfc );_bgb !=nil {return _bgb ;};};if _gbae ._bcca ._dge {if _bbfb :=_bcg .ReadProperty (&_gbae ._fbd ._cdf );_bbfb !=nil {return _bbfb ;};};if _gbae ._bcca ._dga {if _dcd :=_bcg .ReadProperty (&_gbae ._fbd ._dbed );_dcd !=nil {return _dcd ;};};if _gbae ._bcca ._edg {var _aga uint32 ;if _gbb :=_bcg .ReadProperty (&_aga );_gbb !=nil {return _gbb ;};_gbae ._fbd ._fbgd ,_gbae ._fbd ._ccf =_dba (_aga );};if _gbae ._bcca ._cdd {if _aff :=_bcg .ReadProperty (&_gbae ._fbd ._egg );_aff !=nil {return _aff ;};};if _gbae ._bcca ._fdf {if _bce :=_bcg .ReadProperty (&_gbae ._fbd ._ege );_bce !=nil {return _bce ;};};if _gbae ._bcca ._gba {if _afbd :=_bcg .ReadProperty (&_gbae ._fbd ._bge );_afbd !=nil {return _afbd ;};};if _gbae ._bcca ._gag {if _cgg :=_bcg .ReadProperty (&_gbae ._fbd ._afb );_cgg !=nil {return _cgg ;};};if _gbae ._bcca ._bgf {if _dfd :=_bcg .ReadProperty (&_gbae ._fbd ._ddd );_dfd !=nil {return _dfd ;};};return nil ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// ScrollBarControl is a representation of a scrollBar ActiveX form.
type ScrollBarControl struct{controlBase ;_gdfgc *scrollBarPropMask ;_dccg *scrollBarDataBlock ;_abag *scrollBarExtraDataBlock ;_ddff *streamData ;};func (_gdac *SpinButtonControl )readDataBlock (_faga *_a .Reader )error {_gdac ._gff =&spinButtonDataBlock {};if _gdac ._eeba ._dbdg {if _ageb :=_faga .ReadProperty (&_gdac ._gff ._ccede );_ageb !=nil {return _ageb ;};};if _gdac ._eeba ._bbgd {if _dbea :=_faga .ReadProperty (&_gdac ._gff ._bfbb );_dbea !=nil {return _dbea ;};};if _gdac ._eeba ._adda {if _eacbc :=_faga .ReadProperty (&_gdac ._gff ._dgd );_eacbc !=nil {return _eacbc ;};};if _gdac ._eeba ._edeeg {if _egde :=_faga .ReadProperty (&_gdac ._gff ._acfc );_egde !=nil {return _egde ;};};if _gdac ._eeba ._fcbf {if _gggd :=_faga .ReadProperty (&_gdac ._gff ._gacc );_gggd !=nil {return _gggd ;};};if _gdac ._eeba ._ffeg {if _bgef :=_faga .ReadProperty (&_gdac ._gff ._abdb );_bgef !=nil {return _bgef ;};};if _gdac ._eeba ._cbbc {if _cgab :=_faga .ReadProperty (&_gdac ._gff ._bcad );_cgab !=nil {return _cgab ;};};if _gdac ._eeba ._ecgfc {if _gcee :=_faga .ReadProperty (&_gdac ._gff ._afed );_gcee !=nil {return _gcee ;};};if _gdac ._eeba ._cfda {if _dgc :=_faga .ReadProperty (&_gdac ._gff ._eed );_dgc !=nil {return _dgc ;};};if _gdac ._eeba ._aefb {if _bbcag :=_faga .ReadProperty (&_gdac ._gff ._ggfdf );_bbcag !=nil {return _bbcag ;};};if _gdac ._eeba ._feab {if _fbcf :=_faga .ReadProperty (&_gdac ._gff ._gccf );_fbcf !=nil {return _fbcf ;};};if _gdac ._eeba ._bcgb {if _cfg :=_faga .ReadProperty (&_gdac ._gff ._aace );_cfg !=nil {return _cfg ;};};if _gdac ._eeba ._dfaf {if _ccbfc :=_faga .ReadProperty (&_gdac ._gff ._dedbe );_ccbfc !=nil {return _ccbfc ;};};return nil ;};func (_gdff *LabelControl )readExtraDataBlock (_cbegc *_a .Reader )error {_gdff ._bfba =&labelExtraDataBlock {};if _gdff ._eea ._bcgg > 0{_defac ,_fad :=_cbegc .ReadStringProperty (_gdff ._eea ._bcgg );if _fad !=nil {return _fad ;};_gdff ._bfba ._geg =_defac ;};if _gdff ._aac ._gca {var _gdfg uint64 ;if _gaa :=_cbegc .ReadPairProperty (&_gdfg );_gaa !=nil {return _gaa ;};_gdff ._bfba ._edc =uint32 (_gdfg );_gdff ._bfba ._eaeg =uint32 (_gdfg >>32);};return nil ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetBackColor sets a button text color value from a system palette for a commandButton control.
func (_aa *CommandButtonControl )SetBackColor (backColor uint32 ){_aa ._bcca ._dge =true ;_aa ._fbd ._cdf =backColor ;};var _bcec =[]byte {0x04,0x52,0xE3,0x0B,0x91,0x8F,0xCE,0x11,0x9D,0xE3,0,0xAA,0,0x4B,0xB8,0x51};type guidAndPicture struct{_ebf []byte ;_bfb *stdPicture ;};type labelDataBlock struct{_dfe uint32 ;_baf uint32 ;_aaec uint32 ;_bcgg uint32 ;_bga bool ;_fceg uint32 ;_fbgf uint8 ;_cge uint32 ;_bab uint16 ;_ccgc uint16 ;_aedf uint16 ;_ffg rune ;_bdfd uint16 ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// ControlChoice represents an ActiveX control inside a wrapper.
type ControlChoice struct{CheckBox *CheckBoxDataControl ;TextBox *TextBoxDataControl ;ListBox *ListBoxDataControl ;ComboBox *ComboBoxDataControl ;OptionButton *OptionButtonDataControl ;ToggleButton *ToggleButtonDataControl ;Label *LabelControl ;Image *ImageControl ;SpinButton *SpinButtonControl ;CommandButton *CommandButtonControl ;ScrollBar *ScrollBarControl ;_ed *controlBase ;};func _dba (_efe uint32 )(bool ,uint32 ){if _efe ==0{return false ,0;};_ced :=_efe >=1<<31;if _ced {_efe -=1<<31;};return _ced ,_efe ;};func (_cedf *ScrollBarControl )writePropMask (_bbfe *_a .Writer )error {_gdcb :=uint32 (0);_gdcb =_a .PushLeftUI32 (_gdcb ,_cedf ._gdfgc ._daaad );_gdcb =_a .PushLeftUI32 (_gdcb ,_cedf ._gdfgc ._geba );_gdcb =_a .PushLeftUI32 (_gdcb ,_cedf ._gdfgc ._fbgb );_gdcb =_a .PushLeftUI32 (_gdcb ,_cedf ._gdfgc ._ebdd );_gdcb =_a .PushLeftUI32 (_gdcb ,_cedf ._gdfgc ._ccdf );_gdcb =_a .PushLeftUI32 (_gdcb ,_cedf ._gdfgc ._eacb );_gdcb =_a .PushLeftUI32 (_gdcb ,_cedf ._gdfgc ._fffc );_gdcb =_a .PushLeftUI32 (_gdcb ,_cedf ._gdfgc ._caed );_gdcb >>=1;_gdcb =_a .PushLeftUI32 (_gdcb ,_cedf ._gdfgc ._acdf );_gdcb =_a .PushLeftUI32 (_gdcb ,_cedf ._gdfgc ._ebbf );_gdcb =_a .PushLeftUI32 (_gdcb ,_cedf ._gdfgc ._fae );_gdcb =_a .PushLeftUI32 (_gdcb ,_cedf ._gdfgc ._fcaf );_gdcb =_a .PushLeftUI32 (_gdcb ,_cedf ._gdfgc ._dgfa );_gdcb =_a .PushLeftUI32 (_gdcb ,_cedf ._gdfgc ._dfad );_gdcb =_a .PushLeftUI32 (_gdcb ,_cedf ._gdfgc ._agg );_gdcb =_a .PushLeftUI32 (_gdcb ,_cedf ._gdfgc ._gfef );_gdcb >>=15;return _bb .Write (_bbfe ,_bb .LittleEndian ,_gdcb );};type imageDataBlock struct{_bca uint32 ;_fgc uint32 ;_ebc byte ;_acc uint8 ;_cgd byte ;_beb byte ;_acf uint16 ;_cfe byte ;_cbd uint32 ;_ceg uint16 ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetMin gets a button min value.
func (_acda *ScrollBarControl )GetMin ()int32 {return _acda ._dccg ._fgcc };type labelExtraDataBlock struct{_eaeg uint32 ;_edc uint32 ;_geg string ;};type spinButtonPropMask struct{_dbdg bool ;_bbgd bool ;_adda bool ;_ddeef bool ;_edeeg bool ;_fcbf bool ;_ffeg bool ;_cbbc bool ;_ecgfc bool ;_cfda bool ;_aefb bool ;_feab bool ;_bcgb bool ;_dfaf bool ;};func (_babc *morphDataControl )readColumnInfoDataBlock (_gdc *_a .Reader )error {return nil };var _faa =len (_bcec );func (_ebbff *ScrollBarControl )writeExtraDataBlock (_cacd *_a .Writer )error {if _ebbff ._gdfgc ._ebdd {_caba :=uint64 (_ebbff ._abag ._agga )<<32|uint64 (_ebbff ._abag ._gafc );if _eefeb :=_cacd .WritePropertyNoAlign (_caba );_eefeb !=nil {return _eefeb ;};};return nil ;};type scrollBarExtraDataBlock struct{_agga uint32 ;_gafc uint32 ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetBackColor gets a button text color value for a system palette from a scrollBar control.
func (_fcad *ScrollBarControl )GetBackColor ()uint32 {return _fcad ._dccg ._dcf };func (_add *ImageControl )readPropMask (_cfa *_a .Reader )error {var _edbb uint32 ;if _egfb :=_bb .Read (_cfa ,_bb .LittleEndian ,&_edbb );_egfb !=nil {return _egfb ;};_add ._afdg =&imagePropMask {};_edbb >>=2;_add ._afdg ._eaf ,_edbb =_a .PopRightUI32 (_edbb );_add ._afdg ._ded ,_edbb =_a .PopRightUI32 (_edbb );_add ._afdg ._cdea ,_edbb =_a .PopRightUI32 (_edbb );_add ._afdg ._dbba ,_edbb =_a .PopRightUI32 (_edbb );_add ._afdg ._bged ,_edbb =_a .PopRightUI32 (_edbb );_add ._afdg ._bbgg ,_edbb =_a .PopRightUI32 (_edbb );_add ._afdg ._fga ,_edbb =_a .PopRightUI32 (_edbb );_add ._afdg ._bcf ,_edbb =_a .PopRightUI32 (_edbb );_add ._afdg ._bccb ,_edbb =_a .PopRightUI32 (_edbb );_add ._afdg ._bad ,_edbb =_a .PopRightUI32 (_edbb );_add ._afdg ._fff ,_edbb =_a .PopRightUI32 (_edbb );_add ._afdg ._eaed ,_edbb =_a .PopRightUI32 (_edbb );_add ._afdg ._ceb ,_edbb =_a .PopRightUI32 (_edbb );return nil ;};func (_caf *controlBase )setPictureBytes (_eef []byte ){if _caf ._fcb ._fcac ==nil {_caf ._fcb ._fcac =&guidAndPicture {};};_caf ._fcb ._fcac .setStdPictureBytes (_eef );};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetHeight sets height of the ScrollBar in HIMETRIC (0.01mm)
func (_dcda *ScrollBarControl )SetHeight (height uint32 ){_dcda ._gdfgc ._ebdd =true ;_dcda ._abag ._gafc =height ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SpinButtonControl is a representation of a spinButton ActiveX form.
type SpinButtonControl struct{controlBase ;_eeba *spinButtonPropMask ;_gff *spinButtonDataBlock ;_feda *spinButtonExtraDataBlock ;_fefa *streamData ;};const (FmPictureAlignmentTopLeft FmPictureAlignment =iota ;FmPictureAlignmentTopRight ;FmPictureAlignmentCenter ;FmPictureAlignmentBottomLeft ;FmPictureAlignmentBottomRight ;);type morphDataColumnInfoPropMask struct{};func (_gf *CommandButtonControl )readPropMask (_dbfa *_a .Reader )error {var _bbcg uint32 ;if _cca :=_bb .Read (_dbfa ,_bb .LittleEndian ,&_bbcg );_cca !=nil {return _cca ;};_gf ._bcca =&commandButtonPropMask {};_gf ._bcca ._dbb ,_bbcg =_a .PopRightUI32 (_bbcg );_gf ._bcca ._dge ,_bbcg =_a .PopRightUI32 (_bbcg );_gf ._bcca ._dga ,_bbcg =_a .PopRightUI32 (_bbcg );_gf ._bcca ._edg ,_bbcg =_a .PopRightUI32 (_bbcg );_gf ._bcca ._cdd ,_bbcg =_a .PopRightUI32 (_bbcg );_gf ._bcca ._ebg ,_bbcg =_a .PopRightUI32 (_bbcg );_gf ._bcca ._fdf ,_bbcg =_a .PopRightUI32 (_bbcg );_gf ._bcca ._gba ,_bbcg =_a .PopRightUI32 (_bbcg );_gf ._bcca ._gag ,_bbcg =_a .PopRightUI32 (_bbcg );_gf ._bcca ._fcd ,_bbcg =_a .PopRightUI32 (_bbcg );_gf ._bcca ._bgf ,_bbcg =_a .PopRightUI32 (_bbcg );return nil ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// OptionButtonDataControl is a representation of an option button ActiveX form.
type OptionButtonDataControl struct{*morphDataControlBoolValue };func (_adeb *controlBase )writeStreamDataM (_ggceg *_a .Writer )error {if _adeb ._fcb !=nil {if _adeb ._fcb ._cbec !=nil {if _ddb :=_adeb ._fcb ._cbec .export (_ggceg );_ddb !=nil {return _ddb ;};};};return nil ;};func _gcbe (_abb *_a .Reader )(*morphDataControl ,error ){_gec :=&morphDataControl {};if _fcaa :=_gec .readPropMask (_abb );_fcaa !=nil {return nil ,_fcaa ;};if _egfd :=_gec .readDataBlock (_abb );_egfd !=nil {return nil ,_egfd ;};if _ebbc :=_gec .readExtraDataBlock (_abb );_ebbc !=nil {return nil ,_ebbc ;};if _edff :=_gec .readStreamDataMP (_abb ,_gec ._ebb ._gfd ,_gec ._ebb ._bebc );_edff !=nil {return nil ,_edff ;};switch _gec ._bgag ._ace {case _ecfa ,_cgdb :if _gace :=_gec .readColumnInfo (_abb );_gace !=nil {return nil ,_gace ;};if _cafb :=_gec .readColumnInfoPropMask (_abb );_cafb !=nil {return nil ,_cafb ;};if _bbfa :=_gec .readColumnInfoDataBlock (_abb );_bbfa !=nil {return nil ,_bbfa ;};};if _cba :=_gec .readTheRest (_abb );_cba !=nil {return nil ,_cba ;};return _gec ,nil ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetForeColor gets a button text color value for a system palette from a label control.
func (_cbgd *LabelControl )GetForeColor ()uint32 {return _cbgd ._eea ._dfe };
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetWidth sets width of the morphDataControl in HIMETRIC (0.01mm)
func (_dag *morphDataControl )SetWidth (width uint32 ){_dag ._ebb ._baba =true ;_dag ._gabe ._dccc =width ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetMax sets a button max value.
func (_afc *SpinButtonControl )SetMax (max int32 ){_afc ._eeba ._fcbf =true ;_afc ._gff ._gacc =max };func (_gcb *ImageControl )writeExtraDataBlock (_edba *_a .Writer )error {if _gcb ._afdg ._bcf {_acfd :=uint64 (_gcb ._ecf ._fac )<<32|uint64 (_gcb ._ecf ._fdc );if _cbb :=_edba .WritePropertyNoAlign (_acfd );_cbb !=nil {return _cbb ;};};return nil ;};func (_cde *controlBase )getPictureBytes ()[]byte {return _cde ._fcb ._fcac .getStdPictureBytes ()};func _gg (_dad *_bf .Reader )(string ,error ){_bff ,_aec :=_dad .GetEntry ("\u0043o\u006d\u0070\u004f\u0062\u006a");if _aec !=nil {return "",_aec ;};_ggg :=make ([]byte ,_bff .Size );_ ,_aec =_bff .Read (_ggg );if _aec !=nil {return "",_aec ;};_fea :=_d .Split (_ggg ,[]byte ("\u002e"));if len (_fea )< 2{return "",_g .New ("\u0055\u006e\u006bn\u006f\u0077\u006e\u0020\u0066\u006f\u0072\u006d");};return string (_fea [len (_fea )-2]),nil ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetForeColor gets a button text color value for a system palette from a scrollBar control.
func (_afeb *ScrollBarControl )GetForeColor ()uint32 {return _afeb ._dccg ._gdd };func (_gdef *morphDataControl )writeColumnInfo (_bcgd *_a .Writer )error {return nil };func (_fbc *LabelControl )readPropMask (_ffda *_a .Reader )error {var _fdbc uint32 ;if _fec :=_bb .Read (_ffda ,_bb .LittleEndian ,&_fdbc );_fec !=nil {return _fec ;};_fbc ._aac =&labelPropMask {};_fbc ._aac ._gac ,_fdbc =_a .PopRightUI32 (_fdbc );_fbc ._aac ._dfa ,_fdbc =_a .PopRightUI32 (_fdbc );_fbc ._aac ._abec ,_fdbc =_a .PopRightUI32 (_fdbc );_fbc ._aac ._agf ,_fdbc =_a .PopRightUI32 (_fdbc );_fbc ._aac ._ddee ,_fdbc =_a .PopRightUI32 (_fdbc );_fbc ._aac ._gca ,_fdbc =_a .PopRightUI32 (_fdbc );_fbc ._aac ._cebg ,_fdbc =_a .PopRightUI32 (_fdbc );_fbc ._aac ._fgag ,_fdbc =_a .PopRightUI32 (_fdbc );_fbc ._aac ._fede ,_fdbc =_a .PopRightUI32 (_fdbc );_fbc ._aac ._feec ,_fdbc =_a .PopRightUI32 (_fdbc );_fbc ._aac ._edd ,_fdbc =_a .PopRightUI32 (_fdbc );_fbc ._aac ._dea ,_fdbc =_a .PopRightUI32 (_fdbc );_fbc ._aac ._fbb ,_fdbc =_a .PopRightUI32 (_fdbc );return nil ;};type imageExtraDataBlock struct{_fac uint32 ;_fdc uint32 ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetHeight returns height of the SpinButton in HIMETRIC (0.01mm)
func (_ddab *SpinButtonControl )GetHeight ()uint32 {return _ddab ._feda ._ebef };type morphDataPropMask struct{_aeeb bool ;_cfce bool ;_daa bool ;_dbda bool ;_gfab bool ;_fbbb bool ;_dcbc bool ;_afbe bool ;_baba bool ;_agab bool ;_ggfd bool ;_cda bool ;_bcae bool ;_cea bool ;_dagb bool ;_gaab bool ;_efedc bool ;_cgga bool ;_gbaa bool ;_cga bool ;_ece bool ;_bgfb bool ;_feef bool ;_aaf bool ;_fcc bool ;_fgf bool ;_gfd bool ;_bebc bool ;_dagd bool ;_cggd bool ;};func (_bdca *morphDataControl )setValueBool (_faf bool ){_bdca ._ebb ._bgfb =true ;_bdca ._bgag ._fdcfe =1;_bdca ._bgag ._afa =true ;_bbcff :="\u0030";if _faf {_bbcff ="\u0031";};_bdca ._gabe ._abbd =_bbcff ;};func _cabg (_dfef *_a .Reader )(*ScrollBarControl ,error ){_abf :=&ScrollBarControl {};if _acg :=_abf .readPropMask (_dfef );_acg !=nil {return nil ,_acg ;};if _defae :=_abf .readDataBlock (_dfef );_defae !=nil {return nil ,_defae ;};if _cag :=_abf .readExtraDataBlock (_dfef );_cag !=nil {return nil ,_cag ;};if _dcdef :=_abf .readStreamDataM (_dfef ,_abf ._gdfgc ._gfef );_dcdef !=nil {return nil ,_dcdef ;};if _cfb :=_abf .readTheRest (_dfef );_cfb !=nil {return nil ,_cfb ;};return _abf ,nil ;};
2022-01-15 21:17:38 +00:00
2022-02-05 13:05:36 +00:00
// GetCaption gets a caption string from a label control.
2022-02-25 19:20:45 +00:00
func (_edbg *LabelControl )GetCaption ()string {return _edbg ._bfba ._geg };
2022-02-05 13:05:36 +00:00
2022-02-25 19:20:45 +00:00
// ListBoxDataControl is a representation of a list box ActiveX form.
type ListBoxDataControl struct{*morphDataControlStringValue };type scrollBarPropMask struct{_daaad bool ;_geba bool ;_fbgb bool ;_ccdf bool ;_ebdd bool ;_eacb bool ;_fffc bool ;_caed bool ;_acdf bool ;_ebbf bool ;_fae bool ;_fcaf bool ;_dgfa bool ;_dfad bool ;_agg bool ;_gfef bool ;};type controlBase struct{_ggc uint16 ;_acd bool ;_fcb *streamData ;_dada []byte ;};type morphDataControlBoolValue struct{*morphDataControl };
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// LabelControl is a representation of a label ActiveX form.
type LabelControl struct{controlBase ;_aac *labelPropMask ;_eea *labelDataBlock ;_bfba *labelExtraDataBlock ;_gfb *streamData ;};func (_ffcd *guidAndPicture )export (_cede *_a .Writer )error {if _ ,_fce :=_b .Copy (_cede ,_d .NewBuffer (_ffcd ._ebf ));_fce !=nil {return _fce ;};if _dffa :=_cede .WriteProperty (_ffcd ._bfb ._abaf );_dffa !=nil {return _dffa ;};if _gcca :=_cede .WriteProperty (_ffcd ._bfb ._ccb );_gcca !=nil {return _gcca ;};_ ,_caa :=_b .Copy (_cede ,_ffcd ._bfb ._dff );if _caa !=nil {return _caa ;};return nil ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetHeight sets height of the CommandButton in HIMETRIC (0.01mm)
func (_gcd *CommandButtonControl )SetHeight (height uint32 ){_gcd ._bcca ._ebg =true ;_gcd ._ca ._aeb =height ;};func (_afda *ImageControl )readDataBlock (_ccaa *_a .Reader )error {_afda ._fdad =&imageDataBlock {};if _afda ._afdg ._ded {if _bbcf :=_ccaa .ReadProperty (&_afda ._fdad ._bca );_bbcf !=nil {return _bbcf ;};};if _afda ._afdg ._cdea {if _ffd :=_ccaa .ReadProperty (&_afda ._fdad ._fgc );_ffd !=nil {return _ffd ;};};if _afda ._afdg ._dbba {if _fbe :=_ccaa .ReadProperty (&_afda ._fdad ._ebc );_fbe !=nil {return _fbe ;};};if _afda ._afdg ._bged {if _bdf :=_ccaa .ReadProperty (&_afda ._fdad ._acc );_bdf !=nil {return _bdf ;};};if _afda ._afdg ._bbgg {if _bgeb :=_ccaa .ReadProperty (&_afda ._fdad ._cgd );_bgeb !=nil {return _bgeb ;};};if _afda ._afdg ._fga {if _fee :=_ccaa .ReadProperty (&_afda ._fdad ._beb );_fee !=nil {return _fee ;};};if _afda ._afdg ._bccb {if _gea :=_ccaa .ReadProperty (&_afda ._fdad ._acf );_gea !=nil {return _gea ;};};if _afda ._afdg ._bad {if _bea :=_ccaa .ReadProperty (&_afda ._fdad ._cfe );_bea !=nil {return _bea ;};};if _afda ._afdg ._eaed {if _ccgd :=_ccaa .ReadProperty (&_afda ._fdad ._cbd );_ccgd !=nil {return _ccgd ;};};if _afda ._afdg ._ceb {if _dbec :=_ccaa .ReadProperty (&_afda ._fdad ._ceg );_dbec !=nil {return _dbec ;};};return nil ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetWidth returns width of the CommandButton in HIMETRIC (0.01mm)
func (_gbg *CommandButtonControl )GetWidth ()uint32 {return _gbg ._ca ._ggf };func (_cddb *controlBase )readStreamDataPM (_ecfad *_a .Reader ,_cgbf ,_afee bool )error {_cddb ._fcb =&streamData {};if _cgbf {_cddb ._fcb ._fcac =&guidAndPicture {};if _gffe :=_cddb ._fcb ._fcac .importFromReader (_ecfad );_gffe !=nil {return _gffe ;};};if _afee {_cddb ._fcb ._cbec =&guidAndPicture {};if _ddffd :=_cddb ._fcb ._cbec .importFromReader (_ecfad );_ddffd !=nil {return _ddffd ;};};return nil ;};func (_dfac *controlBase )writeStreamDataPM (_ebea *_a .Writer )error {if _dfac ._fcb !=nil {if _dfac ._fcb ._fcac !=nil {if _ggfa :=_dfac ._fcb ._fcac .export (_ebea );_ggfa !=nil {return _ggfa ;};};if _dfac ._fcb ._cbec !=nil {if _fffg :=_dfac ._fcb ._cbec .export (_ebea );_fffg !=nil {return _fffg ;};};};return nil ;};func (_cbee *guidAndPicture )setStdPictureBytes (_dca []byte ){if _dca ==nil {return ;};if _cbee ._ebf ==nil {_cbee ._ebf =_bcec ;};if _cbee ._bfb ==nil {_cbee ._bfb =&stdPicture {_abaf :_bdb };};_cbee ._bfb ._ccb =uint32 (len (_dca ));_cbee ._bfb ._dff =_d .NewBuffer (_dca );};const _geee =5;
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetWidth sets width of the ScrollBar in HIMETRIC (0.01mm)
func (_eeb *ScrollBarControl )SetWidth (width uint32 ){_eeb ._gdfgc ._ebdd =true ;_eeb ._abag ._agga =width ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetCaption gets a caption string from a commandButton control.
func (_feb *CommandButtonControl )GetCaption ()string {return _feb ._ca ._ecg };const _bfdd =6;type spinButtonExtraDataBlock struct{_becd uint32 ;_ebef uint32 ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetWidth returns width of the Label in HIMETRIC (0.01mm)
func (_gfbd *LabelControl )GetWidth ()uint32 {return _gfbd ._bfba ._eaeg };func (_cdbg *morphDataControl )readColumnInfoPropMask (_abdg *_a .Reader )error {return nil };func (_fed *ImageControl )readExtraDataBlock (_adgb *_a .Reader )error {_fed ._ecf =&imageExtraDataBlock {};if _fed ._afdg ._bcf {var _bbe uint64 ;if _cddd :=_adgb .ReadPairProperty (&_bbe );_cddd !=nil {return _cddd ;};_fed ._ecf ._fdc =uint32 (_bbe );_fed ._ecf ._fac =uint32 (_bbe >>32);};return nil ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetBackColor gets a button text color value for a system palette from a commandButton control.
func (_dcb *CommandButtonControl )GetBackColor ()uint32 {return _dcb ._fbd ._cdf };
2022-01-15 21:17:38 +00:00
2022-02-05 13:05:36 +00:00
// SetForeColor sets a button text color value from a system palette for a commandButton control.
2022-02-25 19:20:45 +00:00
func (_fbg *CommandButtonControl )SetForeColor (foreColor uint32 ){_fbg ._bcca ._dbb =true ;_fbg ._fbd ._gfc =foreColor ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// FmPictureAlignment represents one of the five picture aignments according to MS-OFORMS document.
type FmPictureAlignment byte ;func (_aed *controlBase )writeTheRest (_gagc *_a .Writer )error {_ ,_bacc :=_gagc .Write (_aed ._dada );return _bacc ;};func _efad (_gge *_a .Reader )(*ImageControl ,error ){_ggca :=&ImageControl {};if _bacf :=_ggca .readPropMask (_gge );_bacf !=nil {return nil ,_bacf ;};if _cdb :=_ggca .readDataBlock (_gge );_cdb !=nil {return nil ,_cdb ;};if _ggggg :=_ggca .readExtraDataBlock (_gge );_ggggg !=nil {return nil ,_ggggg ;};if _dgae :=_ggca .readStreamDataPM (_gge ,_ggca ._afdg ._bccb ,_ggca ._afdg ._ceb );_dgae !=nil {return nil ,_dgae ;};if _feae :=_ggca .readTheRest (_gge );_feae !=nil {return nil ,_feae ;};return _ggca ,nil ;};func _gggc (_bfee *_a .Reader )(*SpinButtonControl ,error ){_fecf :=&SpinButtonControl {};if _dbbc :=_fecf .readPropMask (_bfee );_dbbc !=nil {return nil ,_dbbc ;};if _ggcg :=_fecf .readDataBlock (_bfee );_ggcg !=nil {return nil ,_ggcg ;};if _cdgc :=_fecf .readExtraDataBlock (_bfee );_cdgc !=nil {return nil ,_cdgc ;};if _agdd :=_fecf .readStreamDataM (_bfee ,_fecf ._eeba ._bcgb );_agdd !=nil {return nil ,_agdd ;};if _ffab :=_fecf .readTheRest (_bfee );_ffab !=nil {return nil ,_ffab ;};return _fecf ,nil ;};func (_fdb *controlBase )setMouseIconBytes (_bed []byte ){if _fdb ._fcb ._cbec ==nil {_fdb ._fcb ._cbec =&guidAndPicture {};};_fdb ._fcb ._cbec .setStdPictureBytes (_bed );};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetCaption gets a caption string from a morph control.
func (_gcfg *morphDataControl )GetCaption ()string {if _gcfg ._acd &&_gcfg ._ebb ._feef {return _gcfg ._gabe ._ceef ;};return "";};func _daed (_gbgb *_a .Reader )(*LabelControl ,error ){_bec :=&LabelControl {};if _bfga :=_bec .readPropMask (_gbgb );_bfga !=nil {return nil ,_bfga ;};if _befe :=_bec .readDataBlock (_gbgb );_befe !=nil {return nil ,_befe ;};if _cfee :=_bec .readExtraDataBlock (_gbgb );_cfee !=nil {return nil ,_cfee ;};if _fefb :=_bec .readStreamDataPM (_gbgb ,_bec ._aac ._edd ,_bec ._aac ._fbb );_fefb !=nil {return nil ,_fefb ;};if _dce :=_bec .readTheRest (_gbgb );_dce !=nil {return nil ,_dce ;};return _bec ,nil ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// ToggleButtonDataControl is a representation of a toggle button ActiveX form.
type ToggleButtonDataControl struct{*morphDataControlBoolValue };
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetForeColor gets a button text color value for a system palette from a spinButton control.
func (_gbaee *SpinButtonControl )GetForeColor ()uint32 {return _gbaee ._gff ._ccede };func (_ggce *morphDataControl )writeExtraDataBlock (_ged *_a .Writer )error {if _ggce ._ebb ._baba {_ccfe :=uint64 (_ggce ._gabe ._dccc )<<32|uint64 (_ggce ._gabe ._cee );if _ffdd :=_ged .WritePropertyNoAlign (_ccfe );_ffdd !=nil {return _ffdd ;};};if _ggce ._bgag ._fdcfe > 0{if _aacc :=_ged .WriteStringProperty (_ggce ._gabe ._abbd );_aacc !=nil {return _aacc ;};};if _ggce ._bgag ._dgea > 0{if _adf :=_ged .WriteStringProperty (_ggce ._gabe ._ceef );_adf !=nil {return _adf ;};};if _ggce ._bgag ._acae > 0{if _gdbe :=_ged .WriteStringProperty (_ggce ._gabe ._cbdc );_gdbe !=nil {return _gdbe ;};};return nil ;};
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// SetForeColor sets a button text color value from a system palette for a label control.
func (_efc *LabelControl )SetForeColor (foreColor uint32 ){_efc ._aac ._gac =true ;_efc ._eea ._dfe =foreColor ;};const (FmPictureSizeModeClip FmPictureSizeMode =iota ;FmPictureSizeModeStretch ;_ ;FmPictureSizeModeZoom ;);type morphDataColumnInfoDataBlock struct{};func (_dfg *SpinButtonControl )writeDataBlock (_efedb *_a .Writer )error {if _dfg ._eeba ._dbdg {if _fbec :=_efedb .WriteProperty (_dfg ._gff ._ccede );_fbec !=nil {return _fbec ;};};if _dfg ._eeba ._bbgd {if _ebbca :=_efedb .WriteProperty (_dfg ._gff ._bfbb );_ebbca !=nil {return _ebbca ;};};if _dfg ._eeba ._adda {if _gdga :=_efedb .WriteProperty (_dfg ._gff ._dgd );_gdga !=nil {return _gdga ;};};if _dfg ._eeba ._edeeg {if _acfde :=_efedb .WriteProperty (_dfg ._gff ._acfc );_acfde !=nil {return _acfde ;};};if _dfg ._eeba ._fcbf {if _dcab :=_efedb .WriteProperty (_dfg ._gff ._gacc );_dcab !=nil {return _dcab ;};};if _dfg ._eeba ._ffeg {if _efgg :=_efedb .WriteProperty (_dfg ._gff ._abdb );_efgg !=nil {return _efgg ;};};if _dfg ._eeba ._cbbc {if _gbged :=_efedb .WriteProperty (_dfg ._gff ._bcad );_gbged !=nil {return _gbged ;};};if _dfg ._eeba ._ecgfc {if _agcd :=_efedb .WriteProperty (_dfg ._gff ._afed );_agcd !=nil {return _agcd ;};};if _dfg ._eeba ._cfda {if _aedc :=_efedb .WriteProperty (_dfg ._gff ._eed );_aedc !=nil {return _aedc ;};};if _dfg ._eeba ._aefb {if _fdef :=_efedb .WriteProperty (_dfg ._gff ._ggfdf );_fdef !=nil {return _fdef ;};};if _dfg ._eeba ._feab {if _dbg :=_efedb .WriteProperty (_dfg ._gff ._gccf );_dbg !=nil {return _dbg ;};};if _dfg ._eeba ._bcgb {if _ddc :=_efedb .WriteProperty (_dfg ._gff ._aace );_ddc !=nil {return _ddc ;};};if _dfg ._eeba ._dfaf {if _gaga :=_efedb .WriteProperty (_dfg ._gff ._dedbe );_gaga !=nil {return _gaga ;};};return _efedb .AlignLength (4);};func (_bdgb *ImageControl )writePropMask (_aeg *_a .Writer )error {_efg :=uint32 (0);_efg >>=2;_efg =_a .PushLeftUI32 (_efg ,_bdgb ._afdg ._eaf );_efg =_a .PushLeftUI32 (_efg ,_bdgb ._afdg ._ded );_efg =_a .PushLeftUI32 (_efg ,_bdgb ._afdg ._cdea );_efg =_a .PushLeftUI32 (_efg ,_bdgb ._afdg ._dbba );_efg =_a .PushLeftUI32 (_efg ,_bdgb ._afdg ._bged );_efg =_a .PushLeftUI32 (_efg ,_bdgb ._afdg ._bbgg );_efg =_a .PushLeftUI32 (_efg ,_bdgb ._afdg ._fga );_efg =_a .PushLeftUI32 (_efg ,_bdgb ._afdg ._bcf );_efg =_a .PushLeftUI32 (_efg ,_bdgb ._afdg ._bccb );_efg =_a .PushLeftUI32 (_efg ,_bdgb ._afdg ._bad );_efg =_a .PushLeftUI32 (_efg ,_bdgb ._afdg ._fff );_efg =_a .PushLeftUI32 (_efg ,_bdgb ._afdg ._eaed );_efg =_a .PushLeftUI32 (_efg ,_bdgb ._afdg ._ceb );_efg >>=17;return _bb .Write (_aeg ,_bb .LittleEndian ,_efg );};func (_gccd *morphDataControl )export (_faff *_a .Writer )error {if _bece :=_gccd .writePropMask (_faff );_bece !=nil {return _bece ;};if _cfd :=_gccd .writeDataBlock (_faff );_cfd !=nil {return _cfd ;};if _dadb :=_gccd .writeExtraDataBlock (_faff );_dadb !=nil {return _dadb ;};_gccd ._ggc =uint16 (_faff .Len ()-4);if _cfaa :=_gccd .writeStreamDataMP (_faff );_cfaa !=nil {return _cfaa ;};return _gccd .writeTheRest (_faff );};func (_eb *CommandButtonControl )export (_dbe *_a .Writer )error {if _bfg :=_eb .writePropMask (_dbe );_bfg !=nil {return _bfg ;};if _de :=_eb .writeDataBlock (_dbe );_de !=nil {return _de ;};if _edb :=_eb .writeExtraDataBlock (_dbe );_edb !=nil {return _edb ;};_eb ._ggc =uint16 (_dbe .Len ()-4);if _bac :=_eb .writeStreamDataPM (_dbe );_bac !=nil {return _bac ;};return _eb .writeTheRest (_dbe );};func (_fge *SpinButtonControl )writePropMask (_bfdda *_a .Writer )error {_dcg :=uint32 (0);_dcg =_a .PushLeftUI32 (_dcg ,_fge ._eeba ._dbdg );_dcg =_a .PushLeftUI32 (_dcg ,_fge ._eeba ._bbgd );_dcg =_a .PushLeftUI32 (_dcg ,_fge ._eeba ._adda );_dcg =_a .PushLeftUI32 (_dcg ,_fge ._eeba ._ddeef );_dcg >>=1;_dcg =_a .PushLeftUI32 (_dcg ,_fge ._eeba ._edeeg );_dcg =_a .PushLeftUI32 (_dcg ,_fge ._eeba ._fcbf );_dcg =_a .PushLeftUI32 (_dcg ,_fge ._eeba ._ffeg );_dcg =_a .PushLeftUI32 (_dcg ,_fge ._eeba ._cbbc );_dcg =_a .PushLeftUI32 (_dcg ,_fge ._eeba ._ecgfc );_dcg =_a .PushLeftUI32 (_dcg ,_fge ._eeba ._cfda );_dcg =_a .PushLeftUI32 (_dcg ,_fge ._eeba
2022-01-15 21:17:38 +00:00
2022-02-25 19:20:45 +00:00
// GetHeight returns height of the Label in HIMETRIC (0.01mm)
func (_cab *LabelControl )GetHeight ()uint32 {return _cab ._bfba ._edc };func (_affd *ImageControl )writeDataBlock (_eaa *_a .Writer )error {if _affd ._afdg ._ded {if _dgb :=_eaa .WriteProperty (_affd ._fdad ._bca );_dgb !=nil {return _dgb ;};};if _affd ._afdg ._cdea {if _ccab :=_eaa .WriteProperty (_affd ._fdad ._fgc );_ccab !=nil {return _ccab ;};};if _affd ._afdg ._dbba {if _abae :=_eaa .WriteProperty (_affd ._fdad ._ebc );_abae !=nil {return _abae ;};};if _affd ._afdg ._bged {if _ffcdd :=_eaa .WriteProperty (_affd ._fdad ._acc );_ffcdd !=nil {return _ffcdd ;};};if _affd ._afdg ._bbgg {if _dgef :=_eaa .WriteProperty (_affd ._fdad ._cgd );_dgef !=nil {return _dgef ;};};if _affd ._afdg ._fga {if _ebe :=_eaa .WriteProperty (_affd ._fdad ._beb );_ebe !=nil {return _ebe ;};};if _affd ._afdg ._bccb {if _fba :=_eaa .WriteProperty (_affd ._fdad ._acf );_fba !=nil {return _fba ;};};if _affd ._afdg ._bad {if _cgb :=_eaa .WriteProperty (_affd ._fdad ._cfe );_cgb !=nil {return _cgb ;};};if _affd ._afdg ._eaed {if _cedc :=_eaa .WriteProperty (_affd ._fdad ._cbd );_cedc !=nil {return _cedc ;};};if _affd ._afdg ._ceb {if _bda :=_eaa .WriteProperty (_affd ._fdad ._ceg );_bda !=nil {return _bda ;};};return _eaa .AlignLength (4);};
2022-02-05 13:05:36 +00:00
2022-02-25 19:20:45 +00:00
// SetWidth sets width of the CommandButton in HIMETRIC (0.01mm)
func (_dcc *CommandButtonControl )SetWidth (width uint32 ){_dcc ._bcca ._ebg =true ;_dcc ._ca ._ggf =width ;};func (_ff *CommandButtonControl )writePropMask (_fca *_a .Writer )error {_bdg :=uint32 (0);_bdg =_a .PushLeftUI32 (_bdg ,_ff ._bcca ._dbb );_bdg =_a .PushLeftUI32 (_bdg ,_ff ._bcca ._dge );_bdg =_a .PushLeftUI32 (_bdg ,_ff ._bcca ._dga );_bdg =_a .PushLeftUI32 (_bdg ,_ff ._bcca ._edg );_bdg =_a .PushLeftUI32 (_bdg ,_ff ._bcca ._cdd );_bdg =_a .PushLeftUI32 (_bdg ,_ff ._bcca ._ebg );_bdg =_a .PushLeftUI32 (_bdg ,_ff ._bcca ._fdf );_bdg =_a .PushLeftUI32 (_bdg ,_ff ._bcca ._gba );_bdg =_a .PushLeftUI32 (_bdg ,_ff ._bcca ._gag );_bdg =_a .PushLeftUI32 (_bdg ,_ff ._bcca ._fcd );_bdg =_a .PushLeftUI32 (_bdg ,_ff ._bcca ._bgf );_bdg >>=21;return _bb .Write (_fca ,_bb .LittleEndian ,_bdg );};
2022-02-05 13:05:36 +00:00
// GetValue gets a value from a control which value can be represented as a string.
2022-02-25 19:20:45 +00:00
func (_bfeb *morphDataControlStringValue )GetValue ()string {return _bfeb .getValueString ()};func (_beag *LabelControl )writePropMask (_gaca *_a .Writer )error {_bae :=uint32 (0);_bae =_a .PushLeftUI32 (_bae ,_beag ._aac ._gac );_bae =_a .PushLeftUI32 (_bae ,_beag ._aac ._dfa );_bae =_a .PushLeftUI32 (_bae ,_beag ._aac ._abec );_bae =_a .PushLeftUI32 (_bae ,_beag ._aac ._agf );_bae =_a .PushLeftUI32 (_bae ,_beag ._aac ._ddee );_bae =_a .PushLeftUI32 (_bae ,_beag ._aac ._gca );_bae =_a .PushLeftUI32 (_bae ,_beag ._aac ._cebg );_bae =_a .PushLeftUI32 (_bae ,_beag ._aac ._fgag );_bae =_a .PushLeftUI32 (_bae ,_beag ._aac ._fede );_bae =_a .PushLeftUI32 (_bae ,_beag ._aac ._feec );_bae =_a .PushLeftUI32 (_bae ,_beag ._aac ._edd );_bae =_a .PushLeftUI32 (_bae ,_beag ._aac ._dea );_bae =_a .PushLeftUI32 (_bae ,_beag ._aac ._fbb );_bae >>=19;return _bb .Write (_gaca ,_bb .LittleEndian ,_bae );};
// CheckBoxDataControl is a representation of a check box ActiveX form.
type CheckBoxDataControl struct{*morphDataControlBoolValue };type stdPicture struct{_abaf uint32 ;_ccb uint32 ;_dff *_d .Buffer ;};
// SetHeight sets height of the morphDataControl in HIMETRIC (0.01mm)
func (_afg *morphDataControl )SetHeight (height uint32 ){_afg ._ebb ._baba =true ;_afg ._gabe ._cee =height ;};func (_cdc *CommandButtonControl )writeExtraDataBlock (_gbc *_a .Writer )error {if _cdc ._fbd ._ccf > 0{if _befb :=_gbc .WriteStringProperty (_cdc ._ca ._ecg );_befb !=nil {return _befb ;};};if _cdc ._bcca ._ebg {_cced :=uint64 (_cdc ._ca ._ggf )<<32|uint64 (_cdc ._ca ._aeb );if _ccg :=_gbc .WritePropertyNoAlign (_cced );_ccg !=nil {return _ccg ;};};return nil ;};func (_fbbd *morphDataControl )writeColumnInfoPropMask (_cdcg *_a .Writer )error {return nil };