David Kastrup | 8 Jul 2006 12:01
Picon
Picon

Proposal...


Mathematicians use set symbols like R, C, Z, Q a lot.  The customary
way to render them tends to be a matter of taste: the "orthodox"
typographic rendition would be \mathbf{R}, since the added strokes are
a "manuscript" indication of bold-facing, like underlining is a
"manuscript" version of emphasis.

However, more often than not, the blackboard specific bolding gets
moved into print, too.  amsmath.sty (and likely amsfonts.sty too) have
\mathbb, and there are a few additional packages like bbm.sty which
provide their own versions, in this case as \mathbbm.

I find that C-c C-f C-s (for "set") is not yet taken in math mode.  It
might be nice to have it deliver \mathbb, or \mathbbm if bbm.sty has
been loaded.

It also might be nice to offer the most common set symbols in the math
menus.

What do people think?

--

-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum
UKTUG FAQ: <URL:http://www.tex.ac.uk/cgi-bin/texfaq2html>
Maarten Bergvelt | 8 Jul 2006 15:08
Picon
Favicon

Re: [AUCTeX] Proposal...

* [Sat 2006-Jul-08 05:01] David Kastrup <dak <at> gnu.org> :
> 
> Mathematicians use set symbols like R, C, Z, Q a lot.  The customary
> way to render them tends to be a matter of taste: the "orthodox"
> typographic rendition would be \mathbf{R}, since the added strokes are
> a "manuscript" indication of bold-facing, like underlining is a
> "manuscript" version of emphasis.
> 
> However, more often than not, the blackboard specific bolding gets
> moved into print, too.  amsmath.sty (and likely amsfonts.sty too) have
> \mathbb, and there are a few additional packages like bbm.sty which
> provide their own versions, in this case as \mathbbm.
> 
> I find that C-c C-f C-s (for "set") is not yet taken in math mode.  It
> might be nice to have it deliver \mathbb, or \mathbbm if bbm.sty has
> been loaded.
> 
> It also might be nice to offer the most common set symbols in the math
> menus.
> 
> What do people think?

I would like a standard key binding in Auctex for \mathbb very
much. C-c C-f C-s would be fine.

Menus would be fine for beginners, too.

--

-- 
Maarten Bergvelt		
(Continue reading)

Harald von Aschen | 8 Jul 2006 20:19
Picon
Picon

Re: Proposal...

At 12:01 08.07.06 +0200, David Kastrup wrote:

>Mathematicians use set symbols like R, C, Z, Q a lot.  The customary

[...]

>I find that C-c C-f C-s (for "set") is not yet taken in math mode.  It
>might be nice to have it deliver \mathbb, or \mathbbm if bbm.sty has
>been loaded.
>
>It also might be nice to offer the most common set symbols in the math
>menus.
>
>What do people think?

This might be a good idea.

