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