Article View: news.software.readers
Article #122865Re: [SLRN] Newbie SetKey etc
From: J.B. Nicholson-Owens
Date: Tue, 08 Apr 2003 04:32
Date: Tue, 08 Apr 2003 04:32
75 lines
3900 bytes
3900 bytes
random.blokeNOSPAMPLEASE@totalise.co.uk wrote:
> What I want to do is have the up and down cursors keys scroll up and down
> in the pager when it's open and in the index when the pager's hidden, j
> and k go down and up in the index (while the pager's open or not), and
> both the left cursor key and the q key to go from the pager being open to
> the pager being closed and from the index of articles to the list of
> subscribed newsgroups.
You'll need a set of macros for that with the current version of slrn. To
install the macro, save the data after the conversation part of this post
into a file (say "~/my-macros.sl") and then load the file from your slrnrc
by appending the following instruction to your slrnrc:
interpret "my-macros.sl"
Then restart slrn.
Since you're remapping the left arrow key, I hope you have some other key
mapped to pan the article to the left. Similarly, 'k' is usually used for
killing articles and 'j' for jumping to a particular article number.
Also, if you want 'j' and 'k' to show the new article under the cursor when
you have the article window showing, that will require a macro too. If you
have access to the slrn-user mailing list, check out the thread that
includes <20030326232023.GD2168@forestfield.org>. I posted a very similar
macro set in that thread to answer someone else's request for a similar set
of macros.
> Remove NOSPAMPLEASE from the email address to send emails to me (a copy would
> be appreciated as I haven't got slrn working to my taste just yet!)
Setting a proper e-mail address (at least in the Reply-To: header) and using
a spam filter is recommended instead of making everyone obviate the
mechanism built to help get e-mail to you.
Happy newsreading.
implements ("my");
static define up ()
{
% when article is visible: UP/j - scrolls one line up/down in current article
if (_is_article_visible () & 1) call ("article_line_up");
% otherwise, in article mode, UP/j - scrolls one line up/down
else call ("header_line_up");
}
definekey ("my->up", "\eOA", "article");
definekey ("my->up", "\e[A", "article");
static define down ()
{
% when article is visible: DOWN/k - scrolls one line down/down in current article
if (_is_article_visible () & 1) call ("article_line_down");
% otherwise, in article mode, DOWN/k - scrolls one line down/down
else call ("header_line_down");
}
definekey ("my->down", "\eOB", "article");
definekey ("my->down", "\e[B", "article");
static define quit ()
{
% when article is visible: q - closes the article window
if (_is_article_visible () & 1) call ("hide_article");
% otherwise, in article mode, q - exits to group mode
else call ("quit");
}
definekey ("my->quit", "q", "article");
definekey ("my->quit", "\eOD", "article");
definekey ("my->quit", "\e[D", "article");
definekey ("header_line_up", "j", "article");
definekey ("header_line_down", "k", "article");
Technical Details
Message-ID:
<slrnb94m39.ra3.jbn@forestfield.org>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.mbox.zip!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!syros.belnet.be!news.belnet.be!feed.news.nacamar.de!fu-berlin.de!uni-berlin.de!forestfield.ORG!not-for-mailReferences:
<b6s3d1$6qo$1@news.netmar.com>Show Full Headers
Complete Article Headers
Message-ID: <slrnb94m39.ra3.jbn@forestfield.org> Subject: Re: [SLRN] Newbie SetKey etc Date: Tue, 08 Apr 2003 04:32:59 +0000 From: "J.B. Nicholson-Owens" <jbn@forestfield.org> References: <b6s3d1$6qo$1@news.netmar.com> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.mbox.zip!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!syros.belnet.be!news.belnet.be!feed.news.nacamar.de!fu-berlin.de!uni-berlin.de!forestfield.ORG!not-for-mail Newsgroups: news.software.readers Organization: Forest Field OmniMedia Lines: 74 NNTP-Posting-Host: forestfield.org (208.216.67.173) X-Trace: fu-berlin.de 1049776379 9467268 208.216.67.173 (16 [35848]) Mail-Copies-To: nobody X-Bush-Oil-War: no User-Agent: slrn/0.9.7.4pl2 (GNU/Linux)