Eskil

Diff
Login

Differences From Artifact [aa6e5cc532]:

To Artifact [3383dbcbfc]:


75
76
77
78
79
80
81
82



83
84
85
86
87
88
89
75
76
77
78
79
80
81

82
83
84
85
86
87
88
89
90
91







-
+
+
+







        # Figure out font size from number of chars per line
        set charwidthHead [$pdf getCharWidth "0"]
        set charwidth [expr {$width / 2.0 / ($options(-cpl) + $options(-cpln) + 1)}]
        set fontsize [expr {$options(-headsize) * $charwidth / $charwidthHead}]
        $pdf setFont $fontsize

        # Text metrics
        set linesize  $fontsize
        set linesize  [$pdf getFontMetric height] ;# $fontsize
        set spacing [expr {$linesize / $fontsize}]
        $pdf setLineSpacing $spacing
        set offset    [expr {$fontsize + [$pdf getFontMetric bboxy]}]
        set charwidth [$pdf getCharWidth "0"]
        set nlinesf [expr {($height - $options(-headsize)) / $linesize}]
        # Number of lines per page
        set nlines  [expr {int($nlinesf - 1.0)}]
        #set nlines 66
        # Offsets to starting points in both subpages.