|Browse all patches|
(Uploaded by Christopher Bratusek)
Sawfish-ui is not "accessible" currently.
Provide "atk" relation between widgets and corresponding labels.
There are two patches one for sawfish and one for rep-gtk.
Patch testing Edit
- Copy/paste the patch listed below into some file, eg.
- If you don't have sawfish sources yet, have one, as described get it from GIT repo.
- Go into the directory where sawfish sources reside, eg.
- Test if the patch applies cleanly with this command:
patch -p1 --ignore-whitespace --dry-run < TEST.diffin case of problems try also:
- If it applies cleanly, then remove the
--dry-runfrom above command and run it again, otherwise ask on the mailing list.
- Compile sawfish:
./autogen.sh && make
- Install it for testing, but it depends on your linux distribution.
- It is always better to install sawfish as your distribution package, but it is different for each distribution.
- So you may try
make install, which will install sawifish in
/usr/local/share/sawfish/(if you have write access). But then make sure that you run the correct version and delete it from that directory afterwards, to avoid any conflicts.
- Se also
PS: edit this template if you feel that those instructions can be improved.
Patch for Sawfish
--- sawfish/lisp/sawfish/ui/layouts/keymaps.jl Mon Apr 1 14:03:00 2002 +++ sawfish-new/lisp/sawfish/ui/layouts/keymaps.jl Wed May 15 13:50:33 2002 @@ -31,6 +31,8 @@ sawfish.ui.layout sawfish.gtk.widget) + (defvar label-ptr nil) + (define (keymap-slot-p slot) ;; XXX so fucking evil! (string-match "-keymap$" (symbol-name (slot-name slot)))) @@ -48,8 +50,10 @@ (active (car keymap-slots))) (when keymap-slots - (gtk-box-pack-start hbox (gtk-label-new (_ "Context:"))) + (setq label-ptr (gtk-label-new (_ "Context:"))) + (gtk-box-pack-start hbox label-ptr) (gtk-box-pack-start hbox omenu) + (gtk-widget-relate-label omenu label-ptr) (gtk-box-pack-start vbox hbox) (let loop ((rest keymap-slots) --- sawfish/lisp/sawfish/ui/layout.jl Wed Feb 13 13:23:07 2002 +++ sawfish-new/lisp/sawfish/ui/layout.jl Wed May 15 15:57:30 2002 @@ -36,6 +36,10 @@ sawfish.gtk.widget) (access rep.structures)) + (defvar widget-ptr nil) + (defvar label-ptr nil) + (defvar tempstring nil) + (define (define-layout-type name fun) (put name 'nokogiri-layout fun)) (define (layout-type name) @@ -124,14 +128,21 @@ (break (if (string-match "\\\\w" doc) (match-start) -2))) + (setq widget-ptr (slot-gtk-widget slot)) (when (> break 0) - (gtk-box-pack-start hbox (make-label (substring doc 0 break)))) + (setq label-ptr (make-label (substring doc 0 break))) + (gtk-box-pack-start hbox label-ptr) + (gtk-widget-relate-label widget-ptr label-ptr)) (if (memq 'expand-horizontally (slot-flags slot)) - (gtk-box-pack-start hbox (slot-gtk-widget slot) t t) - (gtk-box-pack-start hbox (slot-gtk-widget slot) nil nil)) + (gtk-box-pack-start hbox widget-ptr t t) + (gtk-box-pack-start hbox widget-ptr nil nil)) (when (< break (length doc)) - (gtk-box-pack-start - hbox (make-label (substring doc (+ break 2))))) + (setq tempstring (substring doc (+ break 2))) + (if (> (length tempstring) 0) + (progn + (setq label-ptr (make-label tempstring)) + (gtk-box-pack-start hbox label-ptr) + (gtk-widget-relate-label widget-ptr label-ptr)))) (setq hbox (add-tooltip hbox)) (gtk-widget-show-all hbox) hbox)))))) --- sawfish/lisp/sawfish/ui/widgets/frame-style.jl Mon Apr 1 14:03:01 2002 +++ sawfish-new/lisp/sawfish/ui/widgets/frame-style.jl Wed May 15 13:11:29 2002 @@ -41,6 +41,7 @@ (value (car options)) (last-value nil)) + (gtk-widget-relate-label combo doc-label) (gtk-box-set-spacing hbox box-spacing) (gtk-box-set-spacing vbox box-spacing) (gtk-container-add readme-scroller readme-text-view)
Patch for rep-gtk
- already in SVN **
Community's reasons for inclusion or rejection Edit
Patch submitters, please vote also! Yes, obviosuly your vote will be positive, but it's the place to give your explanation why this patch is good for all Sawfish users, and why it is correct - good reasons for inclusion.
When voting anonymously please write your name, so that it can be associated with your posts on the mailing list. If you are logged in you can sign yourself by typing four tilda characters: ~~~~.
- vote: yes.: Uploaders comment: Better a11y is good and if the patch is O.K. it should be commited. Flashrider [Christopher Bratusek] 06:00, 23 July 2008 (UTC)
- Ok I just had some time to test the patch. It does not cause any side-effects as far as I can see.Flashrider [Christopher Bratusek] 06:16, 23 July 2008 (UTC)
- wait for next release. Suspend for next release. We will mark this patch as Category:Submitted patches after we make release of new rep-gtk. Janek Kozicki 13:45, 4 August 2008 (UTC)
- vote: let's try in experimental. rep-gtk patch is in trunk, so you can try this one out. Flashrider [Christopher Bratusek] 02:47, 29 September 2008 (UTC)
- vote: pondering. how could I test this patch? And what is 'atk'? :) Janek Kozicki 15:47, 21 November 2008 (UTC)
- atk is the "GTK+ Accessibility ToolKit" it's needed by GNOME/GTK+ to provide advanced a11y functions. ... Perhaps trying out GNOMEs a11y-apps with and without that patch helps you Flashrider [Christopher Bratusek] 15:55, 21 November 2008 (UTC)
- well, I trust you with this patch. But I'm unable to test this currently - I'll have some time on Febrauary - not sooner :/ Janek Kozicki 21:18, 26 November 2008 (UTC)
- vote: pondering. Could you wait for days?
First, I'm seeking the way to trigger patched part of the code. Simple invocation of the configurator GUI doesn't, at least of .../ui/layouts/keymap.jl. (If someone knows it, please tell us.)Second, it seems that 'defvar' should be replaced by 'let', but I'm not sure yet. I've obtained related tutorials, so I will judge this point, too. (Or Timo's word would make it definite...) - Teika kazura 11:30, 27 November 2008 (UTC)
- - Sorry, I mistook. The patched code is certainly executed. (I didn't know that UI's stdout/stderr is >/dev/null.) So the stability must be OK if Chris doesn't find it. - Teika kazura 06:04, 29 November 2008 (UTC)
- vote: yes. commited rev4310 ... about the defvar -> let thing: If really nessacary, we can still change it. Flashrider [Christopher Bratusek] 22:30, 29 November 2008 (UTC)