I'm using package "dsfont.sty" for doublestroke characters used for number 
sets, so it might be a good idea to have an extra variable to set to 
\mathbb{#Character} or \mathds{#Character} or any other command the user 
wants to use.

Best regards

Harald 
David Kastrup | 14 Jul 2006 15:34
Picon
Picon

Usability of docTeX-mode


Ok, try the following in docTeX-mode:

transform the following:

\def\pp <at> pagectr#1#2#3#4{\ <at> ifundefined{c <at> pp <at> a <at> #1}{}{%
    \addtocounter{pp <at> a <at> #1}\ <at> ne
    \edef\next{\noexpand
      \ <at> newl <at> bel{pp <at> r <at> #1}{#2}{{\number\value{pp <at> a <at> #1}}{#3}%
        {#4}}}\next}}

\def\pp <at> ppagectr#1#2#3#4{\ <at> ifundefined{c <at> pp <at> a <at> #1}{}{%
    \def\next{#3}%
    \expandafter\ifx\csname pp <at> page <at> #1\endcsname\next
      \addtocounter{pp <at> a <at> #1}\ <at> ne
    \else
      \setcounter{pp <at> a <at> #1}{\value{pp <at> r <at> #1}}%
    \fi
    \global\expandafter\let\csname pp <at> page <at> #1\endcsname\next
    \edef\next{\noexpand
      \ <at> newl <at> bel{pp <at> r <at> #1}{#2}{{\number\value{pp <at> a <at> #1}}{#3}%
        {#4}}}\next}}

into

% \begin{macro}{\pp <at> pagectr}
%    \begin{macrocode}
\def\pp <at> pagectr#1#2#3#4{\ <at> ifundefined{c <at> pp <at> a <at> #1}{}{%
    \addtocounter{pp <at> a <at> #1}\ <at> ne
    \edef\next{\noexpand
(Continue reading)

Ralf Angeli | 14 Jul 2006 18:44

Re: Usability of docTeX-mode

* David Kastrup (2006-07-14) writes:

> Instead: no way.  It is simply impossible to keep AUCTeX from
> reformatting the contents.

It would probably suffice to add "macrocode" to
`LaTeX-indent-environment-list'.

--

-- 
Ralf
David Kastrup | 14 Jul 2006 19:31
Picon
Picon

Re: Usability of docTeX-mode

Ralf Angeli <angeli <at> caeruleus.net> writes:

> * David Kastrup (2006-07-14) writes:
>
>> Instead: no way.  It is simply impossible to keep AUCTeX from
>> reformatting the contents.
>
> It would probably suffice to add "macrocode" to
> `LaTeX-indent-environment-list'.

Why doesn't it work to add it to `LaTeX-verbatim-environments-local'?
What's the use of that variable, then?

--

-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum
Ralf Angeli | 14 Jul 2006 20:34

Re: Usability of docTeX-mode

* David Kastrup (2006-07-14) writes:

> Ralf Angeli <angeli <at> caeruleus.net> writes:
>
>> * David Kastrup (2006-07-14) writes:
>>
>>> Instead: no way.  It is simply impossible to keep AUCTeX from
>>> reformatting the contents.
>>
>> It would probably suffice to add "macrocode" to
>> `LaTeX-indent-environment-list'.
>
> Why doesn't it work to add it to `LaTeX-verbatim-environments-local'?
> What's the use of that variable, then?

Currently it's mainly used for font locking, but also for
`LaTeX-verbatim-p' which is used when searching for comment starters.

If we added macrocode environments to this variable, much of the
content of a docTeX file would be highlighted as verbatim.  I don't
think this would be a good idea.

--

-- 
Ralf
David Kastrup | 14 Jul 2006 20:38
Picon
Picon

Re: Re: Usability of docTeX-mode

Ralf Angeli <angeli <at> caeruleus.net> writes:

> * David Kastrup (2006-07-14) writes:
>
>> Ralf Angeli <angeli <at> caeruleus.net> writes:
>>
>>> * David Kastrup (2006-07-14) writes:
>>>
>>>> Instead: no way.  It is simply impossible to keep AUCTeX from
>>>> reformatting the contents.
>>>
>>> It would probably suffice to add "macrocode" to
>>> `LaTeX-indent-environment-list'.
>>
>> Why doesn't it work to add it to `LaTeX-verbatim-environments-local'?
>> What's the use of that variable, then?
>
> Currently it's mainly used for font locking, but also for
> `LaTeX-verbatim-p' which is used when searching for comment starters.
>
> If we added macrocode environments to this variable, much of the
> content of a docTeX file would be highlighted as verbatim.  I don't
> think this would be a good idea.

Maybe the doc strings should give some more pointers about the effects
of those variables.  I was also a bit surprised about the existence of
LaTeX-verbatim-environments-local variable and friends.  Is there
anything one can achieve with those that is not possible to do with a
local variable?

(Continue reading)

Ralf Angeli | 14 Jul 2006 20:43

Re: Usability of docTeX-mode

* David Kastrup (2006-07-14) writes:

> Maybe the doc strings should give some more pointers about the effects
> of those variables.  I was also a bit surprised about the existence of
> LaTeX-verbatim-environments-local variable and friends.  Is there
> anything one can achieve with those that is not possible to do with a
> local variable?

Those are used by style files which want to add verbatim-like
environments.

--

-- 
Ralf
David Kastrup | 14 Jul 2006 20:46
Picon
Picon

Re: Re: Usability of docTeX-mode

Ralf Angeli <angeli <at> caeruleus.net> writes:

> * David Kastrup (2006-07-14) writes:
>
>> Maybe the doc strings should give some more pointers about the effects
>> of those variables.  I was also a bit surprised about the existence of
>> LaTeX-verbatim-environments-local variable and friends.  Is there
>> anything one can achieve with those that is not possible to do with a
>> local variable?
>
> Those are used by style files which want to add verbatim-like
> environments.

Why would it not work to say

(add-to-list (make-local-variable 'LaTeX-verbatim-environments)
  "macrocode")

?

--

-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum

Gmane