aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKim F. Storm2004-03-19 22:26:38 +0000
committerKim F. Storm2004-03-19 22:26:38 +0000
commitc1cbc25ad68c12ce7894efc76e9657c2863f4784 (patch)
tree126d13a772c3b6a44f9e54a7415b6668b013500d
parentab24c1278d563d91edff4573b43eb9bc71355420 (diff)
downloademacs-c1cbc25ad68c12ce7894efc76e9657c2863f4784.tar.gz
emacs-c1cbc25ad68c12ce7894efc76e9657c2863f4784.zip
Document new :width and :align-to features.
-rw-r--r--etc/NEWS59
1 files changed, 59 insertions, 0 deletions
diff --git a/etc/NEWS b/etc/NEWS
index f44134bae40..701064fa2e9 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -1850,6 +1850,65 @@ configuration files.
1850 1850
1851* Lisp Changes in Emacs 21.4 1851* Lisp Changes in Emacs 21.4
1852 1852
1853** The display space :width and :align-to text properties are now
1854supported on text terminals.
1855
1856** Enhancements to stretch display properties
1857
1858The display property stretch specification form `(space PROPS)', where
1859PROPS is a property list now allows pixel based width and height
1860specifications, as well as enhanced horisontal text alignment.
1861
1862The value of these properties can now be a (primitive) expression
1863which is evaluated during redisplay. The following expressions
1864are supported:
1865
1866EXPR ::= NUM | (NUM) | UNIT | ELEM | POS | IMAGE | FORM
1867NUM ::= INTEGER | FLOAT | SYMBOL
1868UNIT ::= in | mm | cm | width | height
1869ELEM ::= left-fringe | right-fringe | left-margin | right-margin
1870 | scroll-bar | text
1871POS ::= left | center | right
1872FORM ::= (NUM . EXPR) | (OP EXPR ...)
1873OP ::= + | -
1874
1875The form `NUM' specifies a fractional width or height of the default
1876frame font size. The form `(NUM)' specifies an absolute number of
1877pixels. If a symbol is specified, its buffer-local variable binding
1878is used. The `in', `mm', and `cm' units specifies the number of
1879pixels per inch, milli-meter, and centi-meter, resp. The `width' and
1880`height' units correspond to the width and height of the current face
1881font. An image specification corresponds to the width or height of
1882the image.
1883
1884The `left-fringe', `right-fringe', `left-margin', `right-margin',
1885`scroll-bar', and `text' elements specify to the width of the
1886corresponding area of the window.
1887
1888The `left', `center', and `right' positions can be used with :align-to
1889to specify a position relative to the left edge, center, or right edge
1890of the text area. One of the above window elements (except `text')
1891can also be used with :align-to to specify that the position is
1892relative to the left edge of the given area. Once the base offset for
1893a relative position has been set (by the first occurrence of one of
1894these symbols), further occurences of these symbols are interpreted as
1895the width of the area.
1896
1897For example, to align to the center of the left-margin, use
1898 :align-to (+ left-margin (0.5 . left-margin))
1899
1900If no specific base offset is set for alignment, it is always relative
1901to the left edge of the text area. For example, :align-to 0 in a
1902header-line aligns with the first text column in the text area.
1903
1904The value of the form `(NUM . EXPR)' is the value of NUM multiplied by
1905the value of the expression EXPR. For example, (2 . in) specifies a
1906width of 2 inches, while (0.5 . IMAGE) specifies half the width (or
1907height) of the specified image.
1908
1909The form `(+ EXPR ...)' adds up the value of the expressions.
1910The form `(- EXPR ...)' negates or subtracts the value of the expressions.
1911
1853** New macro with-local-quit temporarily sets inhibit-quit to nil for use 1912** New macro with-local-quit temporarily sets inhibit-quit to nil for use
1854around potentially blocking or long-running code in timers 1913around potentially blocking or long-running code in timers
1855and post-command-hooks. 1914and post-command-hooks.