emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Custom themes


From: Luc Teirlinck
Subject: Re: Custom themes
Date: Sat, 25 Jun 2005 13:00:51 -0500 (CDT)

         But, by experimentation, I was able to figure out
       what it currently actually does: it writes files into random
       directories all over your file system without warning.

   That is a rather vague description of the behavior.
   Perhaps you're describing a bug where it writes
   a file into the wrong directory.  If so, can you fix it?

It writes a file into the current directory, which to me does
definitely not seem like the right thing to do for a command like
`customize-create-theme'.  It should write the file into the directory
where these files belong.  I can not possibly fix it, because I have
no idea what directory that is.  The user's home directory?  I do not know.

Here is a list of problems with `customize-create-theme':

1.  The buffer it creates fails to give anywhere close to appropriate
    usage guidance.

2.  The command does things that for most purposes feel like putting
    the buffer in a given major mode, except that it does not run a
    mode hook, nor `after-change-major-mode-hook'.  For instance, it
    calls `kill-all-local-variables' and `use-local-map'.  But instead
    of actually defining and calling a major mode, it kind of
    "inlines" the call to the unofficial major mode.  The buffer ends
    up "officially" in Fundamental Mode, so you can not get info about
    the "hidden" real mode, using `C-h m'.  Because of the
    `use-local-map' call the buffer does not feel like "Fundamental
    Mode".  Because after-change-major-mode-hook has not been called,
    it is not _really_ in Fundamental Mode.  It is in _no_ major mode.
    That is not good.  It could create problems, for instance for
    minor modes defined with define-global-minor-mode.

3.  If now you click on "Done", a second buffer with the tentative
    theme file appears.  It is marked modified and apparently not
    saved to disk.  I believe it should have been either saved to disk
    in the appropriate place, or there should be some message saying
    that saving the file will save it to the appropriate place (and of
    course, that message should not be a lie).

4.  It is a .el file.  The buffer should be in Emacs Lisp mode, but it
    is in Fundamental mode.

5.  You wonder what to do.  You want to save your file, so you do C-x
    C-s, what else?  But that saves it in the current directory, which
    is still the directory that was current when you called
    `customize-create-theme', which may not be an appropriate place
    for theme files.  If you do not pay attention and continue with
    other work, you may have to run `find' to find the file back.  I
    believe that the second buffer's current directory should be the
    directory for saving theme files (whatever directory that is).

Sincerely,

Luc.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]