LibreOffice Module oox (master) 1
axcontrol.hxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 *
9 * This file incorporates work covered by the following license notice:
10 *
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 */
19
20#ifndef INCLUDED_OOX_OLE_AXCONTROL_HXX
21#define INCLUDED_OOX_OLE_AXCONTROL_HXX
22
23#include <memory>
24#include <vector>
25
26#include <com/sun/star/uno/Reference.hxx>
27#include <com/sun/star/uno/Sequence.hxx>
28#include <oox/dllapi.h>
33#include <oox/ole/olehelper.hxx>
34#include <rtl/ustring.hxx>
35#include <sal/types.h>
36
37namespace com::sun::star {
38 namespace awt { class XControlModel; }
39 namespace container { class XIndexContainer; }
40 namespace drawing { class XDrawPage; }
41 namespace frame { class XModel; }
42 namespace form { class XFormsSupplier; }
43 namespace lang { class XMultiServiceFactory; }
44}
45
46namespace oox {
47 class BinaryInputStream;
48 class BinaryOutputStream;
49 class GraphicHelper;
50 class PropertyMap;
51}
52
53namespace oox::ole {
54
55
56#define COMCTL_GUID_SCROLLBAR_60 "{FE38753A-44A3-11D1-B5B7-0000C09000C4}"
57#define COMCTL_GUID_PROGRESSBAR_50 "{0713E8D2-850A-101B-AFC0-4210102A8DA7}"
58#define COMCTL_GUID_PROGRESSBAR_60 "{35053A22-8589-11D1-B16A-00C0F0283628}"
59
60const sal_uInt16 COMCTL_VERSION_50 = 5;
61const sal_uInt16 COMCTL_VERSION_60 = 6;
62
63
64#define AX_GUID_COMMANDBUTTON "{D7053240-CE69-11CD-a777-00dd01143c57}"
65#define AX_GUID_LABEL "{978C9E23-D4B0-11CE-bf2d-00aa003f40d0}"
66#define AX_GUID_IMAGE "{4C599241-6926-101B-9992-00000b65c6f9}"
67#define AX_GUID_TOGGLEBUTTON "{8BD21D60-EC42-11CE-9e0d-00aa006002f3}"
68#define AX_GUID_CHECKBOX "{8BD21D40-EC42-11CE-9e0d-00aa006002f3}"
69#define AX_GUID_OPTIONBUTTON "{8BD21D50-EC42-11CE-9e0d-00aa006002f3}"
70#define AX_GUID_TEXTBOX "{8BD21D10-EC42-11CE-9e0d-00aa006002f3}"
71#define AX_GUID_LISTBOX "{8BD21D20-EC42-11CE-9e0d-00aa006002f3}"
72#define AX_GUID_COMBOBOX "{8BD21D30-EC42-11CE-9e0d-00aa006002f3}"
73#define AX_GUID_SPINBUTTON "{79176FB0-B7F2-11CE-97ef-00aa006d2776}"
74#define AX_GUID_SCROLLBAR "{DFD181E0-5E2F-11CE-a449-00aa004a803d}"
75#define AX_GUID_FRAME "{6E182020-F460-11CE-9bcd-00aa00608e01}"
76
77// Html control GUID(s)
78
79#define HTML_GUID_SELECT "{5512D122-5CC6-11CF-8d67-00aa00bdce1d}"
80#define HTML_GUID_TEXTBOX "{5512D124-5CC6-11CF-8d67-00aa00bdce1d}"
81
82const sal_uInt32 AX_SYSCOLOR_WINDOWBACK = 0x80000005;
83const sal_uInt32 AX_SYSCOLOR_WINDOWFRAME = 0x80000006;
84const sal_uInt32 AX_SYSCOLOR_WINDOWTEXT = 0x80000008;
85const sal_uInt32 AX_SYSCOLOR_BUTTONFACE = 0x8000000F;
86const sal_uInt32 AX_SYSCOLOR_BUTTONTEXT = 0x80000012;
87
88const sal_uInt32 AX_FLAGS_ENABLED = 0x00000002;
89const sal_uInt32 AX_FLAGS_LOCKED = 0x00000004;
90const sal_uInt32 AX_FLAGS_OPAQUE = 0x00000008;
91const sal_uInt32 AX_FLAGS_COLUMNHEADS = 0x00000400;
92const sal_uInt32 AX_FLAGS_ENTIREROWS = 0x00000800;
93const sal_uInt32 AX_FLAGS_EXISTINGENTRIES = 0x00001000;
94const sal_uInt32 AX_FLAGS_CAPTIONLEFT = 0x00002000;
95const sal_uInt32 AX_FLAGS_EDITABLE = 0x00004000;
96const sal_uInt32 AX_FLAGS_IMEMODE_MASK = 0x00078000;
97const sal_uInt32 AX_FLAGS_DRAGENABLED = 0x00080000;
98const sal_uInt32 AX_FLAGS_ENTERASNEWLINE = 0x00100000;
99const sal_uInt32 AX_FLAGS_KEEPSELECTION = 0x00200000;
100const sal_uInt32 AX_FLAGS_TABASCHARACTER = 0x00400000;
101const sal_uInt32 AX_FLAGS_WORDWRAP = 0x00800000;
102const sal_uInt32 AX_FLAGS_BORDERSSUPPRESSED = 0x02000000;
103const sal_uInt32 AX_FLAGS_SELECTLINE = 0x04000000;
104const sal_uInt32 AX_FLAGS_SINGLECHARSELECT = 0x08000000;
105const sal_uInt32 AX_FLAGS_AUTOSIZE = 0x10000000;
106const sal_uInt32 AX_FLAGS_HIDESELECTION = 0x20000000;
107const sal_uInt32 AX_FLAGS_MAXLENAUTOTAB = 0x40000000;
108const sal_uInt32 AX_FLAGS_MULTILINE = 0x80000000;
109
110const sal_Int32 AX_BORDERSTYLE_NONE = 0;
111const sal_Int32 AX_BORDERSTYLE_SINGLE = 1;
112
113const sal_Int32 AX_SPECIALEFFECT_FLAT = 0;
114const sal_Int32 AX_SPECIALEFFECT_RAISED = 1;
115const sal_Int32 AX_SPECIALEFFECT_SUNKEN = 2;
116const sal_Int32 AX_SPECIALEFFECT_ETCHED = 3;
117const sal_Int32 AX_SPECIALEFFECT_BUMPED = 6;
118
119const sal_Int32 AX_PICSIZE_CLIP = 0;
120const sal_Int32 AX_PICSIZE_STRETCH = 1;
121const sal_Int32 AX_PICSIZE_ZOOM = 3;
122
123const sal_Int32 AX_PICALIGN_TOPLEFT = 0;
124const sal_Int32 AX_PICALIGN_TOPRIGHT = 1;
125const sal_Int32 AX_PICALIGN_CENTER = 2;
126const sal_Int32 AX_PICALIGN_BOTTOMLEFT = 3;
127const sal_Int32 AX_PICALIGN_BOTTOMRIGHT = 4;
128
129const sal_Int32 AX_DISPLAYSTYLE_TEXT = 1;
130const sal_Int32 AX_DISPLAYSTYLE_LISTBOX = 2;
131const sal_Int32 AX_DISPLAYSTYLE_COMBOBOX = 3;
132const sal_Int32 AX_DISPLAYSTYLE_CHECKBOX = 4;
133const sal_Int32 AX_DISPLAYSTYLE_OPTBUTTON = 5;
134const sal_Int32 AX_DISPLAYSTYLE_TOGGLE = 6;
135const sal_Int32 AX_DISPLAYSTYLE_DROPDOWN = 7;
136
137const sal_Int32 AX_SELECTION_SINGLE = 0;
138const sal_Int32 AX_SELECTION_MULTI = 1;
139const sal_Int32 AX_SELECTION_EXTENDED = 2;
140
141const sal_Int32 AX_SHOWDROPBUTTON_NEVER = 0;
142const sal_Int32 AX_SHOWDROPBUTTON_FOCUS = 1;
143const sal_Int32 AX_SHOWDROPBUTTON_ALWAYS = 2;
144
145const sal_Int32 AX_SCROLLBAR_NONE = 0x00;
146const sal_Int32 AX_SCROLLBAR_HORIZONTAL = 0x01;
147const sal_Int32 AX_SCROLLBAR_VERTICAL = 0x02;
148
149
152{
172
173
176{
178 Void,
179};
180
183{
188
189
194{
195public:
196 explicit ControlConverter(
197 const css::uno::Reference< css::frame::XModel >& rxDocModel,
198 const GraphicHelper& rGraphicHelper,
199 bool bDefaultColorBgr = true );
201
202 // Generic conversion -----------------------------------------------------
203
205 void convertPosition(
206 PropertyMap& rPropMap,
207 const AxPairData& rPos ) const;
208
210 void convertSize(
211 PropertyMap& rPropMap,
212 const AxPairData& rSize ) const;
213
215 void convertColor(
216 PropertyMap& rPropMap,
217 sal_Int32 nPropId,
218 sal_uInt32 nOleColor ) const;
219
220 static void convertToMSColor(
221 PropertySet const & rPropSet,
222 sal_Int32 nPropId,
223 sal_uInt32& nOleColor,
224 sal_uInt32 nDefault = 0 );
225
226
228 void convertPicture(
229 PropertyMap& rPropMap,
230 const StreamDataSequence& rPicData ) const;
231
233 static void convertOrientation(
234 PropertyMap& rPropMap,
235 bool bHorizontal );
236
237 static void convertToMSOrientation(
238 PropertySet const & rPropMap,
239 bool& bHorizontal );
240
242 static void convertVerticalAlign(
243 PropertyMap& rPropMap,
244 sal_Int32 nVerticalAlign );
245
247 static void convertScrollBar(
248 PropertyMap& rPropMap,
249 sal_Int32 nMin, sal_Int32 nMax, sal_Int32 nPosition,
250 sal_Int32 nSmallChange, sal_Int32 nLargeChange, bool bAwtModel );
251
253 void convertScrollabilitySettings(
254 PropertyMap& rPropMap,
255 const AxPairData& rScrollPos, const AxPairData& rScrollArea,
256 sal_Int32 nScrollBars ) const;
257
260 void bindToSources(
261 const css::uno::Reference< css::awt::XControlModel >& rxCtrlModel,
262 const OUString& rCtrlSource,
263 const OUString& rRowSource,
264 sal_Int32 nRefSheet = 0 ) const;
265
266 // ActiveX (Forms 2.0) specific conversion --------------------------------
267
269 void convertAxBackground(
270 PropertyMap& rPropMap,
271 sal_uInt32 nBackColor,
272 sal_uInt32 nFlags,
273 ApiTransparencyMode eTranspMode ) const;
274
276 void convertAxBorder(
277 PropertyMap& rPropMap,
278 sal_uInt32 nBorderColor,
279 sal_Int32 nBorderStyle,
280 sal_Int32 nSpecialEffect ) const;
281
282 static void convertToAxBorder(
283 PropertySet const & rPropSet,
284 sal_uInt32& nBorderColor,
285 sal_Int32& nBorderStyle,
286 sal_Int32& nSpecialEffect );
287
289 static void convertAxVisualEffect(
290 PropertyMap& rPropMap,
291 sal_Int32 nSpecialEffect );
292
293 static void convertToAxVisualEffect(
294 PropertySet const & rPropSet,
295 sal_Int32& nSpecialEffect );
296
299 void convertAxPicture(
300 PropertyMap& rPropMap,
301 const StreamDataSequence& rPicData,
302 sal_uInt32 nPicPos ) const;
303
306 void convertAxPicture(
307 PropertyMap& rPropMap,
308 const StreamDataSequence& rPicData,
309 sal_Int32 nPicSizeMode ) const;
310
313 static void convertAxState(
314 PropertyMap& rPropMap,
315 std::u16string_view rValue,
316 sal_Int32 nMultiSelect,
317 ApiDefaultStateMode eDefStateMode,
318 bool bAwtModel );
319
320 static void convertToAxState(
321 PropertySet const & rPropSet,
322 OUString& rValue,
323 sal_Int32& nMultiSelect,
324 ApiDefaultStateMode eDefStateMode );
325
327 static void convertAxOrientation(
328 PropertyMap& rPropMap,
329 const AxPairData& rSize,
330 sal_Int32 nOrientation );
331
332 static void convertToAxOrientation(
333 PropertySet const & rPropSet,
334 sal_Int32& nOrientation );
335
336private:
337 css::uno::Reference< css::frame::XModel > mxDocModel;
342};
343
344
347{
348public:
349 explicit ControlModelBase();
350 virtual ~ControlModelBase();
351
353 void setAwtModelMode() { mbAwtModel = true; }
355 void setFormComponentMode() { mbAwtModel = false; }
356
359 OUString getServiceName() const;
360
362 virtual void importProperty( sal_Int32 nPropId, const OUString& rValue );
364 virtual void importPictureData( sal_Int32 nPropId, BinaryInputStream& rInStrm );
366 virtual bool importBinaryModel( BinaryInputStream& rInStrm ) = 0;
368 virtual void exportBinaryModel( BinaryOutputStream& /*rOutStrm*/ ) {}
370 virtual void exportCompObj( BinaryOutputStream& /*rOutStrm*/ ) {}
372 virtual ApiControlType getControlType() const = 0;
374 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const;
376 virtual void convertFromProperties( PropertySet& rPropSet, const ControlConverter& rConv );
377
379 void convertSize( PropertyMap& rPropMap, const ControlConverter& rConv ) const;
380
381public: // direct access needed for legacy VML drawing controls
383
384protected:
386};
387
388typedef std::shared_ptr< ControlModelBase > ControlModelRef;
389
390
393{
394public:
395 explicit ComCtlModelBase(
396 sal_uInt32 nDataPartId5, sal_uInt32 nDataPartId6, sal_uInt16 nVersion );
397
398 virtual bool importBinaryModel( BinaryInputStream& rInStrm ) override;
399 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
400
401protected:
402 virtual void importControlData( BinaryInputStream& rInStrm ) = 0;
403
404private:
406 sal_uInt32 getDataPartId() const;
407
408 static bool readPartHeader( BinaryInputStream& rInStrm,
409 sal_uInt32 nExpPartId,
410 sal_uInt16 nExpMajor = SAL_MAX_UINT16,
411 sal_uInt16 nExpMinor = SAL_MAX_UINT16 );
412
413 bool importSizePart( BinaryInputStream& rInStrm );
414 bool importCommonPart( BinaryInputStream& rInStrm, sal_uInt32 nPartSize );
415 bool importComplexPart( BinaryInputStream& rInStrm );
416
417protected:
420 sal_uInt32 mnFlags;
421 const sal_uInt16 mnVersion;
422
423private:
424 sal_uInt32 mnDataPartId5;
425 sal_uInt32 mnDataPartId6;
428};
429
430
433{
434public:
435 explicit ComCtlScrollBarModel( sal_uInt16 nVersion );
436
437 virtual ApiControlType getControlType() const override;
438 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
439
440private:
441 virtual void importControlData( BinaryInputStream& rInStrm ) override;
442
443 sal_uInt32 mnScrollBarFlags;
444 sal_Int32 mnLargeChange;
445 sal_Int32 mnSmallChange;
446 sal_Int32 mnMin;
447 sal_Int32 mnMax;
448 sal_Int32 mnPosition;
449};
450
451
454{
455public:
456 explicit ComCtlProgressBarModel( sal_uInt16 nVersion );
457
458 virtual ApiControlType getControlType() const override;
459 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
460
461private:
462 virtual void importControlData( BinaryInputStream& rInStrm ) override;
463
464 float mfMin;
465 float mfMax;
466 sal_uInt16 mnVertical;
467 sal_uInt16 mnSmooth;
468};
469
470
473{
474public:
475 explicit AxControlModelBase();
476
477 virtual void importProperty( sal_Int32 nPropId, const OUString& rValue ) override;
478};
479
480
483{
484public:
485 explicit AxFontDataModel( bool bSupportsAlign = true );
486
487 virtual void importProperty( sal_Int32 nPropId, const OUString& rValue ) override;
488 virtual bool importBinaryModel( BinaryInputStream& rInStrm ) override;
489 virtual void exportBinaryModel( BinaryOutputStream& rOutStrm ) override;
490 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
491 virtual void convertFromProperties( PropertySet& rPropSet, const ControlConverter& rConv ) override;
492
494 sal_Int16 getFontHeight() const { return maFontData.getHeightPoints(); }
495
496public: // direct access needed for legacy VML drawing controls
498
499private:
501};
502
503
506{
507public:
508 explicit AxCommandButtonModel();
509
510 virtual void importProperty( sal_Int32 nPropId, const OUString& rValue ) override;
511 virtual void importPictureData( sal_Int32 nPropId, BinaryInputStream& rInStrm ) override;
512 virtual bool importBinaryModel( BinaryInputStream& rInStrm ) override;
513 virtual void exportBinaryModel( BinaryOutputStream& rOutStrm ) override;
514 virtual void exportCompObj( BinaryOutputStream& rOutStrm ) override;
515
516 virtual ApiControlType getControlType() const override;
517 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
518 virtual void convertFromProperties( PropertySet& rPropSet, const ControlConverter& rConv ) override;
519
520public: // direct access needed for legacy VML drawing controls
522 OUString maCaption;
523 sal_uInt32 mnTextColor;
524 sal_uInt32 mnBackColor;
525 sal_uInt32 mnFlags;
526 sal_uInt32 mnPicturePos;
527 sal_Int32 mnVerticalAlign;
529};
530
531
534{
535public:
536 explicit AxLabelModel();
537
538 virtual void importProperty( sal_Int32 nPropId, const OUString& rValue ) override;
539 virtual bool importBinaryModel( BinaryInputStream& rInStrm ) override;
540 virtual void exportBinaryModel( BinaryOutputStream& rOutStrm ) override;
541 virtual void exportCompObj( BinaryOutputStream& rOutStrm ) override;
542
543 virtual ApiControlType getControlType() const override;
544 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
545 virtual void convertFromProperties( PropertySet& rPropSet, const ControlConverter& rConv ) override;
546
547public: // direct access needed for legacy VML drawing controls
548 OUString maCaption;
549 sal_uInt32 mnTextColor;
550 sal_uInt32 mnBackColor;
551 sal_uInt32 mnFlags;
552 sal_uInt32 mnBorderColor;
553 sal_Int32 mnBorderStyle;
554 sal_Int32 mnSpecialEffect;
555 sal_Int32 mnVerticalAlign;
556};
557
558
561{
562public:
563 explicit AxImageModel();
564
565 virtual void importProperty( sal_Int32 nPropId, const OUString& rValue ) override;
566 virtual void importPictureData( sal_Int32 nPropId, BinaryInputStream& rInStrm ) override;
567 virtual bool importBinaryModel( BinaryInputStream& rInStrm ) override;
568 virtual void exportBinaryModel( BinaryOutputStream& rOutStrm ) override;
569 virtual void exportCompObj( BinaryOutputStream& rOutStrm ) override;
570
571 virtual ApiControlType getControlType() const override;
572 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
573
574private:
576 sal_uInt32 mnBackColor;
577 sal_uInt32 mnFlags;
578 sal_uInt32 mnBorderColor;
579 sal_Int32 mnBorderStyle;
580 sal_Int32 mnSpecialEffect;
581 sal_Int32 mnPicSizeMode;
582 sal_Int32 mnPicAlign;
584};
585
587{
588public:
589 explicit AxTabStripModel();
590
591 virtual bool importBinaryModel( BinaryInputStream& rInStrm ) override;
592
593 virtual ApiControlType getControlType() const override;
594
595public:
596 sal_uInt32 mnListIndex;
597 sal_uInt32 mnTabStyle;
598 sal_uInt32 mnTabData;
600 std::vector< OUString > maItems; // captions for each tab
601 std::vector< OUString > maTabNames; // names for each tab
602};
603
604
607{
608public:
609 explicit AxMorphDataModelBase();
610
611 virtual void importProperty( sal_Int32 nPropId, const OUString& rValue ) override;
612 virtual void importPictureData( sal_Int32 nPropId, BinaryInputStream& rInStrm ) override;
613 virtual bool importBinaryModel( BinaryInputStream& rInStrm ) override;
614 virtual void exportBinaryModel( BinaryOutputStream& rOutStrm ) override;
615 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
616 virtual void convertFromProperties( PropertySet& rPropSet, const ControlConverter& rConv ) override;
617
618public: // direct access needed for legacy VML drawing controls
620 OUString maCaption;
621 OUString maValue;
622 OUString maGroupName;
623 sal_uInt32 mnTextColor;
624 sal_uInt32 mnBackColor;
625 sal_uInt32 mnFlags;
626 sal_uInt32 mnPicturePos;
627 sal_uInt32 mnBorderColor;
628 sal_Int32 mnBorderStyle;
629 sal_Int32 mnSpecialEffect;
630 sal_Int32 mnDisplayStyle;
631 sal_Int32 mnMultiSelect;
632 sal_Int32 mnScrollBars;
633 sal_Int32 mnMatchEntry;
635 sal_Int32 mnMaxLength;
636 sal_Int32 mnPasswordChar;
637 sal_Int32 mnListRows;
638 sal_Int32 mnVerticalAlign;
639};
640
641
644{
645public:
646 explicit AxToggleButtonModel();
647
648 virtual ApiControlType getControlType() const override;
649 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
650 virtual void convertFromProperties( PropertySet& rPropSet, const ControlConverter& rConv ) override;
651 virtual void exportCompObj( BinaryOutputStream& rOutStrm ) override;
652};
653
654
657{
658public:
659 explicit AxCheckBoxModel();
660
661 virtual ApiControlType getControlType() const override;
662 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
663 virtual void convertFromProperties( PropertySet& rPropSet, const ControlConverter& rConv ) override;
664 virtual void exportCompObj( BinaryOutputStream& rOutStrm ) override;
665};
666
667
670{
671public:
672 explicit AxOptionButtonModel();
673
675 const OUString& getGroupName() const { return maGroupName; }
676
677 virtual ApiControlType getControlType() const override;
678 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
679 virtual void convertFromProperties( PropertySet& rPropSet, const ControlConverter& rConv ) override;
680 virtual void exportCompObj( BinaryOutputStream& rOutStrm ) override;
681};
682
683
686{
687public:
688 explicit AxTextBoxModel();
689
690 virtual ApiControlType getControlType() const override;
691 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
692 virtual void convertFromProperties( PropertySet& rPropSet, const ControlConverter& rConv ) override;
693 virtual void exportCompObj( BinaryOutputStream& rOutStrm ) override;
694};
695
696
699{
700public:
701 explicit AxNumericFieldModel();
702
703 virtual ApiControlType getControlType() const override;
704 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
705 virtual void convertFromProperties( PropertySet& rPropSet, const ControlConverter& rConv ) override;
706 virtual void exportCompObj( BinaryOutputStream& rOutStrm ) override;
707};
708
709
712{
713public:
714 explicit AxListBoxModel();
715
716 virtual ApiControlType getControlType() const override;
717 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
718 virtual void convertFromProperties( PropertySet& rPropSet, const ControlConverter& rConv ) override;
719 virtual void exportCompObj( BinaryOutputStream& rOutStrm ) override;
720};
721
722
725{
726public:
727 explicit AxComboBoxModel();
728
729 virtual ApiControlType getControlType() const override;
730 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
731 virtual void convertFromProperties( PropertySet& rPropSet, const ControlConverter& rConv ) override;
732 virtual void exportCompObj( BinaryOutputStream& rOutStrm ) override;
733};
734
735
738{
739public:
740 explicit AxSpinButtonModel();
741
742 virtual void importProperty( sal_Int32 nPropId, const OUString& rValue ) override;
743 virtual bool importBinaryModel( BinaryInputStream& rInStrm ) override;
744 virtual void exportBinaryModel( BinaryOutputStream& rOutStrm ) override;
745
746 virtual ApiControlType getControlType() const override;
747 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
748 virtual void convertFromProperties( PropertySet& rPropSet, const ControlConverter& rConv ) override;
749 virtual void exportCompObj( BinaryOutputStream& rOutStrm ) override;
750
751public: // direct access needed for legacy VML drawing controls
752 sal_uInt32 mnArrowColor;
753 sal_uInt32 mnBackColor;
754 sal_uInt32 mnFlags;
755 sal_Int32 mnOrientation;
756 sal_Int32 mnMin;
757 sal_Int32 mnMax;
758 sal_Int32 mnPosition;
759 sal_Int32 mnSmallChange;
760 sal_Int32 mnDelay;
761};
762
763
766{
767public:
768 explicit AxScrollBarModel();
769
770 virtual void importProperty( sal_Int32 nPropId, const OUString& rValue ) override;
771 virtual bool importBinaryModel( BinaryInputStream& rInStrm ) override;
772 virtual void exportBinaryModel( BinaryOutputStream& rOutStrm ) override;
773 virtual void exportCompObj( BinaryOutputStream& rOutStrm ) override;
774
775 virtual ApiControlType getControlType() const override;
776 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
777 virtual void convertFromProperties( PropertySet& rPropSet, const ControlConverter& rConv ) override;
778
779public: // direct access needed for legacy VML drawing controls
780 sal_uInt32 mnArrowColor;
781 sal_uInt32 mnBackColor;
782 sal_uInt32 mnFlags;
783 sal_Int32 mnOrientation;
784 sal_Int32 mnPropThumb;
785 sal_Int32 mnMin;
786 sal_Int32 mnMax;
787 sal_Int32 mnPosition;
788 sal_Int32 mnSmallChange;
789 sal_Int32 mnLargeChange;
790 sal_Int32 mnDelay;
791};
792
793
794typedef ::std::vector< OUString > AxClassTable;
795
798{
799public:
800 explicit AxContainerModelBase( bool bFontSupport = false );
801
803 virtual void importProperty( sal_Int32 nPropId, const OUString& rValue ) override;
806 virtual bool importBinaryModel( BinaryInputStream& rInStrm ) override;
808 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
809
812 bool importClassTable( BinaryInputStream& rInStrm, AxClassTable& orClassTable );
813
814public: // direct access needed for legacy VML drawing controls
816 OUString maCaption;
819 sal_uInt32 mnBackColor;
820 sal_uInt32 mnTextColor;
821 sal_uInt32 mnFlags;
822 sal_uInt32 mnBorderColor;
823 sal_Int32 mnBorderStyle;
824 sal_Int32 mnScrollBars;
825 sal_Int32 mnCycleType;
826 sal_Int32 mnSpecialEffect;
827 sal_Int32 mnPicAlign;
828 sal_Int32 mnPicSizeMode;
831};
832
833
836{
837public:
838 explicit AxFrameModel();
839
840 virtual ApiControlType getControlType() const override;
841 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
842};
843
845{
846public:
847 explicit AxPageModel();
848
849 virtual ApiControlType getControlType() const override;
850 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
851};
852
854{
855public:
856 explicit AxMultiPageModel();
857
858 virtual ApiControlType getControlType() const override;
859 void importPageAndMultiPageProperties( BinaryInputStream& rInStrm, sal_Int32 nPages );
860 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
861 std::vector<sal_uInt32> mnIDs;
862 sal_uInt32 mnActiveTab;
863 sal_uInt32 mnTabStyle;
864};
865
866
869{
870public:
871 explicit AxUserFormModel();
872
873 virtual ApiControlType getControlType() const override;
874 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
875};
876
877class HtmlSelectModel final : public AxListBoxModel
878{
879 css::uno::Sequence< OUString > msListData;
880 css::uno::Sequence< sal_Int16 > msIndices;
881public:
883 virtual bool importBinaryModel( BinaryInputStream& rInStrm ) override;
884 virtual void convertProperties( PropertyMap& rPropMap, const ControlConverter& rConv ) const override;
885};
886
888{
889public:
890 explicit HtmlTextBoxModel();
891 virtual bool importBinaryModel( BinaryInputStream& rInStrm ) override;
892};
893
894
898{
899public:
900 explicit EmbeddedControl( OUString aName );
901
903 template< typename ModelType >
904 inline ModelType& createModel();
905
907 template< typename ModelType, typename ParamType >
908 inline ModelType& createModel( const ParamType& rParam );
909
912 ControlModelBase* createModelFromGuid( std::u16string_view rClassId );
913
915 bool hasModel() const { return bool(mxModel); }
917 const ControlModelBase* getModel() const { return mxModel.get(); }
919 ControlModelBase* getModel() { return mxModel.get(); }
920
922 OUString getServiceName() const;
923
925 bool convertProperties(
926 const css::uno::Reference< css::awt::XControlModel >& rxCtrlModel,
927 const ControlConverter& rConv ) const;
928
929 void convertFromProperties(
930 const css::uno::Reference< css::awt::XControlModel >& rxCtrlModel,
931 const ControlConverter& rConv );
932
933private:
935 OUString maName;
936};
937
938
939template< typename ModelType >
941{
942 auto xModel = std::make_shared<ModelType>();
943 mxModel = xModel;
944 xModel->setFormComponentMode();
945 return *xModel;
946}
947
948template< typename ModelType, typename ParamType >
949inline ModelType& EmbeddedControl::createModel( const ParamType& rParam )
950{
951 auto xModel = std::make_shared<ModelType>( rParam );
952 mxModel = xModel;
953 xModel->setFormComponentMode();
954 return *xModel;
955}
956
957
960{
961public:
962 explicit EmbeddedForm(
963 const css::uno::Reference< css::frame::XModel >& rxDocModel,
964 const css::uno::Reference< css::drawing::XDrawPage >& rxDrawPage,
965 const GraphicHelper& rGraphicHelper );
966
969 css::uno::Reference< css::awt::XControlModel >
970 convertAndInsert( const EmbeddedControl& rControl, sal_Int32& rnCtrlIndex );
971
973 const css::uno::Reference< css::container::XIndexContainer >&
974 getXForm() const { return mxFormIC; }
975
976private:
978 css::uno::Reference< css::container::XIndexContainer > const &
979 createXForm();
980
981private:
983 css::uno::Reference< css::lang::XMultiServiceFactory > mxModelFactory;
984 css::uno::Reference< css::form::XFormsSupplier > mxFormsSupp;
985 css::uno::Reference< css::container::XIndexContainer > mxFormIC;
986};
987
988
989} // namespace oox::ole
990
991#endif
992
993/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
css::uno::Reference< css::frame::XModel2 > mxModel
ParamType
Interface for binary input stream classes.
Interface for binary output stream classes.
Provides helper functions for colors, device measurement conversion, graphics, and graphic objects ha...
A helper that maps property identifiers to property values.
Definition: propertymap.hxx:52
A wrapper for a UNO property set.
Definition: propertyset.hxx:58
Model for a Forms 2.0 check box.
Definition: axcontrol.hxx:657
Model for a Forms 2.0 combo box.
Definition: axcontrol.hxx:725
Model for a Forms 2.0 command button.
Definition: axcontrol.hxx:506
sal_uInt32 mnTextColor
Text color.
Definition: axcontrol.hxx:523
sal_uInt32 mnFlags
Various flags.
Definition: axcontrol.hxx:525
bool mbFocusOnClick
True = take focus on click.
Definition: axcontrol.hxx:528
OUString maCaption
Visible caption of the button.
Definition: axcontrol.hxx:522
sal_uInt32 mnBackColor
Fill color.
Definition: axcontrol.hxx:524
sal_Int32 mnVerticalAlign
Vertical alignment (legacy VML drawing controls only).
Definition: axcontrol.hxx:527
StreamDataSequence maPictureData
Binary picture stream.
Definition: axcontrol.hxx:521
sal_uInt32 mnPicturePos
Position of the picture relative to text.
Definition: axcontrol.hxx:526
Base class for ActiveX container controls.
Definition: axcontrol.hxx:798
OUString maCaption
Visible caption of the form.
Definition: axcontrol.hxx:816
sal_Int32 mnBorderStyle
Flat border style.
Definition: axcontrol.hxx:823
sal_Int32 mnPicSizeMode
Clip, stretch, zoom.
Definition: axcontrol.hxx:828
sal_uInt32 mnBorderColor
Flat border color.
Definition: axcontrol.hxx:822
sal_uInt32 mnBackColor
Fill color.
Definition: axcontrol.hxx:819
sal_uInt32 mnFlags
Various flags.
Definition: axcontrol.hxx:821
StreamDataSequence maPictureData
Binary picture stream.
Definition: axcontrol.hxx:815
sal_Int32 mnScrollBars
Horizontal/vertical scroll bar.
Definition: axcontrol.hxx:824
bool mbFontSupport
True = control supports the font property.
Definition: axcontrol.hxx:830
sal_Int32 mnCycleType
Cycle in all forms or in this form.
Definition: axcontrol.hxx:825
sal_Int32 mnPicAlign
Anchor position of the picture.
Definition: axcontrol.hxx:827
sal_uInt32 mnTextColor
Text color.
Definition: axcontrol.hxx:820
bool mbPicTiling
True = picture is repeated.
Definition: axcontrol.hxx:829
AxPairData maScrollPos
Scroll position.
Definition: axcontrol.hxx:818
sal_Int32 mnSpecialEffect
3D border effect.
Definition: axcontrol.hxx:826
AxPairData maLogicalSize
Logical form size (scroll area).
Definition: axcontrol.hxx:817
Base class for all models of Form 2.0 form controls.
Definition: axcontrol.hxx:473
Base class for Forms 2.0 controls supporting text formatting.
Definition: axcontrol.hxx:483
AxFontData maFontData
The font settings.
Definition: axcontrol.hxx:497
sal_Int16 getFontHeight() const
Returns the font height in points.
Definition: axcontrol.hxx:494
bool mbSupportsAlign
True = UNO model supports Align property.
Definition: axcontrol.hxx:500
Model for a Forms 2.0 frame control.
Definition: axcontrol.hxx:836
Model for a Forms 2.0 image.
Definition: axcontrol.hxx:561
sal_Int32 mnPicAlign
Anchor position of the picture.
Definition: axcontrol.hxx:582
sal_Int32 mnBorderStyle
Flat border style.
Definition: axcontrol.hxx:579
sal_Int32 mnPicSizeMode
Clip, stretch, zoom.
Definition: axcontrol.hxx:581
sal_uInt32 mnFlags
Various flags.
Definition: axcontrol.hxx:577
bool mbPicTiling
True = picture is repeated.
Definition: axcontrol.hxx:583
sal_uInt32 mnBackColor
Fill color.
Definition: axcontrol.hxx:576
sal_Int32 mnSpecialEffect
3D border effect.
Definition: axcontrol.hxx:580
sal_uInt32 mnBorderColor
Flat border color.
Definition: axcontrol.hxx:578
StreamDataSequence maPictureData
Binary picture stream.
Definition: axcontrol.hxx:575
Model for a Forms 2.0 label.
Definition: axcontrol.hxx:534
sal_Int32 mnSpecialEffect
3D border effect.
Definition: axcontrol.hxx:554
sal_uInt32 mnTextColor
Text color.
Definition: axcontrol.hxx:549
sal_uInt32 mnBackColor
Fill color.
Definition: axcontrol.hxx:550
OUString maCaption
Visible caption of the button.
Definition: axcontrol.hxx:548
sal_Int32 mnBorderStyle
Flat border style.
Definition: axcontrol.hxx:553
sal_uInt32 mnFlags
Various flags.
Definition: axcontrol.hxx:551
sal_uInt32 mnBorderColor
Flat border color.
Definition: axcontrol.hxx:552
sal_Int32 mnVerticalAlign
Vertical alignment (legacy VML drawing controls only).
Definition: axcontrol.hxx:555
Model for a Forms 2.0 list box.
Definition: axcontrol.hxx:712
Base class for a Forms 2.0 morph data control.
Definition: axcontrol.hxx:607
sal_Int32 mnVerticalAlign
Vertical alignment (legacy VML drawing controls only).
Definition: axcontrol.hxx:638
sal_Int32 mnListRows
Number of rows in dropdown box.
Definition: axcontrol.hxx:637
sal_Int32 mnMultiSelect
Selection mode.
Definition: axcontrol.hxx:631
sal_uInt32 mnFlags
Various flags.
Definition: axcontrol.hxx:625
sal_Int32 mnShowDropButton
When to show the dropdown button.
Definition: axcontrol.hxx:634
OUString maCaption
Visible caption of the button.
Definition: axcontrol.hxx:620
OUString maValue
Current value of the control.
Definition: axcontrol.hxx:621
sal_Int32 mnMaxLength
Maximum character count.
Definition: axcontrol.hxx:635
sal_uInt32 mnBackColor
Fill color.
Definition: axcontrol.hxx:624
sal_Int32 mnBorderStyle
Flat border style.
Definition: axcontrol.hxx:628
sal_Int32 mnMatchEntry
Auto completion mode.
Definition: axcontrol.hxx:633
sal_Int32 mnPasswordChar
Password character in edit fields.
Definition: axcontrol.hxx:636
OUString maGroupName
Group name for option buttons.
Definition: axcontrol.hxx:622
sal_uInt32 mnBorderColor
Flat border color.
Definition: axcontrol.hxx:627
sal_Int32 mnSpecialEffect
3D border effect.
Definition: axcontrol.hxx:629
sal_uInt32 mnPicturePos
Position of the picture relative to text.
Definition: axcontrol.hxx:626
sal_Int32 mnScrollBars
Horizontal/vertical scroll bar.
Definition: axcontrol.hxx:632
StreamDataSequence maPictureData
Binary picture stream.
Definition: axcontrol.hxx:619
sal_uInt32 mnTextColor
Text color.
Definition: axcontrol.hxx:623
sal_Int32 mnDisplayStyle
Type of the morph control.
Definition: axcontrol.hxx:630
std::vector< sal_uInt32 > mnIDs
Definition: axcontrol.hxx:861
Model for a numeric field (legacy drawing controls only).
Definition: axcontrol.hxx:699
Model for a Forms 2.0 option button.
Definition: axcontrol.hxx:670
const OUString & getGroupName() const
Returns the group name used to group several option buttons together.
Definition: axcontrol.hxx:675
Model for a Forms 2.0 scroll bar.
Definition: axcontrol.hxx:766
sal_Int32 mnMin
Minimum of the value range.
Definition: axcontrol.hxx:785
sal_uInt32 mnBackColor
Fill color.
Definition: axcontrol.hxx:781
sal_uInt32 mnArrowColor
Button arrow color.
Definition: axcontrol.hxx:780
sal_Int32 mnLargeChange
Increment step size (thumb).
Definition: axcontrol.hxx:789
sal_Int32 mnSmallChange
Increment step size (buttons).
Definition: axcontrol.hxx:788
sal_Int32 mnPropThumb
Proportional thumb size.
Definition: axcontrol.hxx:784
sal_Int32 mnDelay
Repeat delay in milliseconds.
Definition: axcontrol.hxx:790
sal_Int32 mnMax
Maximum of the value range.
Definition: axcontrol.hxx:786
sal_Int32 mnOrientation
Orientation of the buttons.
Definition: axcontrol.hxx:783
sal_Int32 mnPosition
Value of the spin button.
Definition: axcontrol.hxx:787
sal_uInt32 mnFlags
Various flags.
Definition: axcontrol.hxx:782
Model for a Forms 2.0 spin button.
Definition: axcontrol.hxx:738
sal_uInt32 mnBackColor
Fill color.
Definition: axcontrol.hxx:753
sal_Int32 mnDelay
Repeat delay in milliseconds.
Definition: axcontrol.hxx:760
sal_Int32 mnOrientation
Orientation of the buttons.
Definition: axcontrol.hxx:755
sal_uInt32 mnFlags
Various flags.
Definition: axcontrol.hxx:754
sal_Int32 mnPosition
Value of the spin button.
Definition: axcontrol.hxx:758
sal_Int32 mnSmallChange
Increment step size.
Definition: axcontrol.hxx:759
sal_Int32 mnMax
Maximum of the value range.
Definition: axcontrol.hxx:757
sal_Int32 mnMin
Minimum of the value range.
Definition: axcontrol.hxx:756
sal_uInt32 mnArrowColor
Button arrow color.
Definition: axcontrol.hxx:752
std::vector< OUString > maItems
Definition: axcontrol.hxx:600
std::vector< OUString > maTabNames
Definition: axcontrol.hxx:601
sal_uInt32 mnVariousPropertyBits
Definition: axcontrol.hxx:599
Model for a Forms 2.0 text box.
Definition: axcontrol.hxx:686
Model for a Forms 2.0 toggle button.
Definition: axcontrol.hxx:644
Model for a Forms 2.0 user form.
Definition: axcontrol.hxx:869
Base class for all models of ComCtl form controls.
Definition: axcontrol.hxx:393
StreamDataSequence maMouseIcon
Binary picture stream for mouse icon.
Definition: axcontrol.hxx:419
bool importSizePart(BinaryInputStream &rInStrm)
Definition: axcontrol.cxx:720
virtual bool importBinaryModel(BinaryInputStream &rInStrm) override
Derived classes import a form control model from the passed input stream.
Definition: axcontrol.cxx:667
sal_uInt32 mnFlags
Common flags for ComCtl controls.
Definition: axcontrol.hxx:420
sal_uInt32 mnDataPartId6
Identifier for version 6.0 control data.
Definition: axcontrol.hxx:425
const sal_uInt16 mnVersion
Current version of the ComCtl control model.
Definition: axcontrol.hxx:421
sal_uInt32 getDataPartId() const
Returns the data part identifier according to the model version.
Definition: axcontrol.cxx:696
virtual void convertProperties(PropertyMap &rPropMap, const ControlConverter &rConv) const override
Derived classes convert all control properties.
Definition: axcontrol.cxx:689
bool importComplexPart(BinaryInputStream &rInStrm)
Definition: axcontrol.cxx:744
bool mbCommonPart
True = the COMCTL_COMMONDATA part exists.
Definition: axcontrol.hxx:426
StdFontInfo maFontData
Font formatting.
Definition: axcontrol.hxx:418
sal_uInt32 mnDataPartId5
Identifier for version 5.0 control data.
Definition: axcontrol.hxx:424
bool importCommonPart(BinaryInputStream &rInStrm, sal_uInt32 nPartSize)
Definition: axcontrol.cxx:731
static bool readPartHeader(BinaryInputStream &rInStrm, sal_uInt32 nExpPartId, sal_uInt16 nExpMajor=SAL_MAX_UINT16, sal_uInt16 nExpMinor=SAL_MAX_UINT16)
Definition: axcontrol.cxx:707
bool mbComplexPart
True = the COMCTL_COMPLEXDATA part exists.
Definition: axcontrol.hxx:427
ComCtlModelBase(sal_uInt32 nDataPartId5, sal_uInt32 nDataPartId6, sal_uInt16 nVersion)
Definition: axcontrol.cxx:655
virtual void importControlData(BinaryInputStream &rInStrm)=0
Model for a ComCtl progress bar.
Definition: axcontrol.hxx:454
virtual void importControlData(BinaryInputStream &rInStrm) override
Definition: axcontrol.cxx:816
virtual ApiControlType getControlType() const override
Derived classes return the UNO control type enum value.
Definition: axcontrol.cxx:800
float mfMax
Maximum of the value range.
Definition: axcontrol.hxx:465
sal_uInt16 mnVertical
0 = horizontal, 1 = vertical.
Definition: axcontrol.hxx:466
ComCtlProgressBarModel(sal_uInt16 nVersion)
Definition: axcontrol.cxx:791
float mfMin
Minimum of the value range.
Definition: axcontrol.hxx:464
sal_uInt16 mnSmooth
0 = progress blocks, 1 = pixel resolution.
Definition: axcontrol.hxx:467
virtual void convertProperties(PropertyMap &rPropMap, const ControlConverter &rConv) const override
Derived classes convert all control properties.
Definition: axcontrol.cxx:805
Model for a ComCtl scroll bar.
Definition: axcontrol.hxx:433
virtual void convertProperties(PropertyMap &rPropMap, const ControlConverter &rConv) const override
Derived classes convert all control properties.
Definition: axcontrol.cxx:773
sal_Int32 mnLargeChange
Increment step size (thumb).
Definition: axcontrol.hxx:444
sal_uInt32 mnScrollBarFlags
Special flags for scroll bar model.
Definition: axcontrol.hxx:443
sal_Int32 mnSmallChange
Increment step size (buttons).
Definition: axcontrol.hxx:445
ComCtlScrollBarModel(sal_uInt16 nVersion)
Definition: axcontrol.cxx:757
sal_Int32 mnMax
Maximum of the value range.
Definition: axcontrol.hxx:447
sal_Int32 mnMin
Minimum of the value range.
Definition: axcontrol.hxx:446
virtual ApiControlType getControlType() const override
Derived classes return the UNO control type enum value.
Definition: axcontrol.cxx:768
virtual void importControlData(BinaryInputStream &rInStrm) override
Definition: axcontrol.cxx:781
sal_Int32 mnPosition
Value of the spin button.
Definition: axcontrol.hxx:448
A base class with useful helper functions for something that is able to convert ActiveX and ComCtl fo...
Definition: axcontrol.hxx:194
css::uno::Reference< css::frame::XModel > mxDocModel
Definition: axcontrol.hxx:337
PropertySet maAddressConverter
Definition: axcontrol.hxx:339
const GraphicHelper & mrGraphicHelper
Definition: axcontrol.hxx:338
Base class for all models of form controls.
Definition: axcontrol.hxx:347
void setAwtModelMode()
Sets this control model to AWT model mode.
Definition: axcontrol.hxx:353
virtual void exportCompObj(BinaryOutputStream &)
Derived classes export CompObjStream contents.
Definition: axcontrol.hxx:370
bool mbAwtModel
True = AWT control model, false = form component.
Definition: axcontrol.hxx:385
void setFormComponentMode()
Sets this control model to form component mode.
Definition: axcontrol.hxx:355
AxPairData maSize
Size of the control in 1/100 mm.
Definition: axcontrol.hxx:382
virtual void exportBinaryModel(BinaryOutputStream &)
Derived classes export a form control model to the passed output stream.
Definition: axcontrol.hxx:368
virtual bool importBinaryModel(BinaryInputStream &rInStrm)=0
Derived classes import a form control model from the passed input stream.
virtual ApiControlType getControlType() const =0
Derived classes return the UNO control type enum value.
A form control embedded in a document draw page.
Definition: axcontrol.hxx:898
const ControlModelBase * getModel() const
Returns read-only access to the internal control model.
Definition: axcontrol.hxx:917
ControlModelRef mxModel
Control model containing the properties.
Definition: axcontrol.hxx:934
ModelType & createModel()
Creates and returns the internal control model of the specified type.
Definition: axcontrol.hxx:940
OUString maName
Name of the control.
Definition: axcontrol.hxx:935
bool hasModel() const
Returns true, if the internal control model exists.
Definition: axcontrol.hxx:915
ControlModelBase * getModel()
Returns read/write access to the internal control model.
Definition: axcontrol.hxx:919
A wrapper for a control form embedded directly in a draw page.
Definition: axcontrol.hxx:960
EmbeddedForm(const css::uno::Reference< css::frame::XModel > &rxDocModel, const css::uno::Reference< css::drawing::XDrawPage > &rxDrawPage, const GraphicHelper &rGraphicHelper)
Definition: axcontrol.cxx:2722
css::uno::Reference< css::awt::XControlModel > convertAndInsert(const EmbeddedControl &rControl, sal_Int32 &rnCtrlIndex)
Converts the passed control and inserts the control model into the form.
Definition: axcontrol.cxx:2731
css::uno::Reference< css::lang::XMultiServiceFactory > mxModelFactory
Definition: axcontrol.hxx:983
css::uno::Reference< css::container::XIndexContainer > const & createXForm()
Creates the form that will hold the form controls.
Definition: axcontrol.cxx:2756
const css::uno::Reference< css::container::XIndexContainer > & getXForm() const
Returns the XIndexContainer interface of the UNO control form, if existing.
Definition: axcontrol.hxx:974
ControlConverter maControlConv
Definition: axcontrol.hxx:982
css::uno::Reference< css::container::XIndexContainer > mxFormIC
Definition: axcontrol.hxx:985
css::uno::Reference< css::form::XFormsSupplier > mxFormsSupp
Definition: axcontrol.hxx:984
css::uno::Sequence< sal_Int16 > msIndices
Definition: axcontrol.hxx:880
css::uno::Sequence< OUString > msListData
Definition: axcontrol.hxx:879
virtual bool importBinaryModel(BinaryInputStream &rInStrm) override
Derived classes import a form control model from the passed input stream.
Definition: axcontrol.cxx:2567
virtual void convertProperties(PropertyMap &rPropMap, const ControlConverter &rConv) const override
Derived classes convert all control properties.
Definition: axcontrol.cxx:2632
virtual bool importBinaryModel(BinaryInputStream &rInStrm) override
Derived classes import a form control model from the passed input stream.
Definition: axcontrol.cxx:2645
#define OOX_DLLPUBLIC
Definition: dllapi.h:28
sal_Int16 nVersion
OUString aName
const sal_uInt32 AX_FLAGS_AUTOSIZE
Definition: axcontrol.hxx:105
const sal_uInt32 AX_FLAGS_TABASCHARACTER
Definition: axcontrol.hxx:100
const sal_Int32 AX_BORDERSTYLE_SINGLE
Definition: axcontrol.hxx:111
const sal_uInt32 AX_SYSCOLOR_WINDOWFRAME
Definition: axcontrol.hxx:83
const sal_uInt32 AX_SYSCOLOR_WINDOWTEXT
Definition: axcontrol.hxx:84
const sal_uInt32 AX_FLAGS_SELECTLINE
Definition: axcontrol.hxx:103
const sal_uInt32 AX_FLAGS_CAPTIONLEFT
Definition: axcontrol.hxx:94
const sal_Int32 AX_DISPLAYSTYLE_TOGGLE
Definition: axcontrol.hxx:134
const sal_uInt32 AX_FLAGS_DRAGENABLED
Definition: axcontrol.hxx:97
const sal_Int32 AX_DISPLAYSTYLE_TEXT
Definition: axcontrol.hxx:129
const sal_Int32 AX_SELECTION_SINGLE
Definition: axcontrol.hxx:137
const sal_Int32 AX_DISPLAYSTYLE_LISTBOX
Definition: axcontrol.hxx:130
const sal_uInt32 AX_FLAGS_EDITABLE
Definition: axcontrol.hxx:95
const sal_Int32 AX_DISPLAYSTYLE_DROPDOWN
Definition: axcontrol.hxx:135
const sal_Int32 AX_SPECIALEFFECT_BUMPED
Definition: axcontrol.hxx:117
const sal_Int32 AX_SPECIALEFFECT_SUNKEN
Definition: axcontrol.hxx:115
const sal_uInt32 AX_FLAGS_ENABLED
Definition: axcontrol.hxx:88
const sal_uInt32 AX_FLAGS_OPAQUE
Definition: axcontrol.hxx:90
const sal_Int32 AX_PICSIZE_CLIP
Definition: axcontrol.hxx:119
const sal_uInt32 AX_FLAGS_IMEMODE_MASK
Definition: axcontrol.hxx:96
ApiDefaultStateMode
Specifies how a form control supports the DefaultState property.
Definition: axcontrol.hxx:183
@ API_DEFAULTSTATE_BOOLEAN
Control does not support tri-state, state is given as boolean.
Definition: axcontrol.hxx:184
@ API_DEFAULTSTATE_TRISTATE
Control supports tri-state, state is given as short.
Definition: axcontrol.hxx:186
@ API_DEFAULTSTATE_SHORT
Control does not support tri-state, state is given as short.
Definition: axcontrol.hxx:185
const sal_Int32 AX_BORDERSTYLE_NONE
Definition: axcontrol.hxx:110
const sal_Int32 AX_PICALIGN_BOTTOMRIGHT
Definition: axcontrol.hxx:127
const sal_uInt32 AX_SYSCOLOR_WINDOWBACK
Definition: axcontrol.hxx:82
const sal_uInt32 AX_FLAGS_SINGLECHARSELECT
Definition: axcontrol.hxx:104
const sal_uInt32 AX_FLAGS_KEEPSELECTION
Definition: axcontrol.hxx:99
const sal_uInt32 AX_SYSCOLOR_BUTTONFACE
Definition: axcontrol.hxx:85
const sal_Int32 AX_SHOWDROPBUTTON_NEVER
Definition: axcontrol.hxx:141
const sal_uInt32 AX_FLAGS_MULTILINE
Definition: axcontrol.hxx:108
const sal_Int32 AX_PICALIGN_BOTTOMLEFT
Definition: axcontrol.hxx:126
const sal_uInt32 AX_FLAGS_EXISTINGENTRIES
Definition: axcontrol.hxx:93
const sal_Int32 AX_SCROLLBAR_HORIZONTAL
Definition: axcontrol.hxx:146
::std::pair< sal_Int32, sal_Int32 > AxPairData
A pair of integer values as a property.
ApiControlType
Enumerates all UNO API control types supported by these filters.
Definition: axcontrol.hxx:152
@ API_CONTROL_PAGE
Definition: axcontrol.hxx:168
@ API_CONTROL_TABSTRIP
Definition: axcontrol.hxx:164
@ API_CONTROL_RADIOBUTTON
Definition: axcontrol.hxx:157
@ API_CONTROL_COMBOBOX
Definition: axcontrol.hxx:161
@ API_CONTROL_FRAME
Definition: axcontrol.hxx:167
@ API_CONTROL_SCROLLBAR
Definition: axcontrol.hxx:163
@ API_CONTROL_LISTBOX
Definition: axcontrol.hxx:160
@ API_CONTROL_NUMERIC
Definition: axcontrol.hxx:159
@ API_CONTROL_BUTTON
Definition: axcontrol.hxx:153
@ API_CONTROL_IMAGE
Definition: axcontrol.hxx:155
@ API_CONTROL_CHECKBOX
Definition: axcontrol.hxx:156
@ API_CONTROL_MULTIPAGE
Definition: axcontrol.hxx:169
@ API_CONTROL_DIALOG
Definition: axcontrol.hxx:170
@ API_CONTROL_GROUPBOX
Definition: axcontrol.hxx:166
@ API_CONTROL_FIXEDTEXT
Definition: axcontrol.hxx:154
@ API_CONTROL_SPINBUTTON
Definition: axcontrol.hxx:162
@ API_CONTROL_PROGRESSBAR
Definition: axcontrol.hxx:165
@ API_CONTROL_EDIT
Definition: axcontrol.hxx:158
const sal_Int32 AX_SCROLLBAR_VERTICAL
Definition: axcontrol.hxx:147
const sal_Int32 AX_SPECIALEFFECT_RAISED
Definition: axcontrol.hxx:114
const sal_Int32 AX_PICSIZE_STRETCH
Definition: axcontrol.hxx:120
const sal_Int32 AX_DISPLAYSTYLE_COMBOBOX
Definition: axcontrol.hxx:131
const sal_Int32 AX_SELECTION_MULTI
Definition: axcontrol.hxx:138
const sal_uInt16 COMCTL_VERSION_60
Definition: axcontrol.hxx:61
const sal_Int32 AX_SPECIALEFFECT_ETCHED
Definition: axcontrol.hxx:116
const sal_Int32 AX_SCROLLBAR_NONE
Definition: axcontrol.hxx:145
const sal_uInt32 AX_FLAGS_BORDERSSUPPRESSED
Definition: axcontrol.hxx:102
const sal_uInt16 COMCTL_VERSION_50
Definition: axcontrol.hxx:60
const sal_uInt32 AX_FLAGS_HIDESELECTION
Definition: axcontrol.hxx:106
const sal_Int32 AX_SHOWDROPBUTTON_ALWAYS
Definition: axcontrol.hxx:143
const sal_Int32 AX_SPECIALEFFECT_FLAT
Definition: axcontrol.hxx:113
std::shared_ptr< ControlModelBase > ControlModelRef
Definition: axcontrol.hxx:388
ApiTransparencyMode
Specifies how a form control supports transparent background.
Definition: axcontrol.hxx:176
const sal_Int32 AX_DISPLAYSTYLE_OPTBUTTON
Definition: axcontrol.hxx:133
const sal_Int32 AX_PICALIGN_TOPRIGHT
Definition: axcontrol.hxx:124
const sal_uInt32 AX_FLAGS_LOCKED
Definition: axcontrol.hxx:89
const sal_Int32 AX_SHOWDROPBUTTON_FOCUS
Definition: axcontrol.hxx:142
const sal_Int32 AX_SELECTION_EXTENDED
Definition: axcontrol.hxx:139
::std::vector< OUString > AxClassTable
Definition: axcontrol.hxx:794
const sal_uInt32 AX_FLAGS_WORDWRAP
Definition: axcontrol.hxx:101
const sal_Int32 AX_PICALIGN_TOPLEFT
Definition: axcontrol.hxx:123
const sal_uInt32 AX_FLAGS_ENTERASNEWLINE
Definition: axcontrol.hxx:98
const sal_Int32 AX_PICALIGN_CENTER
Definition: axcontrol.hxx:125
const sal_Int32 AX_PICSIZE_ZOOM
Definition: axcontrol.hxx:121
const sal_uInt32 AX_FLAGS_COLUMNHEADS
Definition: axcontrol.hxx:91
const sal_uInt32 AX_FLAGS_MAXLENAUTOTAB
Definition: axcontrol.hxx:107
const sal_uInt32 AX_SYSCOLOR_BUTTONTEXT
Definition: axcontrol.hxx:86
const sal_Int32 AX_DISPLAYSTYLE_CHECKBOX
Definition: axcontrol.hxx:132
const sal_uInt32 AX_FLAGS_ENTIREROWS
Definition: axcontrol.hxx:92
css::uno::Sequence< sal_Int8 > StreamDataSequence
std::map< sal_Int32, STLPropertyMapEntry > PropertyMap
All entries of a font property.
Definition: axfontdata.hxx:54
Stores data about a StdFont font structure.
Definition: olehelper.hxx:69
Reference< XModel > xModel