LibreOffice Module sw (master) 1
docufld.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#ifndef INCLUDED_SW_INC_DOCUFLD_HXX
20#define INCLUDED_SW_INC_DOCUFLD_HXX
21
22#include <sal/config.h>
23
24#include <string_view>
25
26#include <editeng/outlobj.hxx>
27#include <tools/solar.h>
28#include <tools/date.hxx>
29#include <tools/datetime.hxx>
30#include <rtl/ref.hxx>
31#include <svl/macitem.hxx>
32
33#include "fldbas.hxx"
34
35class SetGetExpFields;
36class SwTextField;
37class SwFrame;
39class SwTextAPIObject;
40class SwCharFormat;
41
43{
47 AF_FIXED = 0x8000
48};
49
50// Subtype of document statistics.
52{
61};
62
63typedef sal_uInt16 SwDocInfoSubType;
65{
82
88}
89
91{
95};
96
97// NOTE: Possibly the first 15 values in the below enum are required
98// to exactly match the published constants in css::text::UserDataPart
99// (see offapi/com/sun/star/text/UserDataPart.idl).
100
102{
121
123{
130
131class SAL_DLLPUBLIC_RTTI SwPageNumberFieldType final : public SwFieldType
132{
135
136public:
138
139 OUString Expand( SvxNumType nFormat, short nOff, sal_uInt16 const nPageNumber,
140 sal_uInt16 const nMaxPage, const OUString&, LanguageType = LANGUAGE_NONE ) const;
141 void ChangeExpansion( SwDoc* pDoc,
142 bool bVirtPageNum, const SvxNumType* pNumFormat );
143 virtual std::unique_ptr<SwFieldType> Copy() const override;
144};
145
146// Page numbering.
148{
149 OUString m_sUserStr;
150 sal_uInt16 m_nSubType;
152 // fdo#58074 store page number in SwField, not SwFieldType
153 sal_uInt16 m_nPageNumber;
154 sal_uInt16 m_nMaxPage;
155
156public:
158 sal_uInt32 nFormat, short nOff = 0,
159 sal_uInt16 const nPageNumber = 0,
160 sal_uInt16 const nMaxPage = 0);
161
162 void ChangeExpansion(sal_uInt16 const nPageNumber,
163 sal_uInt16 const nMaxPage);
164
165 virtual OUString ExpandImpl(SwRootFrame const* pLayout) const override;
166 virtual std::unique_ptr<SwField> Copy() const override;
167
168 virtual OUString GetPar2() const override;
169 virtual void SetPar2(const OUString& rStr) override;
170
171 virtual sal_uInt16 GetSubType() const override;
172 virtual bool QueryValue( css::uno::Any& rVal, sal_uInt16 nWhich ) const override;
173 virtual bool PutValue( const css::uno::Any& rVal, sal_uInt16 nWhich ) override;
174
175 const OUString& GetUserString() const { return m_sUserStr; }
176 void SetUserString( const OUString& rS ) { m_sUserStr = rS; }
177};
178
179class SwAuthorFieldType final : public SwFieldType
180{
181public:
183
184 static OUString Expand(sal_uLong);
185 virtual std::unique_ptr<SwFieldType> Copy() const override;
186};
187
188class SwAuthorField final : public SwField
189{
190 OUString m_aContent;
191
192public:
193 SwAuthorField(SwAuthorFieldType*, sal_uInt32 nFormat);
194
195 virtual OUString ExpandImpl(SwRootFrame const* pLayout) const override;
196 virtual std::unique_ptr<SwField> Copy() const override;
197
198 void SetExpansion(const OUString& rStr) { m_aContent = rStr; }
199
200 virtual bool QueryValue( css::uno::Any& rVal, sal_uInt16 nWhich ) const override;
201 virtual bool PutValue( const css::uno::Any& rVal, sal_uInt16 nWhich ) override;
202};
203
204class SAL_DLLPUBLIC_RTTI SwFileNameFieldType final : public SwFieldType
205{
207public:
209
210 OUString Expand(sal_uLong) const;
211 virtual std::unique_ptr<SwFieldType> Copy() const override;
212};
213
215{
216 OUString m_aContent;
217
218public:
219 SwFileNameField(SwFileNameFieldType*, sal_uInt32 nFormat);
220
221 virtual OUString ExpandImpl(SwRootFrame const* pLayout) const override;
222 virtual std::unique_ptr<SwField> Copy() const override;
223
224 void SetExpansion(const OUString& rStr) { m_aContent = rStr; }
225
226 virtual bool QueryValue( css::uno::Any& rVal, sal_uInt16 nWhich ) const override;
227 virtual bool PutValue( const css::uno::Any& rVal, sal_uInt16 nWhich ) override;
228};
229
230class SAL_DLLPUBLIC_RTTI SwTemplNameFieldType final : public SwFieldType
231{
233public:
235
236 OUString Expand(sal_uLong) const;
237 virtual std::unique_ptr<SwFieldType> Copy() const override;
238};
239
241{
242public:
243 SwTemplNameField(SwTemplNameFieldType*, sal_uInt32 nFormat);
244
245 virtual OUString ExpandImpl(SwRootFrame const* pLayout) const override;
246 virtual std::unique_ptr<SwField> Copy() const override;
247 virtual bool QueryValue( css::uno::Any& rVal, sal_uInt16 nWhich ) const override;
248 virtual bool PutValue( const css::uno::Any& rVal, sal_uInt16 nWhich ) override;
249};
250
251// Document statistics
252class SAL_DLLPUBLIC_RTTI SwDocStatFieldType final : public SwFieldType
253{
256
257public:
259 OUString Expand(sal_uInt16 nSubType, SvxNumType nFormat) const;
260 virtual std::unique_ptr<SwFieldType> Copy() const override;
261
262 void SetNumFormat( SvxNumType eFormat ) { m_nNumberingType = eFormat; }
263};
264
266{
267 sal_uInt16 m_nSubType;
268
269public:
271 sal_uInt16 nSubType, sal_uInt32 nFormat);
272
273 void ChangeExpansion( const SwFrame* pFrame );
274
275 virtual OUString ExpandImpl(SwRootFrame const* pLayout) const override;
276 virtual std::unique_ptr<SwField> Copy() const override;
277
278 virtual sal_uInt16 GetSubType() const override;
279 virtual void SetSubType(sal_uInt16 nSub) override;
280 virtual bool QueryValue( css::uno::Any& rVal, sal_uInt16 nWhich ) const override;
281 virtual bool PutValue( const css::uno::Any& rVal, sal_uInt16 nWhich ) override;
282};
283
284class SAL_DLLPUBLIC_RTTI SwHiddenTextFieldType final : public SwFieldType
285{
287public:
288 SwHiddenTextFieldType(bool bSetHidden = true);
289
290 virtual std::unique_ptr<SwFieldType> Copy() const override;
291 virtual void UpdateFields() override {};
292
293 void SetHiddenFlag( bool bSetHidden );
294 bool GetHiddenFlag() const { return m_bHidden; }
295};
296
298{
299 OUString m_aTRUEText;
300 OUString m_aFALSEText;
301 OUString m_aContent;
302
303 OUString m_aCond;
305
306 bool m_bCanToggle : 1;
307 bool m_bIsHidden : 1;
308 bool m_bValid : 1;
309
310 virtual OUString ExpandImpl(SwRootFrame const* pLayout) const override;
311 virtual std::unique_ptr<SwField> Copy() const override;
312
313public:
315 bool bConditional,
316 OUString aCond,
317 const OUString& rText,
318 bool bHidden,
320
322 OUString aCond,
323 OUString aTrue,
324 OUString aFalse,
326
327 virtual OUString GetFieldName() const override;
328
329 void Evaluate(SwDoc& rDoc);
330
331 void SetValue(bool bHidden) { m_bIsHidden = bHidden; }
332 static OUString GetColumnName(const OUString& rName);
333 static OUString GetDBName(std::u16string_view rName, SwDoc& rDoc);
334
336 virtual void SetPar1(const OUString& rStr) override;
337 virtual OUString GetPar1() const override;
338
340 virtual void SetPar2(const OUString& rStr) override;
341 virtual OUString GetPar2() const override;
342
343 virtual sal_uInt16 GetSubType() const override;
344
345 virtual bool QueryValue( css::uno::Any& rVal, sal_uInt16 nWhich ) const override;
346 virtual bool PutValue( const css::uno::Any& rVal, sal_uInt16 nWhich ) override;
347
348 static void ParseIfFieldDefinition(std::u16string_view aFieldDefinition,
349 OUString& rCondition,
350 OUString& rTrue,
351 OUString& rFalse);
352};
353
354// Field that expands to an empty line (without height).
356{
357public:
359
360 virtual std::unique_ptr<SwFieldType> Copy() const override;
361 virtual void UpdateFields() override {};
362};
363
364class SwHiddenParaField final : public SwField
365{
366 OUString m_aCond;
368public:
371
372 virtual OUString ExpandImpl(SwRootFrame const* pLayout) const override;
373 virtual std::unique_ptr<SwField> Copy() const override;
374
375 void SetHidden(bool bHidden) { m_bIsHidden = bHidden; }
376 bool IsHidden() const { return m_bIsHidden; }
377
379 virtual OUString GetPar1() const override;
380 virtual void SetPar1(const OUString& rStr) override;
381 virtual bool QueryValue( css::uno::Any& rVal, sal_uInt16 nWhich ) const override;
382 virtual bool PutValue( const css::uno::Any& rVal, sal_uInt16 nWhich ) override;
383};
384
385class SAL_DLLPUBLIC_RTTI SwMacroFieldType final : public SwFieldType
386{
388
389public:
391
392 virtual std::unique_ptr<SwFieldType> Copy() const override;
393};
394
396{
397 OUString m_aMacro;
398 OUString m_aText;
400
401 virtual OUString ExpandImpl(SwRootFrame const* pLayout) const override;
402 virtual std::unique_ptr<SwField> Copy() const override;
403
404public:
406 SwMacroField( SwMacroFieldType*, OUString aLibAndName,
407 OUString aText);
408
409 const OUString& GetMacro() const { return m_aMacro; }
410 OUString GetLibName() const;
411 OUString GetMacroName() const;
412 SvxMacro GetSvxMacro() const;
413
414 virtual OUString GetFieldName() const override;
415
417 virtual OUString GetPar1() const override;
418 virtual void SetPar1(const OUString& rStr) override;
419
421 virtual OUString GetPar2() const override;
422 virtual void SetPar2(const OUString& rStr) override;
423 virtual bool QueryValue( css::uno::Any& rVal, sal_uInt16 nWhich ) const override;
424 virtual bool PutValue( const css::uno::Any& rVal, sal_uInt16 nWhich ) override;
425
426 static void CreateMacroString( OUString& rMacro,
427 std::u16string_view rMacroName,
428 const OUString& rLibraryName );
429
430 static bool isScriptURL( const OUString& str );
431};
432
433class SAL_DLLPUBLIC_RTTI SwPostItFieldType final : public SwFieldType
434{
435private:
437public:
439
440 virtual std::unique_ptr<SwFieldType> Copy() const override;
441
442 SwDoc& GetDoc() const
443 {
444 return mrDoc;
445 };
446};
447
449{
450 OUString m_sText;
451 OUString m_sAuthor;
452 OUString m_sInitials;
453 OUString m_sName;
458 sal_uInt32 m_nPostItId;
459 sal_uInt32 m_nParentId;
460 sal_uInt32 m_nParaId;
461
462public:
463 static sal_uInt32 s_nLastPostItId;
464
466 OUString aAuthor,
467 OUString aText,
468 OUString aInitials,
469 OUString aName,
470 const DateTime& rDate,
471 const bool bResolved = false,
472 const sal_uInt32 nPostItId = 0,
473 const sal_uInt32 nParentId = 0,
474 const sal_uInt32 nParaId = 0);
475
476 SwPostItField(const SwPostItField&) = delete;
478
479 virtual ~SwPostItField() override;
480
481 virtual OUString ExpandImpl(SwRootFrame const* pLayout) const override;
482 virtual std::unique_ptr<SwField> Copy() const override;
483
484 const DateTime& GetDateTime() const { return m_aDateTime; }
485 Date GetDate() const { return Date(m_aDateTime.GetDate()); }
486 tools::Time GetTime() const { return tools::Time(m_aDateTime.GetTime()); }
487 sal_uInt32 GetPostItId() const { return m_nPostItId; }
488 void SetPostItId(const sal_uInt32 nPostItId = 0);
489 sal_uInt32 GetParentId() const { return m_nParentId; }
490 void SetParentId(const sal_uInt32 nParentId);
491 sal_uInt32 GetParaId() const { return m_nParaId; }
492 void SetParaId(const sal_uInt32 nParaId);
493
495 virtual OUString GetPar1() const override;
496 virtual void SetPar1(const OUString& rStr) override;
497
499 virtual OUString GetPar2() const override;
500 virtual void SetPar2(const OUString& rStr) override;
501 const OUString& GetText() const { return m_sText; }
502 const OUString& GetInitials() const { return m_sInitials;}
503 void SetName(const OUString& rStr);
504 const OUString& GetName() const { return m_sName;}
505
506 const OutlinerParaObject* GetTextObject() const { return mpText ? &*mpText : nullptr;}
507 void SetTextObject( std::optional<OutlinerParaObject> pText );
508
509 void SetResolved(bool bNewState);
510 void ToggleResolved();
511 bool GetResolved() const;
512
513 sal_Int32 GetNumberOfParagraphs() const;
514
515 virtual bool QueryValue( css::uno::Any& rVal, sal_uInt16 nWhich ) const override;
516 virtual bool PutValue( const css::uno::Any& rVal, sal_uInt16 nWhich ) override;
517 virtual OUString GetDescription() const override;
518 virtual void dumpAsXml(xmlTextWriterPtr pWriter) const override;
519};
520
521class SAL_DLLPUBLIC_RTTI SwDocInfoFieldType final : public SwValueFieldType
522{
523public:
525
526 OUString Expand(sal_uInt16 nSubType, sal_uInt32 nFormat, LanguageType nLang, const OUString& rName) const;
527 virtual std::unique_ptr<SwFieldType> Copy() const override;
528};
529
531{
532 sal_uInt16 m_nSubType;
533 OUString m_aContent;
534 OUString m_aName;
535
536 virtual OUString ExpandImpl(SwRootFrame const* pLayout) const override;
537 virtual std::unique_ptr<SwField> Copy() const override;
538
539public:
540 SwDocInfoField(SwDocInfoFieldType*, sal_uInt16 nSub, const OUString& rName, sal_uInt32 nFormat=0);
541 SwDocInfoField(SwDocInfoFieldType*, sal_uInt16 nSub, const OUString& rName, const OUString& rValue, sal_uInt32 nFormat=0);
542
543 virtual void SetSubType(sal_uInt16) override;
544 virtual sal_uInt16 GetSubType() const override;
545 virtual void SetLanguage(LanguageType nLng) override;
546 virtual OUString GetFieldName() const override;
547 const OUString& GetName() const { return m_aName; }
548 void SetName( const OUString& rName ) { m_aName = rName; }
549 void SetExpansion(const OUString& rStr) { m_aContent = rStr; }
550 virtual bool QueryValue( css::uno::Any& rVal, sal_uInt16 nWhich ) const override;
551 virtual bool PutValue( const css::uno::Any& rVal, sal_uInt16 nWhich ) override;
552};
553
554// Extended User settings.
555class SwExtUserFieldType final : public SwFieldType
556{
557public:
559
560 static OUString Expand(sal_uInt16 nSubType);
561 virtual std::unique_ptr<SwFieldType> Copy() const override;
562};
563
564class SwExtUserField final : public SwField
565{
566 OUString m_aContent;
567 sal_uInt16 m_nType;
568
569public:
570 SwExtUserField(SwExtUserFieldType*, sal_uInt16 nSub, sal_uInt32 nFormat);
571
572 virtual OUString ExpandImpl(SwRootFrame const* pLayout) const override;
573 virtual std::unique_ptr<SwField> Copy() const override;
574
575 virtual sal_uInt16 GetSubType() const override;
576 virtual void SetSubType(sal_uInt16 nSub) override;
577
578 void SetExpansion(const OUString& rStr) { m_aContent = rStr; }
579
580 virtual bool QueryValue( css::uno::Any& rVal, sal_uInt16 nWhich ) const override;
581 virtual bool PutValue( const css::uno::Any& rVal, sal_uInt16 nWhich ) override;
582};
583
584// Relative page numbers - field.
586{
587public:
589
590 virtual std::unique_ptr<SwFieldType> Copy() const override;
591 virtual void UpdateFields() override {};
592
593private:
595 virtual void SwClientNotify(const SwModify&, const SfxHint&) override;
596};
597
598// Relative page numbering.
599class SAL_DLLPUBLIC_RTTI SwRefPageSetField final : public SwField
600{
602 bool m_bOn;
603
604public:
605 SwRefPageSetField( SwRefPageSetFieldType*, short nOff, bool bOn );
606
607 virtual OUString ExpandImpl(SwRootFrame const* pLayout) const override;
608 virtual std::unique_ptr<SwField> Copy() const override;
609
610 virtual OUString GetPar2() const override;
611 virtual void SetPar2(const OUString& rStr) override;
612
613 bool IsOn() const { return m_bOn; }
614
615 short GetOffset() const { return m_nOffset; }
616 void SetOffset( short nOff ) { m_nOffset = nOff; }
617 virtual bool QueryValue( css::uno::Any& rVal, sal_uInt16 nWhich ) const override;
618 virtual bool PutValue( const css::uno::Any& rVal, sal_uInt16 nWhich ) override;
619};
620
621// Relative page numbers - query field.
623{
626
627 void UpdateField(SwTextField const * pTextField,
628 SetGetExpFields const & rSetList, SwRootFrame const* pLayout);
629
631 virtual void SwClientNotify(const SwModify&, const SfxHint&) override;
632public:
634 virtual std::unique_ptr<SwFieldType> Copy() const override;
635 bool MakeSetList(SetGetExpFields& rTmpLst, SwRootFrame const* pLayout);
636 SwDoc& GetDoc() const { return m_rDoc; }
637};
638
639// Query relative page numbering.
640class SwRefPageGetField final : public SwField
641{
642 OUString m_sText;
644
645public:
646 SwRefPageGetField( SwRefPageGetFieldType*, sal_uInt32 nFormat );
647
648 virtual OUString ExpandImpl(SwRootFrame const* pLayout) const override;
649 virtual std::unique_ptr<SwField> Copy() const override;
650
651 void SetText(const OUString& rText, SwRootFrame const* pLayout);
652
653 void ChangeExpansion(const SwFrame& rFrame, const SwTextField* pField);
654 virtual bool QueryValue( css::uno::Any& rVal, sal_uInt16 nWhich ) const override;
655 virtual bool PutValue( const css::uno::Any& rVal, sal_uInt16 nWhich ) override;
656};
657
658// Field to jump to and edit.
660{
663
664public:
665 SwJumpEditFieldType( SwDoc& rDoc );
666 virtual std::unique_ptr<SwFieldType> Copy() const override;
667 virtual void UpdateFields() override {};
668
670};
671
672class SwJumpEditField final : public SwField
673{
674 OUString m_sText;
675 OUString m_sHelp;
676public:
677 SwJumpEditField( SwJumpEditFieldType*, sal_uInt32 nFormat,
678 OUString sText, OUString sHelp );
679
680 virtual OUString ExpandImpl(SwRootFrame const* pLayout) const override;
681 virtual std::unique_ptr<SwField> Copy() const override;
682
684 virtual OUString GetPar1() const override;
685 virtual void SetPar1(const OUString& rStr) override;
686
688 virtual OUString GetPar2() const override;
689 virtual void SetPar2(const OUString& rStr) override;
690
692 { return static_cast<SwJumpEditFieldType*>(GetTyp())->GetCharFormat(); }
693 virtual bool QueryValue( css::uno::Any& rVal, sal_uInt16 nWhich ) const override;
694 virtual bool PutValue( const css::uno::Any& rVal, sal_uInt16 nWhich ) override;
695};
696
697class SwScriptFieldType final : public SwFieldType
698{
700public:
701 SwScriptFieldType( SwDoc& rDoc );
702
703 virtual std::unique_ptr<SwFieldType> Copy() const override;
704};
705
707{
708 OUString m_sType;
709 OUString m_sCode;
713
714public:
715 SwScriptField( SwScriptFieldType*, OUString aType,
716 OUString aCode, bool bURL );
717
718 virtual OUString GetDescription() const override;
719
720 virtual OUString ExpandImpl(SwRootFrame const* pLayout) const override;
721 virtual std::unique_ptr<SwField> Copy() const override;
722
724 virtual OUString GetPar1() const override;
725 virtual void SetPar1(const OUString& rStr) override;
727 virtual OUString GetPar2() const override;
728 virtual void SetPar2(const OUString& rStr) override;
729
730 bool IsCodeURL() const { return m_bCodeURL; }
731 void SetCodeURL( bool bURL ) { m_bCodeURL = bURL; }
732 virtual bool QueryValue( css::uno::Any& rVal, sal_uInt16 nWhich ) const override;
733 virtual bool PutValue( const css::uno::Any& rVal, sal_uInt16 nWhich ) override;
734};
735
736// Combined Character Fieldtype
737class SAL_DLLPUBLIC_RTTI SwCombinedCharFieldType final : public SwFieldType
738{
739public:
741
742 virtual std::unique_ptr<SwFieldType> Copy() const override;
743};
744
745// ScriptField
746#define MAX_COMBINED_CHARACTERS 6
747
749{
750 OUString m_sCharacters;
751
752public:
753 SwCombinedCharField( SwCombinedCharFieldType*, const OUString& rChars );
754
755 virtual OUString ExpandImpl(SwRootFrame const* pLayout) const override;
756 virtual std::unique_ptr<SwField> Copy() const override;
757
759 virtual OUString GetPar1() const override;
760 virtual void SetPar1(const OUString& rStr) override;
761
762 virtual bool QueryValue( css::uno::Any& rVal, sal_uInt16 nWhich ) const override;
763 virtual bool PutValue( const css::uno::Any& rVal, sal_uInt16 nWhich ) override;
764};
765
766#endif // INCLUDED_SW_INC_DOCUFLD_HXX
767
768/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
sal_Int32 GetDate() const
static OUString Expand(sal_uLong)
Definition: docufld.cxx:314
virtual std::unique_ptr< SwFieldType > Copy() const override
Definition: docufld.cxx:332
OUString m_aContent
Definition: docufld.hxx:190
virtual OUString ExpandImpl(SwRootFrame const *pLayout) const override
Definition: docufld.cxx:343
void SetExpansion(const OUString &rStr)
Definition: docufld.hxx:198
virtual std::unique_ptr< SwField > Copy() const override
Definition: docufld.cxx:352
virtual bool QueryValue(css::uno::Any &rVal, sal_uInt16 nWhich) const override
Definition: docufld.cxx:360
virtual bool PutValue(const css::uno::Any &rVal, sal_uInt16 nWhich) override
Definition: docufld.cxx:385
SwAuthorField(SwAuthorFieldType *, sal_uInt32 nFormat)
Definition: docufld.cxx:337
Represents the style of a text portion.
Definition: charfmt.hxx:27
OUString m_sCharacters
combine these characters
Definition: docufld.hxx:750
void SetExpansion(const OUString &rStr)
Definition: docufld.hxx:549
void SetName(const OUString &rName)
Definition: docufld.hxx:548
const OUString & GetName() const
Definition: docufld.hxx:547
OUString m_aName
Definition: docufld.hxx:534
OUString m_aContent
Definition: docufld.hxx:533
sal_uInt16 m_nSubType
Definition: docufld.hxx:532
void SetNumFormat(SvxNumType eFormat)
Definition: docufld.hxx:262
SvxNumType m_nNumberingType
Definition: docufld.hxx:255
sal_uInt16 m_nSubType
Definition: docufld.hxx:267
Definition: doc.hxx:195
static OUString Expand(sal_uInt16 nSubType)
Definition: docufld.cxx:2024
virtual std::unique_ptr< SwFieldType > Copy() const override
Definition: docufld.cxx:2019
virtual sal_uInt16 GetSubType() const override
Definition: docufld.cxx:2081
virtual OUString ExpandImpl(SwRootFrame const *pLayout) const override
Definition: docufld.cxx:2065
virtual std::unique_ptr< SwField > Copy() const override
Definition: docufld.cxx:2073
SwExtUserField(SwExtUserFieldType *, sal_uInt16 nSub, sal_uInt32 nFormat)
Definition: docufld.cxx:2059
OUString m_aContent
Definition: docufld.hxx:566
virtual bool PutValue(const css::uno::Any &rVal, sal_uInt16 nWhich) override
Definition: docufld.cxx:2114
sal_uInt16 m_nType
Definition: docufld.hxx:567
virtual bool QueryValue(css::uno::Any &rVal, sal_uInt16 nWhich) const override
Definition: docufld.cxx:2091
void SetExpansion(const OUString &rStr)
Definition: docufld.hxx:578
virtual void SetSubType(sal_uInt16 nSub) override
Definition: docufld.cxx:2086
Instances of SwFields and those derived from it occur 0 to n times.
Definition: fldbas.hxx:243
virtual void QueryValue(css::uno::Any &rVal, sal_uInt16 nWhich) const
Definition: fldbas.cxx:142
virtual void PutValue(const css::uno::Any &rVal, sal_uInt16 nWhich)
Definition: fldbas.cxx:145
virtual std::unique_ptr< SwFieldType > Copy() const =0
Base class of all fields.
Definition: fldbas.hxx:293
virtual void SetLanguage(LanguageType nLng)
Definition: fldbas.cxx:442
virtual void dumpAsXml(xmlTextWriterPtr pWriter) const
Definition: fldbas.cxx:884
virtual OUString GetPar1() const
Definition: fldbas.cxx:321
virtual void SetPar1(const OUString &rStr)
Definition: fldbas.cxx:336
virtual void SetPar2(const OUString &rStr)
Definition: fldbas.cxx:339
virtual OUString ExpandImpl(SwRootFrame const *pLayout) const =0
virtual sal_uInt16 GetSubType() const
Definition: fldbas.cxx:342
virtual bool QueryValue(css::uno::Any &rVal, sal_uInt16 nWhichId) const
Definition: fldbas.cxx:351
virtual OUString GetFieldName() const
get name or content
Definition: fldbas.cxx:305
virtual bool PutValue(const css::uno::Any &rVal, sal_uInt16 nWhichId)
Definition: fldbas.cxx:369
virtual OUString GetDescription() const
Definition: fldbas.cxx:862
SwFieldType * GetTyp() const
Definition: fldbas.hxx:399
virtual std::unique_ptr< SwField > Copy() const =0
virtual OUString GetPar2() const
Definition: fldbas.cxx:326
virtual void SetSubType(sal_uInt16)
Definition: fldbas.cxx:347
void SetExpansion(const OUString &rStr)
Definition: docufld.hxx:224
OUString m_aContent
Definition: docufld.hxx:216
Base class of the Writer layout elements.
Definition: frame.hxx:315
virtual std::unique_ptr< SwFieldType > Copy() const override
Definition: docufld.cxx:1651
virtual void UpdateFields() override
Definition: docufld.hxx:361
virtual std::unique_ptr< SwField > Copy() const override
Definition: docufld.cxx:1669
bool IsHidden() const
Definition: docufld.hxx:376
SwHiddenParaField(SwHiddenParaFieldType *, OUString aCond)
Direct input, delete old value.
Definition: docufld.cxx:1658
virtual void SetPar1(const OUString &rStr) override
set condition
Definition: docufld.cxx:1711
virtual bool QueryValue(css::uno::Any &rVal, sal_uInt16 nWhich) const override
Definition: docufld.cxx:1676
void SetHidden(bool bHidden)
Definition: docufld.hxx:375
OUString m_aCond
Definition: docufld.hxx:366
virtual OUString GetPar1() const override
Query, set condition.
Definition: docufld.cxx:1716
virtual OUString ExpandImpl(SwRootFrame const *pLayout) const override
Definition: docufld.cxx:1664
virtual bool PutValue(const css::uno::Any &rVal, sal_uInt16 nWhich) override
Definition: docufld.cxx:1693
virtual void UpdateFields() override
Definition: docufld.hxx:291
bool GetHiddenFlag() const
Definition: docufld.hxx:294
OUString m_aContent
Evaluated DB-text.
Definition: docufld.hxx:301
bool m_bValid
Is DB-field evaluated?
Definition: docufld.hxx:308
OUString m_aTRUEText
Text if condition true.
Definition: docufld.hxx:299
OUString m_aFALSEText
If condition false.
Definition: docufld.hxx:300
SwFieldTypesEnum m_nSubType
Definition: docufld.hxx:304
bool m_bIsHidden
Is it not visible?
Definition: docufld.hxx:307
bool m_bCanToggle
Can field be toggled alone?
Definition: docufld.hxx:306
OUString m_aCond
Condition.
Definition: docufld.hxx:303
void SetValue(bool bHidden)
Definition: docufld.hxx:331
virtual void UpdateFields() override
Definition: docufld.hxx:667
SwCharFormat * GetCharFormat()
Definition: docufld.cxx:2523
sw::WriterMultiListener m_aDep
Definition: docufld.hxx:662
SwJumpEditFieldType(SwDoc &rDoc)
Definition: docufld.cxx:2513
virtual std::unique_ptr< SwFieldType > Copy() const override
Definition: docufld.cxx:2518
OUString m_sText
Definition: docufld.hxx:674
virtual void SetPar2(const OUString &rStr) override
set hint text
Definition: docufld.cxx:2566
virtual std::unique_ptr< SwField > Copy() const override
Definition: docufld.cxx:2541
virtual OUString GetPar1() const override
Placeholder-Text.
Definition: docufld.cxx:2548
virtual OUString ExpandImpl(SwRootFrame const *pLayout) const override
Definition: docufld.cxx:2536
SwJumpEditField(SwJumpEditFieldType *, sal_uInt32 nFormat, OUString sText, OUString sHelp)
Definition: docufld.cxx:2530
virtual void SetPar1(const OUString &rStr) override
set place holder text
Definition: docufld.cxx:2554
OUString m_sHelp
Definition: docufld.hxx:675
virtual bool PutValue(const css::uno::Any &rVal, sal_uInt16 nWhich) override
Definition: docufld.cxx:2602
virtual OUString GetPar2() const override
Hint-Text.
Definition: docufld.cxx:2560
virtual bool QueryValue(css::uno::Any &rVal, sal_uInt16 nWhich) const override
Definition: docufld.cxx:2571
SwCharFormat * GetCharFormat() const
Definition: docufld.hxx:691
SwDoc & m_rDoc
Definition: docufld.hxx:387
const OUString & GetMacro() const
Definition: docufld.hxx:409
OUString m_aText
Definition: docufld.hxx:398
bool m_bIsScriptURL
Definition: docufld.hxx:399
OUString m_aMacro
Definition: docufld.hxx:397
SvxNumType m_nNumberingType
Definition: docufld.hxx:133
sal_uInt16 m_nMaxPage
Definition: docufld.hxx:154
void SetUserString(const OUString &rS)
Definition: docufld.hxx:176
const OUString & GetUserString() const
Definition: docufld.hxx:175
OUString m_sUserStr
Definition: docufld.hxx:149
sal_uInt16 m_nSubType
Definition: docufld.hxx:150
sal_uInt16 m_nPageNumber
Definition: docufld.hxx:153
SwDoc & GetDoc() const
Definition: docufld.hxx:442
sal_uInt32 GetPostItId() const
Definition: docufld.hxx:487
sal_uInt32 m_nParaId
Definition: docufld.hxx:460
const OUString & GetInitials() const
Definition: docufld.hxx:502
const OUString & GetText() const
Definition: docufld.hxx:501
sal_uInt32 GetParaId() const
Definition: docufld.hxx:491
const OUString & GetName() const
Definition: docufld.hxx:504
OUString m_sAuthor
Definition: docufld.hxx:451
rtl::Reference< SwTextAPIObject > m_xTextObject
Definition: docufld.hxx:457
const DateTime & GetDateTime() const
Definition: docufld.hxx:484
OUString m_sInitials
Initials of the author.
Definition: docufld.hxx:452
OUString m_sText
Definition: docufld.hxx:450
sal_uInt32 GetParentId() const
Definition: docufld.hxx:489
const OutlinerParaObject * GetTextObject() const
Definition: docufld.hxx:506
sal_uInt32 m_nParentId
Definition: docufld.hxx:459
SwPostItField(const SwPostItField &)=delete
bool m_bResolved
Definition: docufld.hxx:455
static sal_uInt32 s_nLastPostItId
Definition: docufld.hxx:463
Date GetDate() const
Definition: docufld.hxx:485
sal_uInt32 m_nPostItId
Definition: docufld.hxx:458
DateTime m_aDateTime
Definition: docufld.hxx:454
SwPostItField * operator=(const SwPostItField &)=delete
tools::Time GetTime() const
Definition: docufld.hxx:486
std::optional< OutlinerParaObject > mpText
Definition: docufld.hxx:456
OUString m_sName
Name of the comment.
Definition: docufld.hxx:453
SwDoc & GetDoc() const
Definition: docufld.hxx:636
virtual std::unique_ptr< SwFieldType > Copy() const override
Definition: docufld.cxx:2225
virtual void SwClientNotify(const SwModify &, const SfxHint &) override
overwritten to update all RefPageGet fields
Definition: docufld.cxx:2232
sal_Int16 m_nNumberingType
Definition: docufld.hxx:625
SwRefPageGetFieldType(SwDoc &rDoc)
Definition: docufld.cxx:2220
bool MakeSetList(SetGetExpFields &rTmpLst, SwRootFrame const *pLayout)
Definition: docufld.cxx:2277
void UpdateField(SwTextField const *pTextField, SetGetExpFields const &rSetList, SwRootFrame const *pLayout)
Definition: docufld.cxx:2323
virtual bool QueryValue(css::uno::Any &rVal, sal_uInt16 nWhich) const override
Definition: docufld.cxx:2473
void ChangeExpansion(const SwFrame &rFrame, const SwTextField *pField)
Definition: docufld.cxx:2412
virtual bool PutValue(const css::uno::Any &rVal, sal_uInt16 nWhich) override
Definition: docufld.cxx:2489
OUString m_sText
Definition: docufld.hxx:642
virtual std::unique_ptr< SwField > Copy() const override
Definition: docufld.cxx:2403
virtual OUString ExpandImpl(SwRootFrame const *pLayout) const override
Definition: docufld.cxx:2398
void SetText(const OUString &rText, SwRootFrame const *pLayout)
Definition: docufld.cxx:2385
OUString m_sTextRLHidden
hidden redlines
Definition: docufld.hxx:643
SwRefPageGetField(SwRefPageGetFieldType *, sal_uInt32 nFormat)
Definition: docufld.cxx:2379
virtual void UpdateFields() override
Definition: docufld.hxx:591
virtual void SwClientNotify(const SwModify &, const SfxHint &) override
noop, there is nothing to update!
Definition: docufld.cxx:2154
virtual std::unique_ptr< SwFieldType > Copy() const override
Definition: docufld.cxx:2148
void SetOffset(short nOff)
Definition: docufld.hxx:616
bool IsOn() const
Definition: docufld.hxx:613
short GetOffset() const
Definition: docufld.hxx:615
The root element of a Writer document layout.
Definition: rootfrm.hxx:83
virtual std::unique_ptr< SwFieldType > Copy() const override
Definition: scrptfld.cxx:33
SwScriptFieldType(SwDoc &rDoc)
Definition: scrptfld.cxx:29
bool IsCodeURL() const
Definition: docufld.hxx:730
bool m_bCodeURL
Code contains URL of a script.
Definition: docufld.hxx:712
void SetCodeURL(bool bURL)
Definition: docufld.hxx:731
OUString m_sCode
Code as text.
Definition: docufld.hxx:709
OUString m_sType
Type of Code (Java/VBScript/...)
Definition: docufld.hxx:708
Fields containing values that have to be formatted via number formatter.
Definition: fldbas.hxx:416
sal_Int64 GetTime() const
struct _xmlTextWriter * xmlTextWriterPtr
SwExtUserSubType
Definition: docufld.hxx:102
@ EU_APARTMENT
Definition: docufld.hxx:119
@ EU_PHONE_PRIVATE
Definition: docufld.hxx:113
@ EU_TITLE
Definition: docufld.hxx:111
@ EU_PHONE_COMPANY
Definition: docufld.hxx:114
@ EU_FIRSTNAME
Definition: docufld.hxx:104
@ EU_FAX
Definition: docufld.hxx:115
@ EU_NAME
Definition: docufld.hxx:105
@ EU_EMAIL
Definition: docufld.hxx:116
@ EU_STREET
Definition: docufld.hxx:107
@ EU_COMPANY
Definition: docufld.hxx:103
@ EU_FATHERSNAME
Definition: docufld.hxx:118
@ EU_POSITION
Definition: docufld.hxx:112
@ EU_ZIP
Definition: docufld.hxx:109
@ EU_SHORTCUT
Definition: docufld.hxx:106
@ EU_CITY
Definition: docufld.hxx:110
@ EU_COUNTRY
Definition: docufld.hxx:108
@ EU_STATE
Definition: docufld.hxx:117
SwJumpEditFormat
Definition: docufld.hxx:123
@ JE_FMT_TEXT
Definition: docufld.hxx:124
@ JE_FMT_GRAPHIC
Definition: docufld.hxx:127
@ JE_FMT_TABLE
Definition: docufld.hxx:125
@ JE_FMT_OLE
Definition: docufld.hxx:128
@ JE_FMT_FRAME
Definition: docufld.hxx:126
SwPageNumSubType
Definition: docufld.hxx:91
@ PG_NEXT
Definition: docufld.hxx:93
@ PG_RANDOM
Definition: docufld.hxx:92
@ PG_PREV
Definition: docufld.hxx:94
SwDocStatSubType
Definition: docufld.hxx:52
@ DS_CHAR
Definition: docufld.hxx:57
@ DS_GRF
Definition: docufld.hxx:59
@ DS_TBL
Definition: docufld.hxx:58
@ DS_OLE
Definition: docufld.hxx:60
@ DS_BEGIN
Definition: docufld.hxx:53
@ DS_PAGE
Definition: docufld.hxx:54
@ DS_WORD
Definition: docufld.hxx:56
@ DS_PARA
Definition: docufld.hxx:55
SwAuthorFormat
Definition: docufld.hxx:43
@ AF_SHORTCUT
Definition: docufld.hxx:46
@ AF_BEGIN
Definition: docufld.hxx:44
@ AF_NAME
Definition: docufld.hxx:45
@ AF_FIXED
Definition: docufld.hxx:47
sal_uInt16 SwDocInfoSubType
Definition: docufld.hxx:63
OUString m_sName
SwFieldTypesEnum
List of FieldTypes at UI.
Definition: fldbas.hxx:94
const SwDocInfoSubType DI_SUB_MASK
Definition: docufld.hxx:87
const SwDocInfoSubType DI_DOCNO
Definition: docufld.hxx:78
const SwDocInfoSubType DI_SUB_AUTHOR
Definition: docufld.hxx:83
const SwDocInfoSubType DI_CUSTOM
Definition: docufld.hxx:80
const SwDocInfoSubType DI_CHANGE
Definition: docufld.hxx:76
const SwDocInfoSubType DI_COMMENT
Definition: docufld.hxx:74
const SwDocInfoSubType DI_SUBTYPE_BEGIN
NB: these must denote consecutive integers! NB2: these are extended by 4 DI_INFO values for backward ...
Definition: docufld.hxx:70
const SwDocInfoSubType DI_SUBTYPE_END
Definition: docufld.hxx:81
const SwDocInfoSubType DI_SUB_FIXED
Definition: docufld.hxx:86
const SwDocInfoSubType DI_PRINT
Definition: docufld.hxx:77
const SwDocInfoSubType DI_SUB_DATE
Definition: docufld.hxx:85
const SwDocInfoSubType DI_KEYS
Definition: docufld.hxx:73
const SwDocInfoSubType DI_EDIT
Definition: docufld.hxx:79
const SwDocInfoSubType DI_SUBJECT
Definition: docufld.hxx:72
const SwDocInfoSubType DI_TITLE
Definition: docufld.hxx:71
const SwDocInfoSubType DI_SUB_TIME
Definition: docufld.hxx:84
const SwDocInfoSubType DI_CREATE
Definition: docufld.hxx:75
OUString m_aName
sal_uIntPtr sal_uLong
static LanguageType nLang
Definition: srtdlg.cxx:51
SvxNumType
#define SW_DLLPUBLIC
Definition: swdllapi.h:28
::ucbhelper::Content m_aContent