Changes between Version 3 and Version 4 of CocoaIde/FontSupport


Ignore:
Timestamp:
Feb 4, 2009, 6:12:56 PM (11 years ago)
Author:
gz
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • CocoaIde/FontSupport

    v3 v4  
     1
    12{{{
    23#!html
     
    910defined by a property name and value, each of which can be an arbitrary object.
    1011Character property names are compared using `EQL`.  Property values are
    11 compared using a special function `CHARPROP-EQUAL`.
     12compared using a special function `CHARPROP-EQUAL`.  The absence of a property
     13is indicated by property value of `NIL`.
    1214
    1315Property names that are keywords are reserved for use by Hemlock as
     
    8385`(SET-CHARPROP-VALUE mark name value &key count end view)`
    8486
    85 Sets the value of property `name` for characters at `mark`.
     87Sets the value of property `name` to `value` for characters at `mark`.  Setting the value to `nil` effectively removes the property.
    8688
    8789Either `count` or `end` may be specified, but not both.  If `count` is specified,
     
    106108
    107109Returns a value representing the set of properties of the character after mark.
    108 If 'view' is specified, returns the union of view and buffer properties.
    109 
    110 'filter' can be used to limit the properties looked at.  It can be a non-empty
     110If `view` is specified, returns the union of view and buffer properties.
     111
     112`filter` can be used to limit the properties looked at.  It can be a non-empty
    111113sequence of property names, or a function that takes a property name as an
    112114argument and returns true if the property is to be considered, or `:display` to
     
    117119
    118120Returns a value representing the set of properties of the character before mark.
    119 Arguments are as for NEXT-CHARPROPS.
     121Arguments are as for `NEXT-CHARPROPS`.
    120122
    121123`(SET-CHARPROPS mark charprops &key count end view filter)`
     
    123125`charprops` should be a value representing a set of properties. Each property in
    124126in the set is applied as if by `set-charprop-value`.  Properties not included in
    125 `charprops` are set to `nil`.
    126 
    127 If `filter` is non-nil,  it restricts the set of properties considered.  The default
    128 filter is the set of property names in `charprops`.
     127`charprops` but allowed by `filter` are set to `nil`, effectively removing them.
     128Properties not allowed by `filter` are not changed. The default
     129`filter` is `(charprops-names` `charprops)'.
    129130
    130131`(CHARPROPS-IN-REGION region-or-mark &key count end filter)`
    131132
    132 Returns a value representing the sequence of `charprops` for all the characters
     133Returns a value representing the sequence of charprops for all the characters
    133134in a region.  `count` and `end` can only be specified if `region-or-mark` is a
    134135region, in which case they define the region as described for `set-charprop-value`.
    135 The returned object doesn't encode the buffer range or the characters
    136 themselves, just the sequence of `charprops`.
     136Only properties allowed by `filter`.  The returned object doesn't
     137encode the buffer range or the characters themselves, just the sequence of `charprops`.
    137138
    138139`(APPLY-CHARPROPS mark charprops-range &key filter from-end)`
     
    154155Find a character whose properties are different from `next-charprops` if
    155156`from-end` is `nil`, or different from `previous-charprops` if `from-end` is
    156 non-`nil`.  If successful, move `mark` there and return it, else leave `mark`
     157non-`nil`.  Only properties allowed by `filter` are considered. If successful,
     158move `mark` there and return it, else leave `mark`
    157159unchanged and return `nil`.
    158160
     
    244246 * A way to associate a value comparison function with a user property.  Might be as simple as announcing `CHARPROP-EQUAL` is a generic function, but I just haven't thought about it yet.
    245247
    246  * A :hidden property to request the character be drawn at 0 width - to allow hiding parts of buffer.
    247 
    248  * Allow properties to be attached to regions as well as characters (not sure this is a good idea, but worth thinking through).
     248 * A `:hidden` property to request the character be drawn at 0 width - to allow hiding parts of buffer.
     249
     250 * Allow properties to be attached to regions as well as characters, lots of issues, but this would be a start on presentation support.
    249251
    250252 * Support multiple overlays in general (view properties are just a special case of overlays).
    251253
    252 
    253 
     254 * Do not restrict view properties to colors and underlines, by not using Cocoa temporary attributes to implement them.