Simple-minded question

2 views
Skip to first unread message

Nick_H

unread,
May 28, 2010, 4:29:18 AM5/28/10
to leo-editor
Sorry, this is probably very trivial, but ...
I have an outline with the default target language set to plain, but
with imported @shadow source code nodes.
The default body font is set to a mono-spaced font for the benefit of
the source code, but I'd really like all my plain-text descriptive
nodes to be in a proportional font.
Can I set a proportional font to use in all "@language plain" nodes
while retaining the mono-spaced font for all @language csharp" nodes?

I'm running Leo 4.7.1 final on Windows XP (SP3) with Python 3.1.2 and
Qt version 4.6.2

Thanks & apologies

Nick

-- Also may I join the others in sending my condolences & best wishes
to Edward and his family.

Terry Brown

unread,
May 28, 2010, 9:58:51 AM5/28/10
to leo-e...@googlegroups.com
On Fri, 28 May 2010 01:29:18 -0700 (PDT)
Nick_H <n...@plextek.co.uk> wrote:

> Can I set a proportional font to use in all "@language plain" nodes
> while retaining the mono-spaced font for all @language csharp" nodes?

No.

But it would be a nice thing to be able to do. When I get time I want to expand colorize_headlines.py to do a variety of styling things to headlines, I guess this would be one case where it could usefully work on body text too.

Cheers -Terry

Edward K. Ream

unread,
Jul 29, 2010, 3:28:29 PM7/29/10
to leo-e...@googlegroups.com
On Fri, May 28, 2010 at 8:58 AM, Terry Brown <terry_...@yahoo.com> wrote:
> On Fri, 28 May 2010 01:29:18 -0700 (PDT)
> Nick_H <n...@plextek.co.uk> wrote:
>
>> Can I set a proportional font to use in all "@language plain" nodes
>> while retaining the mono-spaced font for all @language csharp" nodes?
>
> No.

Actually, almost all the machinery is in place to do this. For
example, see in leoSettings.leo, the node

@settings-->Colors-->Syntax colors & options-->Options for jEdit
colorer-->Language-specific colors

As I have just verified, these will work for the Qt colorizer. For example:

@font python keyword1 fonts

with body text:

python_keyword1_font_family = DejaVu Sans Mono
python_keyword1_font_size = 20
python_keyword1_font_slant = roman
# roman, italic
python_keyword1_font_weight = bold
# normal, bold

Produces quite big keyword :-)

There are some issues that may have to be addressed re defaults, but
I'd like to see this happen in the next day or so. It would be a
really good feature.

Edward

Reply all
Reply to author
Forward
0 new messages