[eclipse-devel] About resize

Luigi Panzeri matley at member.fsf.org
Mon Dec 26 22:42:30 UTC 2005


I started using eclipse from few days and my aim is to get a
configuration such that i have a tiled wm behaviour (ala ratpoison)
only in a screen and for some applications.

In order to do that i have to be able to resize windows, and maybe my
xlib knowledge is too coarse yet to do that. How can i resize windows
in a non-interactively way? 

Thank you and happy new year

P.S. i put here some tools that i have in my config that can be useful
to others

;;; define key combos to start an app, or to raise it if already
;;; started

(defun defcombo-to-select-application (name &key keys modifiers class cmd args)
  (register-callback name (action (:press (select class cmd args)) ()))
  (define-key-combo name 
      :keys keys
      :modifiers modifiers))

;;; e.g.
(defcombo-to-select-application :xterm
    :keys '(:X)
    :modifiers '(:SUPER-LEFT)
    :class "xterm"
    :cmd "xterm"
    :args '("-e" "screen"))

;;; get the trace-output with slime
; (setf swank::*current-trace-output* *standard-output*)

(defun list-applications ()
  (loop for app being the hash-value of *widget-table*
     when (typep app 'application)
     collect app))

(defmacro aif (test truecase elsecase)
  `(let ((it ,test))
     (if it
	 ,truecase
	 ,elsecase)))

(defun select (class-name cmd arguments)
  (aif
   (find class-name (list-applications) 
	 :test #'string-equal :key #'application-class-name)
   (progn
     (change-vscreen *root* :n (window-desktop-num (widget-window it)))
     (put-on-top it))
   (%run-program% cmd arguments)))


-- 
Luigi Panzeri aka Matley

Chiave pubblica su http://www.imati.cnr.it/~panzeri/matley.asc
Why Lisp? http://alu.cliki.net/RtL%20Highlight%20Film
Evaluate Lisp: http://lisp.tech.coop/Evaluate%20Lisp



More information about the eclipse-devel mailing list