/src/libstaroffice/src/lib/StarState.cxx
Line | Count | Source |
1 | | /* -*- Mode: C++; c-default-style: "k&r"; indent-tabs-mode: nil; tab-width: 2; c-basic-offset: 2 -*- */ |
2 | | |
3 | | /* libstaroffice |
4 | | * Version: MPL 2.0 / LGPLv2+ |
5 | | * |
6 | | * The contents of this file are subject to the Mozilla Public License Version |
7 | | * 2.0 (the "License"); you may not use this file except in compliance with |
8 | | * the License or as specified alternatively below. You may obtain a copy of |
9 | | * the License at http://www.mozilla.org/MPL/ |
10 | | * |
11 | | * Software distributed under the License is distributed on an "AS IS" basis, |
12 | | * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License |
13 | | * for the specific language governing rights and limitations under the |
14 | | * License. |
15 | | * |
16 | | * Major Contributor(s): |
17 | | * Copyright (C) 2002 William Lachance (wrlach@gmail.com) |
18 | | * Copyright (C) 2002,2004 Marc Maurer (uwog@uwog.net) |
19 | | * Copyright (C) 2004-2006 Fridrich Strba (fridrich.strba@bluewin.ch) |
20 | | * Copyright (C) 2006, 2007 Andrew Ziem |
21 | | * Copyright (C) 2011, 2012 Alonso Laurent (alonso@loria.fr) |
22 | | * |
23 | | * |
24 | | * All Rights Reserved. |
25 | | * |
26 | | * For minor contributions see the git repository. |
27 | | * |
28 | | * Alternatively, the contents of this file may be used under the terms of |
29 | | * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), |
30 | | * in which case the provisions of the LGPLv2+ are applicable |
31 | | * instead of those above. |
32 | | */ |
33 | | |
34 | | #include <librevenge/librevenge.h> |
35 | | |
36 | | #include "StarState.hxx" |
37 | | |
38 | | #include "STOFFList.hxx" |
39 | | |
40 | | #include "StarItemPool.hxx" |
41 | | #include "StarObjectModel.hxx" |
42 | | #include "StarObjectNumericRuler.hxx" |
43 | | |
44 | | #include "SWFieldManager.hxx" |
45 | | |
46 | | StarState::GlobalState::~GlobalState() |
47 | 832k | { |
48 | 832k | } |
49 | | |
50 | | StarState::StarState(StarItemPool const *pool, StarObject &object) |
51 | 815k | : m_global(new StarState::GlobalState(pool, object, pool ? pool->getRelativeUnit() : 0.05)) |
52 | 815k | , m_styleName("") |
53 | 815k | , m_break(0) |
54 | 815k | , m_cell() |
55 | 815k | , m_frame() |
56 | 815k | , m_graphic() |
57 | 815k | , m_paragraph() |
58 | 815k | , m_font() |
59 | 815k | , m_content(false) |
60 | 815k | , m_flyCnt(false) |
61 | 815k | , m_footnote(false) |
62 | 815k | , m_headerFooter(false) |
63 | 815k | , m_link("") |
64 | 815k | , m_refMark("") |
65 | 815k | , m_field() |
66 | 815k | { |
67 | 815k | } |
68 | | |
69 | | StarState::StarState(StarState::GlobalState const &global) |
70 | 16.2k | : m_global(new StarState::GlobalState(global.m_pool, global.m_object, global.m_relativeUnit)) |
71 | 16.2k | , m_styleName("") |
72 | 16.2k | , m_break(0) |
73 | 16.2k | , m_cell() |
74 | 16.2k | , m_frame() |
75 | 16.2k | , m_graphic() |
76 | 16.2k | , m_paragraph() |
77 | 16.2k | , m_font() |
78 | 16.2k | , m_content(false) |
79 | 16.2k | , m_flyCnt(false) |
80 | 16.2k | , m_footnote(false) |
81 | 16.2k | , m_headerFooter(false) |
82 | 16.2k | , m_link("") |
83 | 16.2k | , m_refMark("") |
84 | 16.2k | , m_field() |
85 | 16.2k | { |
86 | 16.2k | m_global->m_objectModel=global.m_objectModel; |
87 | 16.2k | } |
88 | | StarState::~StarState() |
89 | 1.06M | { |
90 | 1.06M | } |
91 | | |
92 | | void StarState::reinitializeLineData() |
93 | 196k | { |
94 | 196k | m_font=STOFFFont(); |
95 | 196k | m_content=m_flyCnt=m_footnote=false; |
96 | 196k | m_link=m_refMark=""; |
97 | 196k | m_field.reset(); |
98 | 196k | } |
99 | | |
100 | | // vim: set filetype=cpp tabstop=2 shiftwidth=2 cindent autoindent smartindent noexpandtab: |