Line data Source code
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 : #include <editeng/swafopt.hxx>
21 : #include <tools/gen.hxx>
22 : #include <vcl/keycodes.hxx>
23 :
24 178 : SvxSwAutoFmtFlags::SvxSwAutoFmtFlags()
25 : : aBulletFont( OUString("StarSymbol"),
26 178 : Size( 0, 14 ) )
27 : {
28 : bAutoCorrect =
29 : bCptlSttSntnc =
30 : bCptlSttWrd =
31 : bChkFontAttr =
32 : bChgUserColl =
33 : bChgEnumNum =
34 : bAddNonBrkSpace =
35 : bChgOrdinalNumber =
36 : bChgToEnEmDash =
37 : bChgWeightUnderl =
38 : bSetINetAttr =
39 : bAFmtDelSpacesAtSttEnd =
40 : bAFmtDelSpacesBetweenLines =
41 : bAFmtByInpDelSpacesAtSttEnd =
42 : bAFmtByInpDelSpacesBetweenLines =
43 178 : bDummy = true;
44 :
45 : bReplaceStyles =
46 : bDelEmptyNode =
47 : bWithRedlining =
48 : bAutoCmpltEndless =
49 178 : bAutoCmpltAppendBlanc = false;
50 :
51 : bAutoCmpltShowAsTip =
52 : bSetBorder =
53 : bCreateTable =
54 : bSetNumRule =
55 : bAFmtByInput =
56 : bRightMargin =
57 : bAutoCompleteWords =
58 : bAutoCmpltCollectWords =
59 178 : bAutoCmpltKeepList = true;
60 :
61 : bDummy6 = bDummy7 = bDummy8 =
62 178 : false;
63 :
64 178 : nRightMargin = 50; // default 50%
65 178 : nAutoCmpltExpandKey = KEY_RETURN;
66 :
67 178 : aBulletFont.SetCharSet( RTL_TEXTENCODING_SYMBOL );
68 178 : aBulletFont.SetFamily( FAMILY_DONTKNOW );
69 178 : aBulletFont.SetPitch( PITCH_DONTKNOW );
70 178 : aBulletFont.SetWeight( WEIGHT_DONTKNOW );
71 178 : aBulletFont.SetTransparent( true );
72 :
73 178 : cBullet = 0x2022;
74 178 : cByInputBullet = cBullet;
75 178 : aByInputBulletFont = aBulletFont;
76 :
77 178 : nAutoCmpltWordLen = 8;
78 178 : nAutoCmpltListLen = 1000;
79 178 : m_pAutoCompleteList = 0;
80 178 : pSmartTagMgr = 0;
81 178 : }
82 :
83 :
84 88 : SvxSwAutoFmtFlags& SvxSwAutoFmtFlags::operator=( const SvxSwAutoFmtFlags& rAFFlags )
85 : {
86 88 : bAutoCorrect = rAFFlags.bAutoCorrect;
87 88 : bCptlSttSntnc = rAFFlags.bCptlSttSntnc;
88 88 : bCptlSttWrd = rAFFlags.bCptlSttWrd;
89 88 : bChkFontAttr = rAFFlags.bChkFontAttr;
90 :
91 88 : bChgUserColl = rAFFlags.bChgUserColl;
92 88 : bChgEnumNum = rAFFlags.bChgEnumNum;
93 88 : bDelEmptyNode = rAFFlags.bDelEmptyNode;
94 88 : bSetNumRule = rAFFlags.bSetNumRule;
95 88 : bAFmtByInput = rAFFlags.bAFmtByInput;
96 :
97 88 : bAddNonBrkSpace = rAFFlags.bAddNonBrkSpace;
98 88 : bChgOrdinalNumber = rAFFlags.bChgOrdinalNumber;
99 88 : bChgToEnEmDash = rAFFlags.bChgToEnEmDash;
100 88 : bChgWeightUnderl = rAFFlags.bChgWeightUnderl;
101 88 : bSetINetAttr = rAFFlags.bSetINetAttr;
102 88 : bSetBorder = rAFFlags.bSetBorder;
103 88 : bCreateTable = rAFFlags.bCreateTable;
104 88 : bReplaceStyles = rAFFlags.bReplaceStyles;
105 88 : bAFmtDelSpacesAtSttEnd = rAFFlags.bAFmtDelSpacesAtSttEnd;
106 88 : bAFmtDelSpacesBetweenLines = rAFFlags.bAFmtDelSpacesBetweenLines;
107 88 : bAFmtByInpDelSpacesAtSttEnd = rAFFlags.bAFmtByInpDelSpacesAtSttEnd;
108 88 : bAFmtByInpDelSpacesBetweenLines = rAFFlags.bAFmtByInpDelSpacesBetweenLines;
109 :
110 88 : bDummy = rAFFlags.bDummy;
111 :
112 88 : bDummy6 = rAFFlags.bDummy6;
113 88 : bDummy7 = rAFFlags.bDummy7;
114 88 : bDummy8 = rAFFlags.bDummy8;
115 :
116 88 : bWithRedlining = rAFFlags.bWithRedlining;
117 :
118 88 : bRightMargin = rAFFlags.bRightMargin;
119 88 : nRightMargin = rAFFlags.nRightMargin;
120 :
121 88 : cBullet = rAFFlags.cBullet;
122 88 : aBulletFont = rAFFlags.aBulletFont;
123 :
124 88 : cByInputBullet = rAFFlags.cByInputBullet;
125 88 : aByInputBulletFont = rAFFlags.aByInputBulletFont;
126 :
127 88 : bAutoCompleteWords = rAFFlags.bAutoCompleteWords;
128 88 : bAutoCmpltCollectWords = rAFFlags.bAutoCmpltCollectWords;
129 88 : bAutoCmpltKeepList = rAFFlags.bAutoCmpltKeepList;
130 88 : bAutoCmpltEndless = rAFFlags.bAutoCmpltEndless;
131 88 : bAutoCmpltAppendBlanc = rAFFlags.bAutoCmpltAppendBlanc;
132 88 : bAutoCmpltShowAsTip = rAFFlags.bAutoCmpltShowAsTip;
133 88 : m_pAutoCompleteList = rAFFlags.m_pAutoCompleteList;
134 88 : pSmartTagMgr = rAFFlags.pSmartTagMgr;
135 88 : nAutoCmpltExpandKey = rAFFlags.nAutoCmpltExpandKey;
136 :
137 88 : nAutoCmpltWordLen = rAFFlags.nAutoCmpltWordLen;
138 88 : nAutoCmpltListLen = rAFFlags.nAutoCmpltListLen;
139 :
140 88 : return *this;
141 : }
142 :
143 : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|