Subversion-Projekte lars-tiefland.php_share

Revision

Details | Letzte Änderung | Log anzeigen | RSS feed

Revision Autor Zeilennr. Zeile
1 lars 1
% $Header: /cvsroot/html2ps/postscript/flow.box.ps,v 1.1 2005/12/18 07:21:38 Konstantin Exp $
2
 
3
/flow-box {                        % => Child Parent
4
  exch                            % => Parent Child
5
 
6
% in case we're working with floated box,
7
% set 'display' property to 'block' value (FIXME: make this more compatible with CSS spec. 9.7)
8
  dup get-box-dict /Float get
9
  /none ne {
10
% if line box already have content, the flow this float _after_ the line box
11
% otherwise flow it immediately.
12
    1 index get-line length 0 gt {
13
      1 index exch add-deferred-float
14
      pop
15
    } {
16
      flow-float                   % => Parent
17
% Fix parent's current-x value
18
% in case this float had 'float: left' style first inline box should be shifted to the right
19
      offset-x-floats              % =>
20
    } ifelse
21
  } {
22
    dup get-flow-fun
23
    exec
24
  } ifelse
25
} def
26
 
27
/apply-clear {                     % => Box Y
28
  1 index get-box-dict /Clear get
29
  dup /left eq exch /both eq
30
  or {
31
    {
32
      dup get-box-dict /Float get /left eq {
33
        get-bottom min
34
      } {
35
        pop
36
      } ifelse
37
    } 1 index context-floats reduce          % => Parent Child DY FY1
38
    min
39
  } if
40
 
41
  1 index get-box-dict /Clear get
42
  dup /right eq exch /both eq
43
  or {
44
    {
45
      dup get-box-dict /Float get /right eq {
46
        get-bottom min
47
      } {
48
        pop
49
      } ifelse
50
    } 1 index context-floats reduce          % => Parent Child DY FY1
51
    min
52
  } if
53
} def