+<PRIVATE
+
+: row,col-dim ( font r c -- dim )
+ CHAR: x <string> swap
+ CHAR: \n <string>
+ append text-dim ;
+
+: min-dim ( font editor -- dim )
+ [ min-rows>> [ 0 ] unless* ]
+ [ min-cols>> [ 0 ] unless* ] bi
+ row,col-dim ;
+
+: max-dim ( font editor -- dim )
+ ! hopefully no one goes over 5000
+ [ max-rows>> [ 5000 ] unless* ]
+ [ max-cols>> [ 5000 ] unless* ] bi
+ row,col-dim ;
+
+: txt-dim ( font editor -- dim )
+ control-value text-dim ;
+
+PRIVATE>
+
+: editor-constrained-dim ( editor -- dim )
+ [ font>> ] keep
+ [ max-dim ]
+ [ txt-dim ]
+ [ min-dim ]
+ 2tri vmax vmin { 1 0 } v+ ;
+