changeset 67227:d02e0d3b5db9

(speedbar-default-position): New defcustom. (speedbar-frame-reposition-smartly): Use it.
author Romain Francoise <romain@orebokech.com>
date Wed, 30 Nov 2005 21:15:11 +0000
parents fd62535b63a8
children 2e483fb75450
files lisp/ChangeLog lisp/speedbar.el
diffstat 2 files changed, 14 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/ChangeLog	Wed Nov 30 19:40:13 2005 +0000
+++ b/lisp/ChangeLog	Wed Nov 30 21:15:11 2005 +0000
@@ -1,5 +1,8 @@
 2005-11-30  Romain Francoise  <romain@orebokech.com>
 
+	* speedbar.el (speedbar-default-position): New defcustom.
+	(speedbar-frame-reposition-smartly): Use it.
+
 	* dframe.el (dframe-reposition-frame-emacs): Fix position
 	computation for 'left location.
 	Update copyright year.
--- a/lisp/speedbar.el	Wed Nov 30 19:40:13 2005 +0000
+++ b/lisp/speedbar.el	Wed Nov 30 21:15:11 2005 +0000
@@ -331,6 +331,16 @@
   :group 'speedbar
   :type 'boolean)
 
+(defcustom speedbar-default-position 'left-right
+  "*Default position of the speedbar frame.
+Possible values are 'left, 'right or 'left-right.
+If value is 'left-right, the most suitable location is
+determined automatically."
+  :group 'speedbar
+  :type '(radio (const :tag "Automatic" left-right)
+		(const :tag "Left" left)
+		(const :tag "Right" right)))
+
 (defcustom speedbar-sort-tags nil
   "*If non-nil, sort tags in the speedbar display.  *Obsolete*.
 Use `semantic-tag-hierarchy-method' instead."
@@ -967,7 +977,7 @@
 	(t
 	 (dframe-reposition-frame speedbar-frame
 				  (dframe-attached-frame speedbar-frame)
-				  'left-right))))
+				  speedbar-default-position))))
 
 (defun speedbar-detach ()
   "Detach the current Speedbar from auto-updating.