Better layout for the capabilities doc
svn: r10724
This commit is contained in:
parent
bf86c29bb7
commit
1a64ab3af4
|
@ -974,43 +974,60 @@ all of the names in the tools library, for use defining keybindings
|
||||||
and a contract on the values the capability might have.
|
and a contract on the values the capability might have.
|
||||||
|
|
||||||
By default, these capabilities are registered as DrScheme starts up:
|
By default, these capabilities are registered as DrScheme starts up:
|
||||||
@itemize{
|
@(let-syntax ([cap (syntax-rules ()
|
||||||
@item{ @scheme[(drscheme:language:register-capability 'drscheme:check-syntax-button (flat-contract boolean?) #t)]
|
[(cap key contract default desc ...)
|
||||||
--- controls the visiblity of the check syntax button
|
(item @scheme['key : contract = default]
|
||||||
}@item{ @schemeblock[(drscheme:language:register-capability
|
"--- " desc ...)])])
|
||||||
'drscheme:language-menu-title
|
(itemize
|
||||||
(flat-contract string?)
|
@cap[drscheme:check-syntax-button boolean? #t]{
|
||||||
(string-constant scheme-menu-name))]
|
controls the visiblity of the check syntax button}
|
||||||
--- controls the name of the menu just to the right of the language menu (defaultly named ``Scheme'')
|
@cap[drscheme:language-menu-title
|
||||||
}@item{ @scheme[(drscheme:language:register-capability 'drscheme:define-popup (or/c (cons/c string? string?) false/c) (cons "(define" "(define ...)"))]
|
string?
|
||||||
--- specifies the prefix that the define popup should look for and what label it should have,
|
(string-constant scheme-menu-name)]{
|
||||||
or @scheme[#f] if it should not appear at all.
|
controls the name of the menu just to the right of the language
|
||||||
}@item{ @scheme[(drscheme:language:register-capability 'drscheme:special:insert-fraction (flat-contract boolean?) #t)]
|
menu (defaultly named ``Scheme'')}
|
||||||
--- determines if the insert fraction menu item in the special menu is visible
|
@cap[drscheme:define-popup
|
||||||
}@item{ @scheme[(drscheme:language:register-capability 'drscheme:special:insert-lambda (flat-contract boolean?) #t)]
|
(or/c (cons/c string? string?) false/c)
|
||||||
--- determines if the insert lambda menu item in the special menu is visible
|
(cons "(define" "(define ...)")]{
|
||||||
}@item{ @scheme[(drscheme:language:register-capability 'drscheme:special:insert-large-letters (flat-contract boolean?) #t)]
|
specifies the prefix that the define popup should look for and what
|
||||||
--- determines if the insert large letters menu item in the special menu is visible
|
label it should have, or @scheme[#f] if it should not appear at all}
|
||||||
}@item{ @scheme[(drscheme:language:register-capability 'drscheme:special:insert-image (flat-contract boolean?) #t)]
|
@cap[drscheme:special:insert-fraction boolean? #t]{
|
||||||
--- determines if the insert image menu item in the special menu is visible
|
determines if the insert fraction menu item in the special menu is
|
||||||
}@item{ @scheme[(drscheme:language:register-capability 'drscheme:special:insert-comment-box (flat-contract boolean?) #t)]
|
visible}
|
||||||
--- determines if the insert comment box menu item in the special menu is visible
|
@cap[drscheme:special:insert-lambda boolean? #t]{
|
||||||
}@item{ @scheme[(drscheme:language:register-capability 'drscheme:special:insert-gui-tool (flat-contract boolean?) #t)]
|
determines if the insert lambda menu item in the special menu is
|
||||||
--- determines if the insert gui menu item in the special menu is visible
|
visible}
|
||||||
}@item{ @scheme[(drscheme:language:register-capability 'drscheme:special:slideshow-menu-item (flat-contract boolean?) #t)]
|
@cap[drscheme:special:insert-large-letters boolean? #t]{
|
||||||
--- determines if the insert pict box menu item in the special menu is visible
|
determines if the insert large letters menu item in the special menu
|
||||||
}@item{ @scheme[(drscheme:language:register-capability 'drscheme:special:insert-text-box (flat-contract boolean?) #t)]
|
is visible}
|
||||||
--- determines if the insert text box menu item in the special menu is visible
|
@cap[drscheme:special:insert-image boolean? #t]{
|
||||||
}@item{ @scheme[(drscheme:language:register-capability 'drscheme:special:xml-menus (flat-contract boolean?) #t)]
|
determines if the insert image menu item in the special menu is
|
||||||
--- determines if the insert scheme box, insert scheme splice box, and the insert xml box menu item ins the special menu are visible
|
visible}
|
||||||
}@item{ @scheme[(drscheme:language:register-capability 'drscheme:autocomplete-words (listof string?) '())]
|
@cap[drscheme:special:insert-comment-box boolean? #t]{
|
||||||
--- determines the list of words that are used when completing words in this language
|
determines if the insert comment box menu item in the special menu
|
||||||
}@item{ @schemeblock[(drscheme:language:register-capability
|
is visible}
|
||||||
'drscheme:tabify-menu-callback
|
@cap[drscheme:special:insert-gui-tool boolean? #t]{
|
||||||
|
determines if the insert gui menu item in the special menu is
|
||||||
|
visible}
|
||||||
|
@cap[drscheme:special:slideshow-menu-item boolean? #t]{
|
||||||
|
determines if the insert pict box menu item in the special menu is
|
||||||
|
visible}
|
||||||
|
@cap[drscheme:special:insert-text-box boolean? #t]{
|
||||||
|
determines if the insert text box menu item in the special menu is
|
||||||
|
visible}
|
||||||
|
@cap[drscheme:special:xml-menus boolean? #t]{
|
||||||
|
determines if the insert scheme box, insert scheme splice box, and
|
||||||
|
the insert xml box menu item in the special menu are visible}
|
||||||
|
@cap[drscheme:autocomplete-words (listof string?) '()]{
|
||||||
|
determines the list of words that are used when completing words in
|
||||||
|
this language}
|
||||||
|
@cap[drscheme:tabify-menu-callback
|
||||||
(or/c false/c (-> (is-a?/c text%) number? number? void?))
|
(or/c false/c (-> (is-a?/c text%) number? number? void?))
|
||||||
(λ (t a b) (send t tabify-selection a b)))]
|
(λ (t a b) (send t tabify-selection a b))]{
|
||||||
--- is used as the callback when the ``Reindent'' or ``Reindent All'' menu is selected. The first argument is the editor, and the second and third are a range in the editor.
|
is used as the callback when the ``Reindent'' or ``Reindent All''
|
||||||
}}})
|
menu is selected. The first argument is the editor, and the second
|
||||||
|
and third are a range in the editor.}
|
||||||
|
))})
|
||||||
|
|
||||||
(proc-doc/names
|
(proc-doc/names
|
||||||
drscheme:language:capability-registered?
|
drscheme:language:capability-registered?
|
||||||
|
|
Loading…
Reference in New Issue
Block a user