]> gitweb.factorcode.org Git - factor.git/blobdiff - extra/pdf/layout/layout.factor
sequences.extras: adding change-last and change-last-unsafe.
[factor.git] / extra / pdf / layout / layout.factor
index d2177f63db52de4c205e1976df28f29f5eaff794..d509bca78fcace5ec2771e42f851bdd8666f540e 100644 (file)
@@ -4,7 +4,8 @@
 USING: accessors assocs calendar combinators environment fonts
 formatting fry io io.streams.string kernel literals locals make
 math math.order math.ranges pdf.canvas pdf.values pdf.wrap
-sequences sorting splitting ui.text xml.entities ;
+sequences sequences.extras sorting splitting ui.text
+xml.entities ;
 FROM: assocs => change-at ;
 FROM: sequences => change-nth ;
 FROM: pdf.canvas => draw-text ;
@@ -245,9 +246,6 @@ M: table-row pdf-render
         ] [ 0 ] if*
     ] map nip ;
 
-: change-last ( seq quot -- )
-    [ drop length 1 - ] [ change-nth ] 2bi ; inline
-
 :: max-col-widths ( canvas rows -- widths )
     H{ } clone :> widths
     rows [