ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Type-setting filenames
@ 2008-06-25  9:03 richard.stephens
  2008-06-25  9:16 ` Wolfgang Schuster
  0 siblings, 1 reply; 9+ messages in thread
From: richard.stephens @ 2008-06-25  9:03 UTC (permalink / raw)
  To: ntg-context


[-- Attachment #1.1: Type: text/plain, Size: 397 bytes --]

Hello,

Can anyone suggest a good way of type-setting filenames in ConTeXt?  They 
are usually long with few spaces and so often overhang the right-hand 
margin and even fall off the edge of the page.  They also often include 
backslashes and underscores which I have to manually change - very 
tedious.

Is there, for example, a command which handles some or all of my problems?

Thanks

Richard

[-- Attachment #1.2: Type: text/html, Size: 596 bytes --]

[-- Attachment #2: Type: text/plain, Size: 487 bytes --]

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Type-setting filenames
  2008-06-25  9:03 Type-setting filenames richard.stephens
@ 2008-06-25  9:16 ` Wolfgang Schuster
  0 siblings, 0 replies; 9+ messages in thread
From: Wolfgang Schuster @ 2008-06-25  9:16 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Wed, Jun 25, 2008 at 11:03 AM,  <richard.stephens@converteam.com> wrote:
>
> Hello,
>
> Can anyone suggest a good way of type-setting filenames in ConTeXt?  They
> are usually long with few spaces and so often overhang the right-hand margin
> and even fall off the edge of the page.  They also often include backslashes
> and underscores which I have to manually change - very tedious.
>
> Is there, for example, a command which handles some or all of my problems?

\filename{...} or \hyphenatedfilename{...}

Regards
Wolfgang
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Type-setting filenames
  2008-09-18  9:20   ` Wolfgang Schuster
@ 2008-09-18 12:00     ` Hans Hagen
  0 siblings, 0 replies; 9+ messages in thread
From: Hans Hagen @ 2008-09-18 12:00 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Wolfgang Schuster wrote:
> On Thu, Sep 18, 2008 at 11:09 AM, Hans Hagen <pragma@wxs.nl> wrote:
>> richard.stephens@converteam.com wrote:
>>>>> I am using \filename to type-set filenames.  Some of these are very
>>>>> long
>>>>> (greater than 30 characters) and overhang
>>>>> the right hand margin, sometimes even disappearing off the edge of the
>>>>> page.  The first line break is just before the
>>>>> full stop.  There are usually plenty of spaces in the names.  Can I
>>>>> get
>>>>> ConTeXt to put a line-break into filenames?
>>>> Did you try \hyphenatedfilename ?
>>> Yes, I tried that, no difference.  I presume that \hyphenatedfilename is
>>> for use with filenames that already have hyphens in them?
>>> Mine don't, but I want them to split.  Perhaps splitting filenames is
>>> frowned upon - if so, what is the best way to put them into documents?
>>> Or perhaps I should use shorter filenames, but why should I compromise
>>> readability?  One example is "Transfer functions for PID and KF
>>> controllers.xmcd"
>>>
>>> Any ideas or comments?
>> \def\myfilename#1{{\spaceskip.25em plus
>> 1em\relax\tttf\normallanguage\zerocount#1}}
>>
>> \myfilename{Transfer functions for PID and KF controllers.xmcd}
>> \myfilename{Transfer functions for PID and KF controllers.xmcd}
>> \myfilename{Transfer functions for PID and KF controllers.xmcd}
>> \myfilename{Transfer functions for PID and KF controllers.xmcd}
> 
> Why do you use the language trick and not just \nohyphens?

because of a bug in luatex -)


-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
      tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Type-setting filenames
@ 2008-09-18 10:19 richard.stephens
  0 siblings, 0 replies; 9+ messages in thread
From: richard.stephens @ 2008-09-18 10:19 UTC (permalink / raw)
  To: ntg-context


> \def\myfilename#1{{\spaceskip.25em plus
1em\relax\tttf\normallanguage\zerocount#1}}
>
> \myfilename{Transfer functions for PID and KF controllers.xmcd}
> \myfilename{Transfer functions for PID and KF controllers.xmcd}
> \myfilename{Transfer functions for PID and KF controllers.xmcd}
> \myfilename{Transfer functions for PID and KF controllers.xmcd}

