help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: Quite a few emacs questions


From: mowgli
Subject: Re: Quite a few emacs questions
Date: 17 May 2007 12:33:48 -0700
User-agent: G2/1.0

On May 17, 2:07 am, Amy Templeton <amy.g.temple...@gmail.com> wrote:

> CODE:
> ______________________________
>
> (defun eshell/clear ()
>   "Clears the eshell buffer."
>   (interactive)
>   (let ((inhibit-read-only t))
>     (erase-buffer)))
> ______________________________

[snip]

> after the (erase-buffer) command and hit "C-x C-e" (to evaluate the
> code). Then test it out in the eshell buffer.

First of all thanks a ton for the nice detail explanations.

Pressing C-x C-e generates some eval errors that I can't paste here in
firefox since copy/pasting from other apps doesn't seem to work in ff.

But atleast now the clear command in eshell works. Nice

> > How to make eshell work like on full page? Typing any command
> > scrolls half the page to top.
>
> Could you be more specific? I'm not really sure what you mean by
> this. You can go back in the eshell buffer just like any other
> buffer, if that's your question.

Peter got it right I think. I knew my question could confuse. Sorry.
Say that I have a directory listing containing about 20 entries. When
I type ls -l in eshell, I get only the last 10 or so entries. The
below entries that is. The emacs in X, I can easily press Shift Pg-Up
to read the first entries tho this is also a pain. But bad thing is
that in console, Shift Pg-Up in emacs doesn't give you the first
entries in that list.

Now say you have 20 entries in a dir and you type the clear command in
eshell. Now do an ls -l mydir. This results in only the bottom 10
entries. you do ls -l as many times you want but can never see the
topmost 10 entries. How do you fix that? I hope I'm not confusing
again.

 > > I'm just installing w3. Does it support frames like the links or
> > elinks browsers?

> I don't believe so, and neither does emacs-w3m (my browser of
> choice). You might try to look into a comparison of w3 and
> emacs-w3m's features before deciding on one; try googling for each
> one.

I tried using lynx in eshell and it works like a charm. However since
lynx doesn't support frames, I like links or elinks but running these
in eshell just outputs grabage all over the screen and I have to kill
the eshell buffer. If there was a way to run links or elinks, it would
be just great.

> > When using X, how to change the default font used by emacs? It's
> > extremely small.
>
> CODE:
> _________________________________________________________________
>
> (if window-system
>       (set-default-font
>       "-adobe-courier-medium-r-*-*-14-*-100-100-*-*-iso10646-1"))
> _________________________________________________________________

> ...would do this, assuming you wanted that particular font. Enter
> your font of choice.


Works very nicely. Infact I used this same font just with the value of
24 and it's a nice font.

> I'll take these one at a time...
>
> > M-x color-theme xyz
>
> CODE:
> _________________
>
> (color-theme-xyz)
> _________________

[snip]

> CODE:
> ________________________
>
> (if window-system
>       (color-theme-xyz))
> ________________________


> CODE:
> _______________________________________________
>
> (if window-system
>       (color-theme-xyz)
>   (color-theme-your-favorite-for-the-terminal))
> _______________________________________________


Neither of the above works. The acutal command is M-x color-theme-
select , then pressing enter and selecting from the list of themes
normally. But even putting (color-theme-select xyz) gives the
following error in any case:

Symbol's definition function is void : color-theme-euphoria

or

Symbol's definition function is void : color-theme-select-euphoria

euphoria being the theme name.


> CODE:
> _____________________________________________________
>
> (add-to-list 'auto-mode-alist '("\\.ses" . ses-mode))
> _____________________________________________________
>
> ...inserting, of course, the file or file ending you wanted instead
> of ".ses" and the mode you wanted instead of "ses-mode."

The shell script mode isn't that important and it's now working
with .sh file extensions so it's fine.


> setq is the command to set one or more variables.

I needed this explanation. Thanks again.

> > M-x highlight-current-line-globally
>
> CODE:
> _____________________________
>
> (highlight-current-line-on t)
> _____________________________

> ...will turn it on. Passing it an argument of nil (instead of t)
> will turn it off again if it gets on your nerves.

Before it gets on  my nerves, I wish to use none for the bg color and
a nice color for fg so that only the characters color change telling
me which line I am on. The command for this is

highlight-current-line-set-bg-color  then press enter and type the
color of choice

Same for the fg color. But neither of these work. Same error:

Symbol's definition function is void : highlight-current-line-set-bg-
color

> CODE:
> __________________________________________________
>
> (global-set-key (kbd "M-n") 'cyclebuffer-forward)
> (global-set-key (kbd "M-p") 'cyclebuffer-backward)
> __________________________________________________
>
> ...in your .emacs (and eval them the same was as with the first
> command I suggested). That should make it work.

Both now work nicely. In the cyclebuffer info page, there was
something else mentioned instead of the kbd and that was causing
problem it seems.

Thanks for the great help again. WIth all of you helping has generated
in me more interest in emacs than before. I even printed out the GNU
Emacs manual by Eric Raymond. Tho it seems a little outdated. Is that
enough to make me comfy with emacs?

Regards,
mowgli



reply via email to

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