Parent Directory | Revision Log
|Links to HEAD:||(view) (annotate)|
Unsupplied and Numeric argument markers should not be uninterned structures, otherwise use of the literals in compiled files will fail to compare EQLly with the specials.
I feel ashamed of myself, but: commit a dubious fix to the infinite recursion observed when accepting a command from a drei-gadget dispatching command-table. The problem is that the accept presentation method sets the frame-command-table to the command-table from which the command is being accepted, while the dispatching table arranges to inherit from the frame-command-table dynamically, leading to an infinite explosion. This "fix" is dubious for a number of reasons, two of which are: the previous code is arguably "correct" in that it uses the established command-enabled protocol for detecting whether a command is disabled (though it is definitely weird that that necessitates mutating the frame-command-table); and that the fix doesn't actually address every instance of this problem, there being another in ESA:ESA-TOP-LEVEL.
Add new keyword to accepting-values, select-first-query, to automatically select the first field in the dialog (we could do this using an existing keyword, but figuring out the right query ID and getting it where it needed to be looked like too much work). This highlights what I think is an existing bug - the exit buttons often don't work when a field in the dialog is accepting. Minor aesthetic tweaks to accepting-values dialog (change border styles, dress up exit buttons, rearrange some line breaks).
MAP-OVER-COMMAND-TABLE-TRANSLATORS and ADD-ACTUAL-PRESENTATION-TRANSLATOR-TO-COMMAND-TABLE from Mike Watters.
Fixed broken :insert-default t in command parameters. It wasn't being passed along in the call to ACCEPT in the acceptor. I feel a bit odd about this fix, because I vaguely recall that this used to work, at least in Climacs, but the code pretty obviously filtered :insert-default keywords away.
Fixed the addition of menu items to empty menus.
Fix typo, with-bounding-rectangle -> with-bounding-rectangle*.
Implemented generic input-editor typeout, provided we can get an output record for the input editor. Theoretically, the nice typeout implementation should now also work for Goatee, though I seem to have broken it at some other point.
Added type specification to inherit-from slot of command tables. It's very easy to accidentally provide a non-list for the inherit-from argument, but it's not correct, and will fail later on.
Implemented :inherit-menu keyword argument for MAKE-COMMAND-TABLE and DEFINE-COMMAND-TABLE.
Committed patch from Nikodemus Siivola fixing undefined variables.
Added some slightly more useful command-table errors.
Don't return a value from map-over-command-menu-items (was trickling down to make lookup-keystroke-item return nonsense in the case where lookup failed).
When reading commands for `command-or-form', use the command history.
When doing sub-accepts for `command-or-form', inherit the history of the `command-or-form' type.
Rename the class MENU-ITEM to %MENU-ITEM, so that it doesn't clobber the MENU-ITEM presentation type. This is important because we want menus to supersede any inner accepts in READ-FRAME-COMMAND, so the MENU-ITEM presentation type must not have applicable translators to any inner type, including EXPRESSION or FORM. (Fixes menus in the Listener)
Moved `display-command-table-menu' to menu.lisp and implemented `display-command-menu'.
Added portable implementation of `display-command-table-menu'.
Committed changes necessary to support Drei (and non-Goatee input editors at all). Also some indirection permitting run-time selection of editor substrate and the code for :text-editor and :text-field gadgets.
`Lookup-keystroke-item' does not take an :errorp argument according to the spec. And if we really want it to, it should be NIL by default.
In accepting command names textually, suggest only one command per string name, and suggest ones from the child tables in preference. This allows command shadowing to behave as you might expect.
the command-table-error subclasses must handle :format-control and :format-arguments. Make it so, and test for it (and also test that not passing them doesn't lead to an unprintable condition. New test file input-editing, for an invariant I spotted while browsing.
* fix remove-command-from-command-table * add relevant test
Made the command-table-inherit-from slot of command tables setf-able, as per the Franz manual. Changed the default documentation of presentation translators from the presentation object to the name of the translator. If this is too controversial I will back it out. Force the tester of drag-and-drop translators to be definitive; otherwise serious weirdness ensues. Added the functional geometry explorer of Frank Buss and Rainer Joswig, who graciously agreed to it being included, as an application.
Fixed destination highlighting for drag-and-drop translators. Added documentation for dnd translators. Corrected the default value for modifier-state in find-innermost-applicable-presentation and friends. This isn't as big as it looks :)
Move most protocol class definitions into protocol-classes.lisp, which is compiled and loaded early. Some class definitions, which had slot definitions that I didn't have the stomach to tease apart, stayed behind. Replace the presentation documentation state mechanism with updating-output so that other functions / programs can write to the pointer documentation area and not screw things up. We still use the state to actually print the documentation.
According to the CLIM Spec, Chapter 26, accepting-values must be supplied with accept forms that either have unique query-identifiers or unique prompts (query-identifier is derived from prompt if query-id is missing). When the partial command parser is called for commands that have two arguments with the same type, two identical prompts are generated. That is not allowed. Fix by generating a unique query-identifier via gensym in accept-form-for-argument-partial.
- added more DEFGENERICs - fiddled with a few IGNORE declarations - with CMUCL, macros no longer attempt to declare special variables IGNORABLE
Commit untested patch from JQS for command-table-keystroke mapping. Add untested tests for the problem. People with non-mutant mcclim trees and a certain amount of free time would be well advised to run the tests.
Patch from Max-Gerd Retzlaff
Fixed the Help command to not display duplicates i.e., commands accessible via more than one inherited command table. Fixed a bug in command-line-name-for-command; it wasn't looking in inherited command tables. Changed the presentation method for command-name to output the symbol if the command isn't accessable instead of pretending that nothing's wrong and creating a command line name.
Added some improvements to accept-from-string so that random accept methods and default processing are more likely to work with it. Added a null command and null-command presentation type so that the REPL doesn't print something obnoxious when the user enters an empty command. Some fixes to default processing.
Changes to MAKE-PARTIAL-PARSER-FUN and supporting functions. If a command argument is unspecified and there is no default specified for that argument, then don't pass any any :default argument to the corresponding call to ACCEPT. Also, don't modify the variables that hold the return values for the arguments unless the user actually changes the value; this preserves thhe unspecified argument marker. This fixes the bug show-cmd-table-arg.
Bring command table inheritence in line with the 2.2 spec described in the Franz User Manual. All command tables must inherit, one way or another, from global-command-table. Change add-command-to-command-table so that command table designators work too.
Almost-correct fix for keyboard accelerators in inherited command tables.
In the accept method for COMMAND-NAME, bind the frame's command table (using LETF) to the command table argument so that COMMAND-ENABLED checks the right command table.
Improved (fixed) support for keystroke accelerators --------------------------------------------------- File commands.lisp: add-command-to-command-table: When given a keystroke, call add-keystroke-to-command-table. %add-keystroke-item: Changed error handling logic, added support for literal keystroke specifications remove-keystroke-from-command-table: When searching keystroke accelerators, use :test #'equal New function partial-command-from-name, which given a command name produces a command whose requried args are *unsupplied-argument-marker* lookup-keystroke-command-item: Add support for keystroke accelerators which specify only a command name. A partial command is created via partial-command-from-name. Class command-parsers: Added slots required-args and keyword-args, needed in order to construct a partial command. %define-command: Init required/keyword arguments in command-parser object read-command-using-keystrokes: Invoke partial command parser if a partial command is returned. File events.lisp: Add :wheel-up and :wheel-down to key-modifier-state-match-p button mapping. (This has been sitting around my tree for months, but somehow never got committed..) File frames.lisp: In read-frame-command, supply ':use-keystrokes t' by default. File stream-input.lisp: Factored the bulk of add-gesture-name out into a new function, realize-gesture-spec, which converts modifier names to symbols and does general massaging of the gesture specification. Added translations for :wheel-up, :wheel-down device names, which have also been sitting around my tree for months. realize-gesture-spec: Don't signal an error if the device-name is not found in +name-to-char+, doing so would preclude the use of port-specific keyboard gestures. %event-matches-gesture: In the method specialized on key-press-event and gesture type :keyboard, compare against the key-name of the event when there is no key-character available, so that we can match keys/gestures outside the CL character set via device names. event-matches-gesture-name-p: Added the ability to match against other than defined gesture-names. Specifically, it can now match against a 'physical' gesture-spec of the form (type device-name modifier-state). Matching against characters is also supported. Fix random typo. Misc changes ------------ recording.lisp: Comment on 'constructor' arg to invoke-with-output-recording-options, use of untransform on rotation angles. table-formatting.lisp: Supply required 'constructor' arg, which was missing.
apply the SciGraph patch from Raymond Toy
Implement command-enabled and (setf command-enabled). This includes a test in command presentation translators that checks if the command is currently enabled. Menu items are disabled if the command is disabled, though buttons on menu bars aren't handled yet. Created a command com-describe-presentation that can be enabled/disabled seperately from com-describe.
Changed the way defaults are handled by accept. I added a mixin class to standard-input-editing-stream, empty-input-mixin; an around method on stream-read-gesture; and some supporting macrology (handle-empty-input) to detect "empty" input and throw control to the appropriate place. Accept-1 now uses handle-empty-input to determine if it should return the default value. This means that the accept methods no longer need to do anything with their :default argument unless they use it for merging. I removed the :default and :default-type arguments from many accept methods all over McCLIM. Fixed a bad bug in the basic input editing loop (stream-read-gesture): rescanning-p should be set to nil when the scan-pointer reaches the fill pointer (not the insertion-pointer). Fixed a small bug in make-gf-specialized-ptype, a support function for com-show-generic-function.
Fix command menu bug (Fred Gilham)
2004-03-24 Timothy Moore <firstname.lastname@example.org> * INSTALL.OPENMCL: updated instructions. * builtin-commands.lisp (default-translator): Return the presentation type of the presentation as the second value. (document-form-translator): New function (%frob-constant-form, %frob-form): Use document-form-translator. Add translators from standard-object to expression and form. (expression-as-form): Add a menu entry for this translator. (ccl::%read-list-expression, (accept expression t textual-view), read, read-preserving-whitespace): Move the Lisp form reader stuff from the ptype 'form to the ptype 'expression. Disallow any activation or delimiter gestures while reading an expression. * commands.lisp (command-name-from-symbol): Don't strip leading subsequences of "COM-" from the command name. (keyword-arg-name-from-symbol): New function. (command-parsers): Add argument-unparser slot (make-keyword): New function (make-key-accessors): Use it. Accept keynames that begin with a #\: and have dashes replaced by spaces. (make-unprocessor-fun) New function to create an unprocessor function for each command. (%define-command): New macro preserving old behavior. Use new unprocessor stuff. (output-destination, invoke-with-standard-output): New class and generic function for outputing the results of commands to an output stream. (define-command): Implement :provide-output-destination-keyword (command-line-unparser): Call new stuff instead. * dialog.lisp: Add (redundant):provide-output-destination-keyword keyword argument to some commands. * incremental-redisplay.lisp: Work in progress. Turn things inside-out. * input-editing.lisp (complete-input): Don't insert input when mode is :complete and we've failed. * presentation-defs.lisp (accept-1): Use multiple-value-list when looking at results of accept method. ((present t completion t t)): Use the arguments to the type to drive the present method here. ((accept sequence t textual-view)): Don't peek-char initially! It breaks accepting the first element via mouse click. (accept sequence-enumerated t textual-view): new method. * recording.lisp : Cosmetic fixups. * regions.lisp (ellipse-normal-radii*): Add Gilbert's English translation of the comment and clean up the function. * system.lisp: Add Goatee/presentation-history. * transforms.lisp (+identity-transformation+): Move earlier in the file to avoid a warning. * utils.lisp (delete-1, parse-lambda-list): new functions. * Apps/Listener/dev-commands.lisp : Add :provide-output-destination-keyword argument to many commands. ((presentation-type generic-function)): Rewrite. Make it inherit from t, add accept method. The type of the object is generic-function, not the name or something. ((presentation-type standard-generic-function), (presentation-type method), (presentation-type standard-method)): add. (Show Generic Function): All-singing all-dancing command for exploring generic functions and their methods. ((presentation-type package)): New type with completing accept method. (Set Package): New command * Apps/Listener/listener.lisp (run-frame-top-level): Add bindings for all the Common Lisp reader and printer variables. * Apps/Scigraph/dwim/macros.lisp (define-command): Add :provide-output-destination-keyword support for McCLIM. * Goatee/goatee-command.lisp (lookup-gesture-command): Disable annoying debugging output. * Lisp-Dep/fix-openmcl.lisp (:clim-mop): In OpenMCL 0.14 use and export all symbols from :openmcl-mop. (compute-applicable-methods-using-classes): Hack for the listener.
Prompt for arguments in menu commands. Work in progress on the OpenGL backend. Merged Dan Barlow's SBCL condition variable changes for event queues and provide a reasonable implementation of condition variables for the implementations. This means no more busy-waiting. I've tested the OpenMCL version and will test the CMUCL implementation shortly; I haven't tested ACL or no multiprocessing. I've looked at LispWorks but don't know yet how to support condition variables there.
Cleaned up the frame layout code. It's now possible to change layouts on the fly. Got rid of frame-pane and replaced it with a proper definition of frame-panes that conforms to the Spec. All the frame pane and layout functions in the spec should be implemented now. In presentation-replace-input, checked in a fix that I thought was already in.
tiny fixes to presentation history
Presentation histories. The new goatee command C-M y works reasonably well in the listener demo. More testing and user documentation is needed. Work in progress on the OpenGL backend.
Implemented command-or-form presentation type. Fixed stupid-subtypep so OR presentation types can be used in with-input-context. Changed the subform reader stuff to use a presentation type option instead of the presentation type subform. Got rid of subform altogether. Changed the Lisp presentation types to be a subtype of expression, not form; added a presentation translator from expression to form that does necessary quoting. Fixed passing of arguments to the frame-top-level function. Moved the menu-item stuff in read-frame-command into an :around method so that read-frame-command can be usefully overridden by users. Cleaned up the listener demo: got rid of the top level loop parts that are now redundant. Added a frame slot and an argument to run-listener/run-listener-process to control whether or not to use CLIM command-or-form processing (the default is the existing method.)
Fixed Goatee problem with the area not being drawn initially. Implement :move-cursor option to surrounding-output-with-border. Use surrounding-output-with-border in accepting-values to make better-looking entry fields. Establish an abort restart in default-frame-top-level. Paul Werkowski's fix for menu command names. Added Raymond Toy's note about CLX and CMUCL.
Some cleanup and missing functions
Set up an input context for commands when there's no interactor pane. Be more liberal in accepting clause arguments for tracking-pointer. Translate from CLIM line-cap names to XLIB names.
Fix to partial argument processor. It now seems to work. Added silly two-argument command to the listener. Take in-package form out of progn in fix-openmcl.lisp.
Christophe Rhodes' improved defgeneric definitions. Early work on the partial command processor.
fix map-over-command-table-menu-items per Milan Zamazal
Added a call to EAT-DELIMITER-OR-ACTIVATOR after each keyword accept so that it's possible to escape from keyword input in the command processor.
Due to popular demand we spit FORMAT-style debugging messages out to *trace-output* instead of *debug-io*
COMMAND-ACCESSIBLE-IN-COMMAND-TABLE-P takes a command table designator, so added a call to FIND-COMMAND-TABLE before calling COMMAND-TABLE-INHERIT-FROM.
Change presentation-subtypep for command-name and command. See comment above command-table-inherits-from-p. Change menu code to throw menu-item presentation types instead of commands; accept that in read-frame-command. The menutest example works again, although the highlighting is a bit broken. clim-fig's menus don't work yet; I need to figure out why clim-fig still needs its own top-level to work.
Squashed a warning in define-command's expansion.
Fix for keyword args to commands, where no value other than nil would ever be received for any keywords. Due to a return-from (block activated..) inside the key acceptor, the (setq ,key-results ...) never occured, and key-results remained empty. Fixed by removing the setq entirely. Instead of the expansion from make-key-acceptors creating its own gensym and binding for key-results, it now receives the gensym from make-argument-accept-fun so it can share the same binding used there, and stores the results directly.
make all of the package names passed to in-package be lowercase keywords for ACL's java mode
3 sets of additions/changes/fixes: presentation-replace-input Bugs I fixed while at ILC, including implementing accept-from-string. Fixes made in the course of getting cl-reversi to work (it mostly does modulo display timing issues). This includes a revamping of command tables, menus and keystrokes.
Commit of patch submitted my Oliver Markovic. Original message: Message-ID: <email@example.com> From: Oliver Markovic <firstname.lastname@example.org> To: email@example.com Subject: Protocol Classes Date: Sat, 09 Nov 2002 22:06:50 +0100 Hi, Attached is a patch, which uses DEFINE-PROTOCOL-CLASS for all protocol classes as defined in the spec (not all were using that macro). I also added simple docstrings to the macro and changed the error message to something more civil :-) This should also add some required predicates, which were missing. I also noticed that protocol classes were given slots contradicting the definition in 2.5: "A protocol class is an "abstract" class with no slots and no methods (except perhaps for some default methods) [...]". But I guess that's no serious deviation from the spec though. greetz, -- Oliver Markovic
language support for text-styles, korean font support, support for 16 bit fonts, support for font composition, support for timer events, some cosmetic changes, support for unicode characters, etc. A bit much at once, and hopefully it won't break for anyone who isn't using unicode enabled cmucl.
Uncommented menu-choose.lisp from the system definition. I'm using it so it's not experimental, damn it :) Possibilities gestures for command completion. C-/ and right mouse bring up possibilities menus. Make user-command-table inherit from global-command-table. Implement keyword arguments in commands. Implement the "read" part of the pointer protocol. Added accept method for sequence presentation type. Change handling of *null-presentation*. This isn't traversed in find-applicable-translators / map-applicable-translators anymore; it's handeld in find-innermost-presentation-match. Gave a raised appearance to menus drawn with menu-choose and friends. Someone who knows what they're doing should look over what I did. Steps towards implementing line wrap in Goatee. Fixed bug in insert-obj-before pointed out by someone on IRC.
don't set :acceptably to T
* MAKE-COMMAND-TRANSLATORS generates documentation.
* Mistyping fixed. * PARTIAL-COMMAND-P: Implemented.
Multiline display now works in Goatee. The redisplay algorithm leaves a lot to be desired, but is serviceable for small areas. Baby steps towards incremental redisplay.
Fixes to the presentation type system, including some MOP hacking, to bring the presentation type lattice in line with the Spec. In particular, form and expression are supertypes of all Lisp types, including implicit CLOS types. Presentation method dispatch, presentation-subtypep, map-over-presentation-type-supertypes, etc. all implement this lattice. I think we're doing a better job than real CLIM in this respect. Broke out presentation type and method definitions into presentation-defs.lisp so that less stuff needs to be wrapped in eval-when.
Presentation translators, including define-presentation-to-command-translator and command translators generated by the :gesture option in define-command arguments. With this checkin the address book demo mostly works as intended, except for creating new address book entries. Added builtin-commands.lisp to hold global commands and presentation translators. Added a nifty help command with context sensitive command names.
clean up a bunch of ACL compiler warnings
These changes have been tested in ACL as well as CMUCL. * Lisp-Dep/fix-acl.lisp, Lisp-Dep/fix-cmu.lisp, Lisp-Dep/fix-sbcl.lisp: (defclass, compile-time-clos-class-p): Patch defclass to record CLOS classes at compile time. * presentations.lisp (compile-time-clos-p): Use the above when defined. * presentations.lisp (accept-using-completion): Helper function that defaults empty completion input. (method accept boolean): Use accept-using-completion. (method accept completion): Implement. * input-editing.lisp (stream-read-gesture): Don't loop doing stream-process-gesture when stream-read-gesture of encapsulated stream returns nil. (complete-input): Some tweaks to deal with "empty" input. * commands.lisp (make-argument-accept-fun, command-line-command-parser, read-command): Adjustments to deal with empty arguments. (com-help): Add gratuitous argument to test accept of completion presentation type and defaults. * Goatee/flexivector.lisp (method print-object (flexivector t)): Add missing stream argument to write-char. * Goatee/buffer.lisp: (method (setf point*) (t t basic-buffer-mixin), method buffer-close-line* (basic-buffer-mixin t t), method delete-char (basic-buffer), (method forward-char* (basic-buffer t), method buffer-close-line* :around (bp-buffer-mixin bp-buffer-line t)): Various bug fixes made in the course of doing replace-input in a multiline buffer.
commands.lisp (make-argument-accept-fun): Wrap in eval-when (:compile-toplevel). input-editing.lisp (complete-input): Tweak to preserve the ending delimiter. presentations.lisp: accept method for boolean.
Major new functionality: command processing with completion. Check out the address-book demo. In it, all commands are available on the command line. Completion and editing work. Prompts for input show up on *debug-io* for now, but otherwise command input is accepted from presentations. 2002-05-08 Tim Moore <firstname.lastname@example.org> * commands.lisp: Implemented the magic argument parser function for commands. Defined presentation types for command-name and command, as well as present and accept methods for them. (command-line-parser, command-line-unparser): Implemented. (define-command): Changed the :name argument to define-command to default to t which goes against the spec; this gives us some interesting command line parsing in the address book demo. I'll change it back when we have presentation translators. * frames.lisp (default-frame-top-level): changed default prompt to "Command: ". Don't echo results of commands. (execute-frame-command): Apply command name to command arguments like the spec says. * input-editing.lisp (stream-read-gesture): set rescanning to nil after reading a new gesture from the underlaying stream. (with-delimiter-gestures): Implement. (input-editor-format): Direct output to *debug-io* for now. (read-token): Handle null gestures, which shouldn't happen, but might after a stream is activated. (simple-parse-error): Fix :format-control initarg. (*completion-gestures*, simple-completion-error, complete-input, complete-from-generator, complete-from-possibilities, completing-from-suggestions): Implement. * ports.lisp (distribute-event): Change sheet of keyboard events to the sheet with input focus. * presentations.lisp (fake-params-args): Generate dummy args for optional and keyword arguments so their defaults don't need to be evaluated at compile time. (define-presentation-method): Set up a block with the same name as the method around the method body. (method presentation-typep): default method. (method presentation-type-of (standard-object)): Don't fail if the presentation type has no parameters. (method description (standard-class)): Add. (highlight-applicable-presentation): Don't pass through button events to the stream; handle them here. (accept): Provide a default :default-type argument if :default is specified. (method stream-accept (standard-input-editing-stream)): add. (accept-1): Respect replace-input argument. (prompt-for-accept): Work on any stream. (prompt-for-accept-1): Tweak default prompt for recursive accept. (method present): Define default method. (accept-using-read): Take read-eval as an argument. (method accept): Define default method. (presentation-method presentation-type-of (string)): Return a more general result. * stream-input.lisp (gesture-name command-delimiter): Define. * system.lisp: Reenable the address book demo. * Backends/CLX/port.lisp (method realize-mirror (clx-port application-pane)): Add to register for pointer motion events. * Goatee/buffer.lisp: Added buffer pointers, which maintain their relative position across inserts and deletes. (bp-buffer-mixin, bp-buffer-line): Classes for buffer pointers. Added all the buffer protocol functions for buffer pointers. * Goatee/editing-stream.lisp (location*-offset*): Old offset-location* :) (offset-location*) New function to return a stream offset from a buffer location. (replace-input): Rewrite to preserve insertion pointer, using buffer pointers. * Goatee/goatee-command.lisp: Add #\tab as an insertable character.
Sundry fixes to run without multiprocessing support. Added images/ to hold bitmaps for tests. Added looks/ to hold neutral look-and-feel realizer packages. Added Examples/gadget-test to test many gadgets with a look and feel. Added a pixie look and feel, and a pixie/clx to work with the clx backend. Added drawing support in the CLX backend for ovals and circles. Fixed pixmaps to work with with-output-to-pixmap with draw-image, etc. Moved sheet-leaf-mixin to standard-gadget-pane so it doesn't break radio-box-pane, etc. Misc fixes.
change generate-name to command-name-from-symbol
Fix to DEFINE-COMMAND in an attempt to get CLIM-FIG working.
added define-frame-command and define-command support - still doesn't define the unnamed parser function
Fixed spelling error documetation -> documentation found by my students.
Implement extended input streams, stub of input editing streams and enough of encapsulating streams to support input editing. A few random bug fixes too.
remove compiler warnings for ACL
Added code for command tables.
This form allows you to request diffs between any two revisions of this file. For each of the two "sides" of the diff, select a symbolic revision name using the selection box, or choose 'Use Text Field' and enter a numeric revision.
|Powered by ViewVC 1.1.5|