That works brilliantly (I've no idea why through).  Thanks Hans

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Type-setting filenames
  2008-09-18  9:09 ` Hans Hagen
@ 2008-09-18  9:20   ` Wolfgang Schuster
  2008-09-18 12:00     ` Hans Hagen
  0 siblings, 1 reply; 9+ messages in thread
From: Wolfgang Schuster @ 2008-09-18  9:20 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Thu, Sep 18, 2008 at 11:09 AM, Hans Hagen <pragma@wxs.nl> wrote:
> richard.stephens@converteam.com wrote:
>>>> I am using \filename to type-set filenames.  Some of these are very
>>>> long
>>>> (greater than 30 characters) and overhang
>>>> the right hand margin, sometimes even disappearing off the edge of the
>>>> page.  The first line break is just before the
>>>> full stop.  There are usually plenty of spaces in the names.  Can I
>>>> get
>>>> ConTeXt to put a line-break into filenames?
>>> Did you try \hyphenatedfilename ?
>>
>> Yes, I tried that, no difference.  I presume that \hyphenatedfilename is
>> for use with filenames that already have hyphens in them?
>> Mine don't, but I want them to split.  Perhaps splitting filenames is
>> frowned upon - if so, what is the best way to put them into documents?
>> Or perhaps I should use shorter filenames, but why should I compromise
>> readability?  One example is "Transfer functions for PID and KF
>> controllers.xmcd"
>>
>> Any ideas or comments?
> \def\myfilename#1{{\spaceskip.25em plus
> 1em\relax\tttf\normallanguage\zerocount#1}}
>
> \myfilename{Transfer functions for PID and KF controllers.xmcd}
> \myfilename{Transfer functions for PID and KF controllers.xmcd}
> \myfilename{Transfer functions for PID and KF controllers.xmcd}
> \myfilename{Transfer functions for PID and KF controllers.xmcd}

Why do you use the language trick and not just \nohyphens?

Wolfgang
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Type-setting filenames
  2008-09-18  8:42 richard.stephens
@ 2008-09-18  9:09 ` Hans Hagen
  2008-09-18  9:20   ` Wolfgang Schuster
  0 siblings, 1 reply; 9+ messages in thread
From: Hans Hagen @ 2008-09-18  9:09 UTC (permalink / raw)
  To: mailing list for ConTeXt users

richard.stephens@converteam.com wrote:
>>> I am using \filename to type-set filenames.  Some of these are very
>>> long
>>> (greater than 30 characters) and overhang
>>> the right hand margin, sometimes even disappearing off the edge of the
>>> page.  The first line break is just before the
>>> full stop.  There are usually plenty of spaces in the names.  Can I
>>> get
>>> ConTeXt to put a line-break into filenames?
>> Did you try \hyphenatedfilename ?
> 
> Yes, I tried that, no difference.  I presume that \hyphenatedfilename is
> for use with filenames that already have hyphens in them?
> Mine don't, but I want them to split.  Perhaps splitting filenames is
> frowned upon - if so, what is the best way to put them into documents?
> Or perhaps I should use shorter filenames, but why should I compromise
> readability?  One example is "Transfer functions for PID and KF
> controllers.xmcd"
> 
> Any ideas or comments?
\def\myfilename#1{{\spaceskip.25em plus 
1em\relax\tttf\normallanguage\zerocount#1}}

\myfilename{Transfer functions for PID and KF controllers.xmcd}
\myfilename{Transfer functions for PID and KF controllers.xmcd}
\myfilename{Transfer functions for PID and KF controllers.xmcd}
\myfilename{Transfer functions for PID and KF controllers.xmcd}


-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
      tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Type-setting filenames
@ 2008-09-18  8:42 richard.stephens
  2008-09-18  9:09 ` Hans Hagen
  0 siblings, 1 reply; 9+ messages in thread
From: richard.stephens @ 2008-09-18  8:42 UTC (permalink / raw)
  To: ntg-context


>> I am using \filename to type-set filenames.  Some of these are very
>> long
>> (greater than 30 characters) and overhang
>> the right hand margin, sometimes even disappearing off the edge of the
>> page.  The first line break is just before the
>> full stop.  There are usually plenty of spaces in the names.  Can I
>> get
>> ConTeXt to put a line-break into filenames?
>
> Did you try \hyphenatedfilename ?

Yes, I tried that, no difference.  I presume that \hyphenatedfilename is
for use with filenames that already have hyphens in them?
Mine don't, but I want them to split.  Perhaps splitting filenames is
frowned upon - if so, what is the best way to put them into documents?
Or perhaps I should use shorter filenames, but why should I compromise
readability?  One example is "Transfer functions for PID and KF
controllers.xmcd"

Any ideas or comments?

Richard

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Type-setting filenames
  2008-09-17 14:20 richard.stephens
@ 2008-09-17 14:34 ` Thomas A. Schmitz
  0 siblings, 0 replies; 9+ messages in thread
From: Thomas A. Schmitz @ 2008-09-17 14:34 UTC (permalink / raw)
  To: mailing list for ConTeXt users


On Sep 17, 2008, at 4:20 PM, richard.stephens@converteam.com wrote:

> I am using \filename to type-set filenames.  Some of these are very   
> long
> (greater than 30 characters) and overhang
> the right hand margin, sometimes even disappearing off the edge of the
> page.  The first line break is just before the
> full stop.  There are usually plenty of spaces in the names.  Can I  
> get
> ConTeXt to put a line-break into filenames?

Did you try \hyphenatedfilename ?

Thomas
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Type-setting filenames
@ 2008-09-17 14:20 richard.stephens
  2008-09-17 14:34 ` Thomas A. Schmitz
  0 siblings, 1 reply; 9+ messages in thread
From: richard.stephens @ 2008-09-17 14:20 UTC (permalink / raw)
  To: ntg-context


I am using \filename to type-set filenames.  Some of these are very  long
(greater than 30 characters) and overhang
the right hand margin, sometimes even disappearing off the edge of the
page.  The first line break is just before the
full stop.  There are usually plenty of spaces in the names.  Can I get
ConTeXt to put a line-break into filenames?

Thanks,

Richard

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2008-09-18 12:00 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-06-25  9:03 Type-setting filenames richard.stephens
2008-06-25  9:16 ` Wolfgang Schuster
2008-09-17 14:20 richard.stephens
2008-09-17 14:34 ` Thomas A. Schmitz
2008-09-18  8:42 richard.stephens
2008-09-18  9:09 ` Hans Hagen
2008-09-18  9:20   ` Wolfgang Schuster
2008-09-18 12:00     ` Hans Hagen
2008-09-18 10:19 richard.stephens

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).