1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
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/.
9 * This file incorporates work covered by the following license notice:
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 .
20 #include "htmlfly.hxx"
22 #define TE(t,p,c) { HtmlOut::t, HtmlPosition::p, HtmlContainerFlags::c }
24 AllHtmlFlags
const aHTMLOutFramePageFlyTable
[MAX_FRMTYPES
][MAX_BROWSERS
] =
27 // text frame with table
28 TE(TableNode
, Before
, NONE
), // HTML 3.2
29 TE(Div
, Prefix
, NONE
), // IE 4
30 TE(Div
, Prefix
, NONE
), // SW
31 TE(Div
, Prefix
, NONE
) // Netscape 4!
34 // text frame with table and headline
35 TE(TableNode
, Before
, NONE
), // HTML 3.2
36 TE(Div
, Prefix
, NONE
), // IE 4
37 TE(Div
, Prefix
, NONE
), // SW
38 TE(Div
, Prefix
, NONE
) // Netscape 4
42 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
43 TE(GraphicFrame
, Prefix
, NONE
), // IE 4
44 TE(MultiCol
, Prefix
, NONE
), // SW
45 TE(MultiCol
, Prefix
, Div
) // Netscape 4
49 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
50 TE(Div
, Prefix
, NONE
), // IE 4
51 TE(Div
, Prefix
, NONE
), // SW
52 TE(Div
, Prefix
, NONE
) // Netscape 4
56 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
57 TE(Div
, Prefix
, NONE
), // IE 4
58 TE(Div
, Prefix
, NONE
), // SW
59 TE(Div
, Prefix
, NONE
) // Netscape 4
63 TE(GraphicNode
, Inside
, NONE
), // HTML 3.2
64 TE(GraphicNode
, Prefix
, NONE
), // IE 4
65 TE(GraphicNode
, Prefix
, NONE
), // SW
66 TE(GraphicNode
, Prefix
, Span
) // Netscape 4
70 TE(OleNode
, Inside
, NONE
), // HTML 3.2
71 TE(OleNode
, Prefix
, NONE
), // IE 4
72 TE(OleNode
, Prefix
, NONE
), // SW
73 TE(OleNode
, Prefix
, Span
) // Netscape 4
77 TE(OleNode
, Inside
, NONE
), // HTML 3.2
78 TE(OleNode
, Prefix
, NONE
), // IE 4
79 TE(OleNode
, Prefix
, NONE
), // SW
80 TE(OleNode
, Prefix
, Span
) // Netscape 4
84 TE(OleGraphic
, Inside
, NONE
), // HTML 3.2
85 TE(OleNode
, Prefix
, NONE
), // IE 4
86 TE(OleNode
, Prefix
, NONE
), // SW
87 TE(OleGraphic
, Prefix
, Span
) // Netscape 4
91 TE(OleGraphic
, Inside
, NONE
), // HTML 3.2
92 TE(OleGraphic
, Prefix
, NONE
), // IE 4
93 TE(OleGraphic
, Prefix
, NONE
), // SW
94 TE(OleGraphic
, Prefix
, Span
) // Netscape 4
98 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
99 TE(AMarquee
, Prefix
, NONE
), // IE 4
100 TE(AMarquee
, Prefix
, NONE
), // SW
101 TE(GraphicFrame
, Prefix
, Span
) // Netscape 4
105 TE(Control
, Inside
, NONE
), // HTML 3.2
106 TE(Control
, Prefix
, NONE
), // IE 4
107 TE(Control
, Prefix
, NONE
), // SW
108 // Netscape disables FROM at controls in absolute position span.
109 TE(Control
, Inside
, NONE
) // Netscape 4
112 // other character objects
113 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
114 TE(GraphicFrame
, Prefix
, NONE
), // IE 4
115 TE(GraphicFrame
, Prefix
, NONE
), // SW
116 TE(GraphicFrame
, Prefix
, Span
) // Netscape 4
120 AllHtmlFlags
const aHTMLOutFrameParaFrameTable
[MAX_FRMTYPES
][MAX_BROWSERS
] =
123 // text frame with table
124 TE(TableNode
, Before
, NONE
), // HTML 3.2
125 TE(TableNode
, Before
, NONE
), // IE 4
126 TE(TableNode
, Before
, NONE
), // SW
127 TE(TableNode
, Before
, NONE
) // Netscape 4
130 // text frame with table and headline
131 TE(TableNode
, Before
, NONE
), // HTML 3.2
132 TE(Div
, Before
, NONE
), // IE 4
133 TE(Div
, Before
, NONE
), // SW
134 TE(TableNode
, Before
, NONE
) // Netscape 4
138 TE(GraphicFrame
, Before
, NONE
), // HTML 3.2
139 TE(GraphicFrame
, Before
, NONE
), // IE 4
140 TE(MultiCol
, Before
, NONE
), // SW
141 TE(MultiCol
, Before
, Div
) // Netscape 4
145 TE(GraphicFrame
, Before
, NONE
), // HTML 3.2
146 TE(Div
, Before
, NONE
), // IE 4
147 TE(Spacer
, Before
, NONE
), // SW
148 TE(Spacer
, Before
, NONE
) // Netscape 4
152 TE(GraphicFrame
, Before
, NONE
), // HTML 3.2
153 TE(Div
, Before
, NONE
), // IE 4
154 TE(Div
, Before
, NONE
), // SW
155 TE(Div
, Before
, NONE
) // Netscape 4
159 TE(GraphicNode
, Before
, NONE
), // HTML 3.2
160 TE(GraphicNode
, Before
, NONE
), // IE 4
161 TE(GraphicNode
, Before
, NONE
), // SW
162 TE(GraphicNode
, Before
, NONE
) // Netscape 4
166 TE(OleNode
, Before
, NONE
), // HTML 3.2
167 TE(OleNode
, Before
, NONE
), // IE 4
168 TE(OleNode
, Before
, NONE
), // SW
169 TE(OleNode
, Before
, NONE
) // Netscape 4
173 TE(OleNode
, Before
, NONE
), // HTML 3.2
174 TE(OleNode
, Before
, NONE
), // IE 4
175 TE(OleNode
, Before
, NONE
), // SW
176 TE(OleNode
, Before
, NONE
) // Netscape 4
180 TE(OleGraphic
, Before
, NONE
), // HTML 3.2
181 TE(OleNode
, Before
, NONE
), // IE 4
182 TE(OleNode
, Before
, NONE
), // SW
183 TE(OleGraphic
, Before
, NONE
) // Netscape 4
187 TE(OleGraphic
, Before
, NONE
), // HTML 3.2
188 TE(OleGraphic
, Before
, NONE
), // IE 4
189 TE(OleGraphic
, Before
, NONE
), // SW
190 TE(OleGraphic
, Before
, NONE
) // Netscape 4
193 // marquee (for Netscape 4 in container, so that
194 // the marquee appears at the right spot)
195 TE(GraphicFrame
, Before
, NONE
), // HTML 3.2
196 TE(AMarquee
, Before
, NONE
), // IE 4
197 TE(AMarquee
, Before
, NONE
), // SW
198 TE(GraphicFrame
, Before
, NONE
) // Netscape 4
202 TE(Control
, Inside
, NONE
), // HTML 3.2
203 TE(Control
, Before
, NONE
), // IE 4
204 TE(Control
, Before
, NONE
), // SW
205 // here you could make container out if it (import is missing)
206 TE(Control
, Before
, NONE
) // Netscape 4
209 // other character objects
210 TE(GraphicFrame
, Before
, NONE
), // HTML 3.2
211 TE(GraphicFrame
, Before
, NONE
), // IE 4
212 TE(GraphicFrame
, Before
, NONE
), // SW
213 TE(GraphicFrame
, Before
, NONE
) // Netscape 4
217 AllHtmlFlags
const aHTMLOutFrameParaPrtAreaTable
[MAX_FRMTYPES
][MAX_BROWSERS
] =
220 // text frame with table
221 TE(TableNode
, Inside
, NONE
), // HTML 3.2
222 TE(TableNode
, Inside
, NONE
), // IE 4
223 TE(TableNode
, Inside
, NONE
), // SW
224 TE(TableNode
, Inside
, NONE
) // Netscape 4
227 // text frame with table and headline
228 TE(TableNode
, Inside
, NONE
), // HTML 3.2
229 TE(Span
, Inside
, NONE
), // IE 4
230 TE(Span
, Inside
, NONE
), // SW
231 TE(Span
, Inside
, NONE
) // Netscape 4
235 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
236 TE(GraphicFrame
, Inside
, NONE
), // IE 4
237 TE(MultiCol
, Inside
, NONE
), // SW
238 TE(MultiCol
, Inside
, Span
) // Netscape 4
242 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
243 TE(Span
, Inside
, NONE
), // IE 4
244 TE(Spacer
, Inside
, NONE
), // SW
245 TE(Spacer
, Inside
, NONE
) // Netscape 4
249 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
250 TE(Span
, Inside
, NONE
), // IE 4
251 TE(Span
, Inside
, NONE
), // SW
252 TE(Span
, Inside
, NONE
) // Netscape 4
256 TE(GraphicNode
, Inside
, NONE
), // HTML 3.2
257 TE(GraphicNode
, Inside
, NONE
), // IE 4
258 TE(GraphicNode
, Inside
, NONE
), // SW
259 TE(GraphicNode
, Inside
, NONE
) // Netscape 4
263 TE(OleNode
, Inside
, NONE
), // HTML 3.2
264 TE(OleNode
, Inside
, NONE
), // IE 4
265 TE(OleNode
, Inside
, NONE
), // SW
266 TE(OleNode
, Inside
, NONE
) // Netscape 4
270 TE(OleNode
, Inside
, NONE
), // HTML 3.2
271 TE(OleNode
, Inside
, NONE
), // IE 4
272 TE(OleNode
, Inside
, NONE
), // SW
273 TE(OleNode
, Inside
, NONE
) // Netscape 4
277 TE(OleGraphic
, Inside
, NONE
), // HTML 3.2
278 TE(OleNode
, Inside
, NONE
), // IE 4
279 TE(OleNode
, Inside
, NONE
), // SW
280 TE(OleGraphic
, Inside
, NONE
) // Netscape 4
284 TE(OleGraphic
, Inside
, NONE
), // HTML 3.2
285 TE(OleGraphic
, Inside
, NONE
), // IE 4
286 TE(OleGraphic
, Inside
, NONE
), // SW
287 TE(OleGraphic
, Inside
, NONE
) // Netscape 4
291 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
292 TE(AMarquee
, Inside
, NONE
), // IE 4
293 TE(AMarquee
, Inside
, NONE
), // SW
294 TE(GraphicFrame
, Inside
, NONE
) // Netscape 4
298 TE(Control
, Inside
, NONE
), // HTML 3.2
299 TE(Control
, Inside
, NONE
), // IE 4
300 TE(Control
, Inside
, NONE
), // SW
301 // here you could make container out if it (import is missing)
302 TE(Control
, Inside
, NONE
) // Netscape 4
305 // other character objects
306 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
307 TE(GraphicFrame
, Inside
, NONE
), // IE 4
308 TE(GraphicFrame
, Inside
, NONE
), // SW
309 TE(GraphicFrame
, Inside
, NONE
) // Netscape 4
313 AllHtmlFlags
const aHTMLOutFrameParaOtherTable
[MAX_FRMTYPES
][MAX_BROWSERS
] =
316 // text frame with table
317 TE(TableNode
, Before
, NONE
), // HTML 3.2
318 TE(Span
, Inside
, NONE
), // IE 4
319 TE(Span
, Inside
, NONE
), // SW
320 TE(Span
, Inside
, NONE
) // Netscape 4
323 // text frame with table and headline
324 TE(TableNode
, Before
, NONE
), // HTML 3.2
325 TE(Span
, Inside
, NONE
), // IE 4
326 TE(Span
, Inside
, NONE
), // SW
327 TE(Span
, Inside
, NONE
) // Netscape 4
331 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
332 TE(GraphicFrame
, Inside
, NONE
), // IE 4
333 TE(MultiCol
, Inside
, NONE
), // SW
334 TE(MultiCol
, Inside
, Span
) // Netscape 4
338 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
339 TE(Span
, Inside
, NONE
), // IE 4
340 TE(Span
, Inside
, NONE
), // SW
341 TE(Span
, Inside
, NONE
) // Netscape 4
345 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
346 TE(Span
, Inside
, NONE
), // IE 4
347 TE(Span
, Inside
, NONE
), // SW
348 TE(Span
, Inside
, NONE
) // Netscape 4
352 TE(GraphicNode
, Inside
, NONE
), // HTML 3.2
353 TE(GraphicNode
, Inside
, NONE
), // IE 4
354 TE(GraphicNode
, Inside
, NONE
), // SW
355 TE(GraphicNode
, Inside
, Span
) // Netscape 4
359 TE(OleNode
, Inside
, NONE
), // HTML 3.2
360 TE(OleNode
, Inside
, NONE
), // IE 4
361 TE(OleNode
, Inside
, NONE
), // SW
362 TE(OleNode
, Inside
, Span
) // Netscape 4
366 TE(OleNode
, Inside
, NONE
), // HTML 3.2
367 TE(OleNode
, Inside
, NONE
), // IE 4
368 TE(OleNode
, Inside
, NONE
), // SW
369 TE(OleNode
, Inside
, Span
) // Netscape 4
373 TE(OleGraphic
, Inside
, NONE
), // HTML 3.2
374 TE(OleNode
, Inside
, NONE
), // IE 4
375 TE(OleNode
, Inside
, NONE
), // SW
376 TE(OleGraphic
, Inside
, Span
) // Netscape 4
380 TE(OleGraphic
, Inside
, NONE
), // HTML 3.2
381 TE(OleGraphic
, Inside
, NONE
), // IE 4
382 TE(OleGraphic
, Inside
, NONE
), // SW
383 TE(OleGraphic
, Inside
, Span
) // Netscape 4
387 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
388 TE(AMarquee
, Inside
, NONE
), // IE 4
389 TE(AMarquee
, Inside
, NONE
), // SW
390 TE(GraphicFrame
, Inside
, Span
) // Netscape 4
394 TE(Control
, Inside
, NONE
), // HTML 3.2
395 TE(Control
, Inside
, NONE
), // IE 4
396 TE(Control
, Inside
, NONE
), // SW
397 // Netscape disables FROM at controls in absolute position span.
398 TE(Control
, Inside
, NONE
) // Netscape 4
401 // other character objects
402 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
403 TE(GraphicFrame
, Inside
, NONE
), // IE 4
404 TE(GraphicFrame
, Inside
, NONE
), // SW
405 TE(GraphicFrame
, Inside
, Span
) // Netscape 4
409 AllHtmlFlags
const aHTMLOutFrameAsCharTable
[MAX_FRMTYPES
][MAX_BROWSERS
] =
412 // text frame with table
413 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
414 TE(GraphicFrame
, Inside
, NONE
), // IE 4
415 TE(GraphicFrame
, Inside
, NONE
), // SW
416 TE(GraphicFrame
, Inside
, NONE
) // Netscape 4
419 // text frame with table and headline
420 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
421 TE(GraphicFrame
, Inside
, NONE
), // IE 4
422 TE(GraphicFrame
, Inside
, NONE
), // SW
423 TE(GraphicFrame
, Inside
, NONE
) // Netscape 4
427 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
428 TE(GraphicFrame
, Inside
, NONE
), // IE 4
429 TE(MultiCol
, Inside
, NONE
), // SW
430 TE(MultiCol
, Inside
, NONE
) // Netscape 4
434 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
435 TE(GraphicFrame
, Inside
, NONE
), // IE 4
436 TE(Spacer
, Inside
, NONE
), // SW
437 TE(Spacer
, Inside
, NONE
) // Netscape 4
441 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
442 TE(GraphicFrame
, Inside
, NONE
), // IE 4
443 TE(GraphicFrame
, Inside
, NONE
), // SW
444 TE(GraphicFrame
, Inside
, NONE
) // Netscape 4
448 TE(GraphicNode
, Inside
, NONE
), // HTML 3.2
449 TE(GraphicNode
, Inside
, NONE
), // IE 4
450 TE(GraphicNode
, Inside
, NONE
), // SW
451 TE(GraphicNode
, Inside
, NONE
) // Netscape 4
455 TE(OleNode
, Inside
, NONE
), // HTML 3.2
456 TE(OleNode
, Inside
, NONE
), // IE 4
457 TE(OleNode
, Inside
, NONE
), // SW
458 TE(OleNode
, Inside
, NONE
) // Netscape 4
462 TE(OleNode
, Inside
, NONE
), // HTML 3.2
463 TE(OleNode
, Inside
, NONE
), // IE 4
464 TE(OleNode
, Inside
, NONE
), // SW
465 TE(OleNode
, Inside
, NONE
) // Netscape 4
469 TE(OleGraphic
, Inside
, NONE
), // HTML 3.2
470 TE(OleNode
, Inside
, NONE
), // IE 4
471 TE(OleNode
, Inside
, NONE
), // SW
472 TE(OleGraphic
, Inside
, NONE
) // Netscape 4
476 TE(OleGraphic
, Inside
, NONE
), // HTML 3.2
477 TE(OleGraphic
, Inside
, NONE
), // IE 4
478 TE(OleGraphic
, Inside
, NONE
), // SW
479 TE(OleGraphic
, Inside
, NONE
) // Netscape 4
482 // marquee (can always exported as marquee, because
483 // the content shows up at the right spot
484 TE(Marquee
, Inside
, NONE
), // HTML 3.2
485 TE(Marquee
, Inside
, NONE
), // IE 4
486 TE(Marquee
, Inside
, NONE
), // SW
487 TE(Marquee
, Inside
, NONE
) // Netscape 4
491 TE(Control
, Inside
, NONE
), // HTML 3.2
492 TE(Control
, Inside
, NONE
), // IE 4
493 TE(Control
, Inside
, NONE
), // SW
494 TE(Control
, Inside
, NONE
) // Netscape 4
497 // other character objects
498 TE(GraphicFrame
, Inside
, NONE
), // HTML 3.2
499 TE(GraphicFrame
, Inside
, NONE
), // IE 4
500 TE(GraphicFrame
, Inside
, NONE
), // SW
501 TE(GraphicFrame
, Inside
, NONE
) // Netscape 4
505 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */