Subject: mailing-list for TeXmacs Users
List archive
From : Henri Lesourd <address@hidden>- To: address@hidden
- Subject: Re: [TeXmacs] A simple
- Date: Sun, 26 Oct 2008 20:48:35 +0100
Andrea Gamba wrote:
That's very nice!It's easy to find this by yourself: the following recursive grep
Can you possibly explain how to perform a much simpler task, binding Ctrl-+
and
Ctrl-- to decrease/increase the shrinking ratio?
into the TeXmacs codebase:
/home/henri/TeXmacs/TeXmacs/src>grep -R 'Shrin' *|grep scm
TeXmacs/progs/texmacs/menus/preferences-menu.scm: (enum ("Shrinking factor" "shrinking factor")
TeXmacs/progs/texmacs/menus/view-menu.scm: (-> "Shrinking factor"
TeXmacs/progs/texmacs/texmacs/tm-view.scm: (:argument s "Shrinking factor")
/home/henri/TeXmacs/TeXmacs/src>
, then having a look inside view-menu.scm, you find:
(menu-bind view-menu
("Open new window" (open-window))
.................................
("Presentation mode" (toggle-full-screen-mode))
(-> "Shrinking factor"
("1" (set-shrinking-factor 1))
................................
("10" (set-shrinking-factor 10))
---
("Other" (interactive other-shrinking-factor))))
=> thus, the function to use to set the shrinking factor
is: (set-shrinking-factor <VALUE>)
Now, to do what you want, use this function inside the (kbd-map)s
of Christophe's program, and then you are done (inside the '+' handler,
you should increment the shrinking factor, and inside the '-' handler,
you should decrease it. I let the rest as an exercise in Scheme
programming for you. It also turns out that the function to read
the current shrinking factor is (get-shrinking-factor)).
Have fun !
It would be also nice that the window is always centered when zooming in/out.No, there are no Scheme commands to change the alignment
Now it is aligned to the left, do you think it is possible to change this
setting?
of the displayed text inside the window (nor to move or
resize the TeXmacs window, btw).
Best, Henri
- Re: [TeXmacs] A simple, Andrea Gamba, 10/26/2008
- Re: [TeXmacs] A simple, Henri Lesourd, 10/26/2008
Archive powered by MHonArc 2.6.19.