diff options
author | ppedrot <ppedrot@85f007b7-540e-0410-9357-904b9bb8a0f7> | 2012-04-27 15:31:30 +0000 |
---|---|---|
committer | ppedrot <ppedrot@85f007b7-540e-0410-9357-904b9bb8a0f7> | 2012-04-27 15:31:30 +0000 |
commit | bbf334b38ae4c57b4d619a8f98acc488077efca4 (patch) | |
tree | 91b013df3287c9a806971c1b8c47c5c519125a0f | |
parent | 9af3413edd3c82e99766bb3c2541d1cf8920c006 (diff) |
Removed the quasi-useless gtk2rc file and the documentation that went with it. Now CoqIDE is not anymore totally irrespectful of the local configuration of themes, in particular w.r.t. to menu fonts.
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@15251 85f007b7-540e-0410-9357-904b9bb8a0f7
-rw-r--r-- | Makefile.build | 4 | ||||
-rw-r--r-- | doc/faq/FAQ.tex | 40 | ||||
-rw-r--r-- | doc/refman/RefMan-ide.tex | 16 | ||||
-rw-r--r-- | ide/FAQ | 25 | ||||
-rw-r--r-- | ide/coqide-gtk2rc | 39 | ||||
-rw-r--r-- | ide/coqide_main.ml4 | 8 |
6 files changed, 19 insertions, 113 deletions
diff --git a/Makefile.build b/Makefile.build index 793c60690..086587a9d 100644 --- a/Makefile.build +++ b/Makefile.build @@ -285,7 +285,7 @@ COQIDEFLAGS=-thread $(COQIDEINCLUDES) .SUFFIXES:.vo -IDEFILES=ide/coq.png ide/coqide-gtk2rc ide/mac_default_accel_map +IDEFILES=ide/coq.png ide/mac_default_accel_map coqide-binaries: coqide-$(HASCOQIDE) coqide-no: @@ -338,7 +338,7 @@ install-ide-files: $(MKDIR) $(FULLDATADIR) $(INSTALLLIB) ide/coq.png $(FULLDATADIR) $(MKDIR) $(FULLCONFIGDIR) - $(INSTALLLIB) ide/coqide-gtk2rc $(FULLCONFIGDIR) + $(INSTALLLIB) $(FULLCONFIGDIR) if [ $(IDEOPTINT) = QUARTZ ] ; then $(INSTALLLIB) ide/mac_default_accel_map $(FULLCONFIGDIR)/coqide.keys ; fi install-ide-info: diff --git a/doc/faq/FAQ.tex b/doc/faq/FAQ.tex index 0bd84992b..b5a4c160d 100644 --- a/doc/faq/FAQ.tex +++ b/doc/faq/FAQ.tex @@ -2342,20 +2342,13 @@ rendering tool provided by the server (see \Question{How to enable Emacs keybindings?} -Depending on your configuration, use either one of these two methods - -\begin{itemize} - -\item Insert \texttt{gtk-key-theme-name = "Emacs"} - in your \texttt{coqide-gtk2rc} file. It should be in - \verb#$XDG_CONFIG_DIRS/coq# dir. This is done by default. - -\item If in Gnome, run the gnome configuration editor (\texttt{gconf-editor}) +If in Gnome, run the gnome configuration editor (\texttt{gconf-editor}) and set key \texttt{gtk-key-theme} to \texttt{Emacs} in the category \texttt{desktop/gnome/interface}. -\end{itemize} - +Otherwise, you need to find where the \verb#gtk-key-theme-name# option is located in +your configuration, and set it to \texttt{Emacs}. Usually, it is in the +\verb#$(HOME)/.gtkrc-2.0# file. %$ juste pour que la coloration emacs marche @@ -2406,33 +2399,14 @@ keycode 26 = e E e E U2203 NoSymbol U2203 NoSymbol \end{verbatim} and then run xmodmap ~/.xmodmaprc. - Alternatively, if your version of \verb=xmodmap= does not support unicode, you need to use something like -\begin{verbatim} -xmodmap -e "keycode 24 = a A F13 F13" -xmodmap -e "keycode 26 = e E F14 F14" -\end{verbatim} - and then to add - -\verb=bind "F13" {"insert-at-cursor" ("=$\forall$\verb=")}=\\ -\verb=bind "F14" {"insert-at-cursor" ("=$\exists$\verb=")}= - - to your "binding "text"" section in \verb#coqiderc-gtk2rc#. - The last arguments to {\tt bind} between "" are - the UTF-8 encodings for 0x2200 and 0x2203. - You can compute these encodings using the lablgtk2 toplevel with -\begin{verbatim} -Glib.Utf8.from_unichar 0x2200;; -\end{verbatim} - Further symbols can be bound on higher Fxx keys or on even on other keys you - do not need . -\end{itemize} + Alternatively, you may use an input method editor such as SCIM or iBus. +The latter offers a \LaTeX-like input method. \Question{How to customize the shortcuts for menus?} Two solutions are offered: \begin{itemize} \item Edit \verb+$XDG_CONFIG_HOME/coq/coqide.keys+ (which is usually \verb+$HOME/.config/coq/coqide.keys+) by hand or -\item Add "gtk-can-change-accels = 1" in your coqide-gtk2rc file. Then - from \CoqIde, you may select a menu entry and press the desired +\item If your system supports it, from \CoqIde, you may select a menu entry and press the desired shortcut. \end{itemize} diff --git a/doc/refman/RefMan-ide.tex b/doc/refman/RefMan-ide.tex index f061ef18d..e0c6c868f 100644 --- a/doc/refman/RefMan-ide.tex +++ b/doc/refman/RefMan-ide.tex @@ -209,21 +209,11 @@ Notice that these settings are saved in the file \verb|.coqiderc| of your home directory. A gtk2 accelerator keymap is saved under the name \verb|.coqide.keys|. -This file should not be edited manually: to modify a given menu +It is not recommanded to edit this file manually: to modify a given menu shortcut, go to the corresponding menu item without releasing the mouse button, press the key you want for the new shortcut, and release -the mouse button afterwards. - -For experts: it is also possible to set up a specific gtk resource -file, under the name \verb|.coqide-gtk2rc|, following the gtk2 -resources syntax -\url{http://developer.gnome.org/doc/API/2.0/gtk/gtk-Resource-Files.html}. -Such a default resource file can be found in the subdirectory -\verb=lib/coq/ide= of the root installation directory of \Coq{} -(alternatively, it can be found in the subdirectory \verb=ide= of the -source archive of \Coq{}). You may -copy this file into your home directory, and edit it using any text -editor, \CoqIDE{} itself for example. +the mouse button afterwards. If your system does not allow it, you may still +edit this configuration file by hand, but this is more involved. \section{Using unicode symbols} @@ -6,8 +6,8 @@ R0: A powerfull graphical interface for Coq. See http://coq.inria.fr. for more i Q1) How to enable Emacs keybindings? R1: Insert gtk-key-theme-name = "Emacs" - in your "coqide-gtk2rc" file. It should be in $XDG_CONFIG_DIRS/coq dir. - This is done by default. +in your gtkrc file. The location of this file is system-dependent. If you're running +Gnome, you may use the graphical configuration tools. Q2) How to enable antialiased fonts? R2) Set the GDK_USE_XFT variable to 1. This is by default with Gtk >= 2.2. @@ -34,27 +34,14 @@ R5)-First solution : type "<CONTROL><SHIFT>2200" to enter a forall in the script 2200 is the hexadecimal code for forall in unicode charts and is encoded as "∀" in UTF-8. 2203 is for exists. See http://www.unicode.org for more codes. --Second solution : rebind "<AltGr>a" to forall and "<AltGr>e" to exists. - Under X11, you need to use something like - xmodmap -e "keycode 24 = a A F13 F13" - xmodmap -e "keycode 26 = e E F14 F14" - and then to add - bind "F13" {"insert-at-cursor" ("∀")} - bind "F14" {"insert-at-cursor" ("∃")} - to your "binding "text"" section in coqiderc-gtk2rc. - The strange ("∀") argument is the UTF-8 encoding for - 0x2200. - You can compute these encodings using the lablgtk2 toplevel with - Glib.Utf8.from_unichar 0x2200;; - Further symbols can be bound on higher Fxx keys or on even on other keys you - do not need . +-Second solution : Use an input method editor, such as SCIM or iBus. The latter offers +a module for LaTeX-like inputting. Q6) How to customize the shortcuts for menus? R6) Two solutions are offered: - Edit $XDG_CONFIG_HOME/coq/coqide.keys by hand or - - Add "gtk-can-change-accels = 1" in your coqide-gtk2rc file. Then - from CoqIde, you may select a menu entry and press the desired - shortcut. + - If your system allows it, from CoqIde, you may select a menu entry and press the + desired shortcut. Q7) What encoding should I use? What is this \x{iiii} in my file? R7) The encoding option is related to the way files are saved. diff --git a/ide/coqide-gtk2rc b/ide/coqide-gtk2rc deleted file mode 100644 index 9da99551b..000000000 --- a/ide/coqide-gtk2rc +++ /dev/null @@ -1,39 +0,0 @@ -# Some default functions for CoqIde. You may copy the file in $XDG_CONFIG_HOME -# ($HOME/.config/coq/) and edit as you want. See -# http://developer.gnome.org/doc/API/2.0/gtk/gtk-Resource-Files.html -# for a complete set of options -# To set the font of the text windows, edit the .coqiderc file through the menus. - -gtk-key-theme-name = "Emacs" - -#pixmap_path "/home/" - -binding "text" { - bind "<ctrl>k" { "set-anchor" () - "move-cursor" (display-line-ends,1,0) - "move-cursor" (visual-positions,1,0) - "cut-clipboard" () - } - bind "<ctrl>w" { "cut-clipboard" () } - -# For UTF-8 inputs ! -# bind "F11" {"insert-at-cursor" ("∀")} -# bind "F12" {"insert-at-cursor" ("∃")} -} -class "GtkTextView" binding "text" - - -gtk-font-name = "Sans 12" - -style "location" { -font_name = "Sans 10" -} -widget "*location*" style "location" - - -gtk-can-change-accels = 1 - -style "men" { -# -} -widget "GtkMenu" style "men" diff --git a/ide/coqide_main.ml4 b/ide/coqide_main.ml4 index db2b2361c..1e71b8da4 100644 --- a/ide/coqide_main.ml4 +++ b/ide/coqide_main.ml4 @@ -67,13 +67,7 @@ END let () = Coqide.ignore_break (); ignore (GtkMain.Main.init ()); - initmac () ; - (try - let gtkrcdir = List.find - (fun x -> Sys.file_exists (Filename.concat x "coqide-gtk2rc")) - Minilib.xdg_config_dirs in - GtkMain.Rc.add_default_file (Filename.concat gtkrcdir "coqide-gtk2rc"); - with Not_found -> ()); + initmac (); (* Statup preferences *) begin try Preferences.load_pref () |