ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Making context produce dvi file.
@ 2006-09-11 12:05 John R. Culleton
  2006-09-11 13:14 ` luigi scarso
                   ` (3 more replies)
  0 siblings, 4 replies; 16+ messages in thread
From: John R. Culleton @ 2006-09-11 12:05 UTC (permalink / raw)


For one recurring task I first produce a booklet version 5.5. x
8.5in, then a straight pdf 8.5 x 11in, all controlled by modes. The
third format is plain text. Others recommend dvi2tty for this
conversion. But how do I get Context to produce a dvi file? The
Context manual does not make this clear.

I am on a Linux system.  

-- 
John Culleton
Able Indexing and Typesetting
Precision typesetting (tm) at reasonable cost.
Satisfaction guaranteed. 
http://wexfordpress.com

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

* Re: Making context produce dvi file.
  2006-09-11 12:05 Making context produce dvi file John R. Culleton
@ 2006-09-11 13:14 ` luigi scarso
  2006-09-11 14:58   ` Willi Egger
  2006-09-11 14:11 ` Mari Voipio
                   ` (2 subsequent siblings)
  3 siblings, 1 reply; 16+ messages in thread
From: luigi scarso @ 2006-09-11 13:14 UTC (permalink / raw)


On 9/11/06, John R. Culleton <john@wexfordpress.com> wrote:
> For one recurring task I first produce a booklet version 5.5. x
> 8.5in, then a straight pdf 8.5 x 11in, all controlled by modes. The
> third format is plain text. Others recommend dvi2tty for this
> conversion. But how do I get Context to produce a dvi file? The
> Context manual does not make this clear.
>
> I am on a Linux system.
hmm, on my (one year old) system
$> texexec file.tex
make file.dvi
and
$> texexec --pdf file.tex
make file.pdf


luigi

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

* Re: Making context produce dvi file.
  2006-09-11 12:05 Making context produce dvi file John R. Culleton
  2006-09-11 13:14 ` luigi scarso
@ 2006-09-11 14:11 ` Mari Voipio
  2006-09-11 15:21   ` Hans Hagen
  2006-09-11 16:32 ` Aditya Mahajan
  2006-09-11 19:34 ` Sanjoy Mahajan
  3 siblings, 1 reply; 16+ messages in thread
From: Mari Voipio @ 2006-09-11 14:11 UTC (permalink / raw)




On Mon, 11 Sep 2006, John R. Culleton wrote:
> But how do I get Context to produce a dvi file?

If I recall correctly from my time with TeXLive, dvi is the 'native' 
format of ConTeXt, which was less than handy with Windows....
i.e. you normally get dvi by *not* telling ConTeXt to make ps/pdf. (See 
beginner manual p. 6, second paragraph.)

However, the systems have changed over the last couple of years and for 
example I now run the stand-alone WinConText that pdfs everything, whether 
I want it or not (I do, so it doesn't bother me), so this is not so 
self-evident any more. From http://wiki.contextgarden.net/First_Document I 
understand that most ConTeXt configurations now produce pdfs by default.

On Linux you might be able to find the place where your \setupoutput[pdf] 
or texexec --pdf sits, if it's in a configuration file.
On the other hand, I dug a bit into my stand-alone Windows distribution 
and didn't get any smarter by that. Now I know why my pdf opens 
automatically into Acrobat, but not how *not* to produce pdf (or ps).



That was a very good question. :-)


Mari
(...three years with ConTeXt and I sound like a dinosaur...)

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

* Re: Making context produce dvi file.
  2006-09-11 13:14 ` luigi scarso
@ 2006-09-11 14:58   ` Willi Egger
  0 siblings, 0 replies; 16+ messages in thread
From: Willi Egger @ 2006-09-11 14:58 UTC (permalink / raw)


Hi,

Humble, I would start in the preamble to sau \setupoutput[dvi]

Willi

luigi scarso wrote:
> On 9/11/06, John R. Culleton <john@wexfordpress.com> wrote:
>   
>> For one recurring task I first produce a booklet version 5.5. x
>> 8.5in, then a straight pdf 8.5 x 11in, all controlled by modes. The
>> third format is plain text. Others recommend dvi2tty for this
>> conversion. But how do I get Context to produce a dvi file? The
>> Context manual does not make this clear.
>>
>> I am on a Linux system.
>>     
> hmm, on my (one year old) system
> $> texexec file.tex
> make file.dvi
> and
> $> texexec --pdf file.tex
> make file.pdf
>
>
> luigi
> _______________________________________________
> ntg-context mailing list
> ntg-context@ntg.nl
> http://www.ntg.nl/mailman/listinfo/ntg-context
>   

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

* Re: Making context produce dvi file.
  2006-09-11 14:11 ` Mari Voipio
@ 2006-09-11 15:21   ` Hans Hagen
  2006-09-11 18:06     ` John R. Culleton
  0 siblings, 1 reply; 16+ messages in thread
From: Hans Hagen @ 2006-09-11 15:21 UTC (permalink / raw)


Mari Voipio wrote:
> On Mon, 11 Sep 2006, John R. Culleton wrote:
>   
>> But how do I get Context to produce a dvi file?
>>     
>
> If I recall correctly from my time with TeXLive, dvi is the 'native' 
> format of ConTeXt, which was less than handy with Windows....
> i.e. you normally get dvi by *not* telling ConTeXt to make ps/pdf. (See 
> beginner manual p. 6, second paragraph.)
>
> However, the systems have changed over the last couple of years and for 
> example I now run the stand-alone WinConText that pdfs everything, whether 
> I want it or not (I do, so it doesn't bother me), so this is not so 
> self-evident any more. From http://wiki.contextgarden.net/First_Document I 
> understand that most ConTeXt configurations now produce pdfs by default.
>
> On Linux you might be able to find the place where your \setupoutput[pdf] 
> or texexec --pdf sits, if it's in a configuration file.
> On the other hand, I dug a bit into my stand-alone Windows distribution 
> and didn't get any smarter by that. Now I know why my pdf opens 
> automatically into Acrobat, but not how *not* to produce pdf (or ps).
>
>
>
> That was a very good question. :-)
>
>
> Mari
> (...three years with ConTeXt and I sound like a dinosaur...)
>   
texexec --dvips yourfile

Hans 

-----------------------------------------------------------------
                                          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
-----------------------------------------------------------------

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

* Re: Making context produce dvi file.
  2006-09-11 12:05 Making context produce dvi file John R. Culleton
  2006-09-11 13:14 ` luigi scarso
  2006-09-11 14:11 ` Mari Voipio
@ 2006-09-11 16:32 ` Aditya Mahajan
  2006-09-11 19:34 ` Sanjoy Mahajan
  3 siblings, 0 replies; 16+ messages in thread
From: Aditya Mahajan @ 2006-09-11 16:32 UTC (permalink / raw)


John,

On Mon, 11 Sep 2006, John R. Culleton wrote:

> For one recurring task I first produce a booklet version 5.5. x
> 8.5in, then a straight pdf 8.5 x 11in, all controlled by modes. The
> third format is plain text. Others recommend dvi2tty for this
> conversion. But how do I get Context to produce a dvi file? The
> Context manual does not make this clear.

Not that you asked, but dvitty does not seem to be the best way to get a 
plain text output. I am assuming that you do not have maths, otherwise 
text output will not make much sense.

Assuming that you have a document with simple structure (title, section, 
header, etc), and not too complicated floats (figures and tables), and you 
want pdf and plain text, I think that starting from xml is better. For 
simple tasks, html is sufficient. For more complicated tasks, you will 
need to define your own xml schema. In either case, you can get a pdf with 
all the bells and whistles by compiling the xml (or html) file using 
context. To get a plain text output, open your file in a browser and save 
as text  (lynx --dump or links -dump will work if the file is html) to 
get a text output.

IMHO, this is much easier than trying to coax tex to output something that 
resemples a typewritter output (fixed width fonts, no hyphenation, etc)

Aditya

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

* Re: Making context produce dvi file.
  2006-09-11 15:21   ` Hans Hagen
@ 2006-09-11 18:06     ` John R. Culleton
  2006-09-11 19:08       ` Hans Hagen
  2006-09-11 19:14       ` Mojca Miklavec
  0 siblings, 2 replies; 16+ messages in thread
From: John R. Culleton @ 2006-09-11 18:06 UTC (permalink / raw)
  Cc: Hans Hagen, Mari Voipio

On Monday 11 September 2006 11:21, Hans Hagen wrote:
> Mari Voipio wrote:
> > On Mon, 11 Sep 2006, John R. Culleton wrote:
> >> But how do I get Context to produce a dvi file?
>
> texexec --dvips yourfile
>
> Hans

Thanks! 
That works after excising some grqphics. Just as a matter of
curiosity, why is the parameter --dvips and not dvi? 

-- 
John Culleton
Able Indexing and Typesetting
Precision typesetting (tm) at reasonable cost.
Satisfaction guaranteed. 
http://wexfordpress.com

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

* Re: Making context produce dvi file.
  2006-09-11 18:06     ` John R. Culleton
@ 2006-09-11 19:08       ` Hans Hagen
  2006-09-11 21:37         ` Sanjoy Mahajan
  2006-09-11 19:14       ` Mojca Miklavec
  1 sibling, 1 reply; 16+ messages in thread
From: Hans Hagen @ 2006-09-11 19:08 UTC (permalink / raw)


John R. Culleton wrote:
> On Monday 11 September 2006 11:21, Hans Hagen wrote:
>   
>> Mari Voipio wrote:
>>     
>>> On Mon, 11 Sep 2006, John R. Culleton wrote:
>>>       
>>>> But how do I get Context to produce a dvi file?
>>>>         
>> texexec --dvips yourfile
>>
>> Hans
>>     
>
> Thanks! 
> That works after excising some grqphics. Just as a matter of
> curiosity, why is the parameter --dvips and not dvi? 
>
>   
because one can also say -dvipdfmx

-- 

-----------------------------------------------------------------
                                          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
-----------------------------------------------------------------

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

* Re: Making context produce dvi file.
  2006-09-11 18:06     ` John R. Culleton
  2006-09-11 19:08       ` Hans Hagen
@ 2006-09-11 19:14       ` Mojca Miklavec
  2006-09-12  7:18         ` Hans Hagen
  1 sibling, 1 reply; 16+ messages in thread
From: Mojca Miklavec @ 2006-09-11 19:14 UTC (permalink / raw)


On 9/11/06, John R. Culleton wrote:
> On Monday 11 September 2006 11:21, Hans Hagen wrote:
> > Mari Voipio wrote:
> > > On Mon, 11 Sep 2006, John R. Culleton wrote:
> > >> But how do I get Context to produce a dvi file?
> >
> > texexec --dvips yourfile
> >
> > Hans
>
> Thanks!
> That works after excising some grqphics. Just as a matter of
> curiosity, why is the parameter --dvips and not dvi?

Simple explanation: because it generates a PostScript file as well ;)

But I'm supporting you in that question. I would also prefer to have a
switch --dvi which would skip the "dvips" postprocessing part.

And an answer to those who were wondering if ConTeXt doesn't produce
dvi by default. Yes, it did once. And still does if you're using the
old perl script "texexec.pl" which is becomming more and more
deprecated (and not supported any more anyway).

The new texexec ("texmfstart texexec.rb") should produce pdf by
default, but it's mostly fault of (old) distributions, not your fault
if you're still using the old scripts (you can influence that
behaviour though). As far as I know only MikTeX 2.5 and Hans's
standalone distros support that by default. tetex and Mac users still
have to fix that by themselves if they want to switch to the usage of
new ruby scripts.

Mojca

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

* Re: Making context produce dvi file.
  2006-09-11 12:05 Making context produce dvi file John R. Culleton
                   ` (2 preceding siblings ...)
  2006-09-11 16:32 ` Aditya Mahajan
@ 2006-09-11 19:34 ` Sanjoy Mahajan
  3 siblings, 0 replies; 16+ messages in thread
From: Sanjoy Mahajan @ 2006-09-11 19:34 UTC (permalink / raw)


> But how do I get Context to produce a dvi file? 

Using the ruby texexec, do this:

  texexec --dvi file.tex

The manual says that this is equivalent to 

  texexec --output=dvi file.tex

but that way produces pdf.

-Sanjoy

`Never underestimate the evil of which men of power are capable.'
         --Bertrand Russell, _War Crimes in Vietnam_, chapter 1.

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

* Re: Making context produce dvi file.
  2006-09-11 19:08       ` Hans Hagen
@ 2006-09-11 21:37         ` Sanjoy Mahajan
  2006-09-12 17:27           ` Hans Hagen
  0 siblings, 1 reply; 16+ messages in thread
From: Sanjoy Mahajan @ 2006-09-11 21:37 UTC (permalink / raw)


>>> texexec --dvips yourfile
>>
>> That works after excising some grqphics. Just as a matter of
>> curiosity, why is the parameter --dvips and not dvi? 
>
> because one can also say -dvipdfmx

Trying a few tests here (TeXExec 6.2.0): 'texexec --dvi' seems
equivalent to running 'texexec --dvips'.

And, a small point of disagreement with the old man entry for texexec:
'texexec --output=dvi' produces pdf.

-Sanjoy

`Never underestimate the evil of which men of power are capable.'
         --Bertrand Russell, _War Crimes in Vietnam_, chapter 1.

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

* Re: Making context produce dvi file.
  2006-09-11 19:14       ` Mojca Miklavec
@ 2006-09-12  7:18         ` Hans Hagen
  0 siblings, 0 replies; 16+ messages in thread
From: Hans Hagen @ 2006-09-12  7:18 UTC (permalink / raw)


Mojca Miklavec wrote:
> On 9/11/06, John R. Culleton wrote:
>   
>> On Monday 11 September 2006 11:21, Hans Hagen wrote:
>>     
>>> Mari Voipio wrote:
>>>       
>>>> On Mon, 11 Sep 2006, John R. Culleton wrote:
>>>>         
>>>>> But how do I get Context to produce a dvi file?
>>>>>           
>>> texexec --dvips yourfile
>>>
>>> Hans
>>>       
>> Thanks!
>> That works after excising some grqphics. Just as a matter of
>> curiosity, why is the parameter --dvips and not dvi?
>>     
>
> Simple explanation: because it generates a PostScript file as well ;)
>
> But I'm supporting you in that question. I would also prefer to have a
> switch --dvi which would skip the "dvips" postprocessing part.
>   
--nobackend

beware: there is no 'dvi' as such, there is alwasy backend specific code 
involved
> And an answer to those who were wondering if ConTeXt doesn't produce
> dvi by default. Yes, it did once. And still does if you're using the
> old perl script "texexec.pl" which is becomming more and more
> deprecated (and not supported any more anyway).
>  
>   
Hans 

-----------------------------------------------------------------
                                          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
-----------------------------------------------------------------

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

* Re: Making context produce dvi file.
  2006-09-11 21:37         ` Sanjoy Mahajan
@ 2006-09-12 17:27           ` Hans Hagen
  2006-09-14 13:28             ` Sanjoy Mahajan
  0 siblings, 1 reply; 16+ messages in thread
From: Hans Hagen @ 2006-09-12 17:27 UTC (permalink / raw)


Sanjoy Mahajan wrote:
>>>> texexec --dvips yourfile
>>>>         
>>> That works after excising some grqphics. Just as a matter of
>>> curiosity, why is the parameter --dvips and not dvi? 
>>>       
>> because one can also say -dvipdfmx
>>     
>
> Trying a few tests here (TeXExec 6.2.0): 'texexec --dvi' seems
> equivalent to running 'texexec --dvips'.
>
> And, a small point of disagreement with the old man entry for texexec:
> 'texexec --output=dvi' produces pdf.
>
>   
line 116 in tex.rb in the ruby base path can be adapted:

    ['dvips','ps','dvi']                          .each do |b| 
@@backends[b]   = 'dvips'     end

untested

> -Sanjoy
>
> `Never underestimate the evil of which men of power are capable.'
>          --Bertrand Russell, _War Crimes in Vietnam_, chapter 1.
> _______________________________________________
> ntg-context mailing list
> ntg-context@ntg.nl
> http://www.ntg.nl/mailman/listinfo/ntg-context
>   


-- 

-----------------------------------------------------------------
                                          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
-----------------------------------------------------------------

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

* Re: Making context produce dvi file.
  2006-09-12 17:27           ` Hans Hagen
@ 2006-09-14 13:28             ` Sanjoy Mahajan
  2006-09-14 18:55               ` Hans Hagen
  0 siblings, 1 reply; 16+ messages in thread
From: Sanjoy Mahajan @ 2006-09-14 13:28 UTC (permalink / raw)


Hans Hagen wrote:
> > And, a small point of disagreement with the old man entry for texexec:
> > 'texexec --output=dvi' produces pdf.
> >
> >   
> line 116 in tex.rb in the ruby base path can be adapted:
> 
>     ['dvips','ps','dvi']                          .each do |b| 
> @@backends[b]   = 'dvips'     end

That didn't change it, perhaps because of some clever code looking for
prefix matches when processing options? (I need to study the code a
bit more but that was one guess.)  I tried the following file for fun:

\setupcolors[state=start]
\starttext
\showcolor
\stoptext

'texexec --dvi 1.tex' produces ps, via dvips, with or without the
change to tex.rb.

'texexec --output=dvi 1.tex' produces pdf, with or without the change.

The texexec.pl script produced dvi when given the --dvi option, but
maybe it's a bad idea to allow generic dvi output (without going to
postscript or pdf), for the reason you say: that the included specials
depend on the backend, whether dvips or dvipsone etc.

By the way I was pleasantly surprised that xdvi could display the
colors in 1.dvi, I guess because ConTeXt generated direct postscript
specials (like "ps: 0 0 1 setrgbcolor") rather than dvips's color
specials.

-Sanjoy

`Never underestimate the evil of which men of power are capable.'
         --Bertrand Russell, _War Crimes in Vietnam_, chapter 1.

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

* Re: Making context produce dvi file.
  2006-09-14 13:28             ` Sanjoy Mahajan
@ 2006-09-14 18:55               ` Hans Hagen
  2006-09-14 22:03                 ` Sanjoy Mahajan
  0 siblings, 1 reply; 16+ messages in thread
From: Hans Hagen @ 2006-09-14 18:55 UTC (permalink / raw)


Sanjoy Mahajan wrote:
> Hans Hagen wrote:
>   
>>> And, a small point of disagreement with the old man entry for texexec:
>>> 'texexec --output=dvi' produces pdf.
>>>
>>>   
>>>       
>> line 116 in tex.rb in the ruby base path can be adapted:
>>
>>     ['dvips','ps','dvi']                          .each do |b| 
>> @@backends[b]   = 'dvips'     end
>>     
>
>
>   
texexec --dvi test --nobackend

-----------------------------------------------------------------
                                          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
-----------------------------------------------------------------

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

* Re: Making context produce dvi file.
  2006-09-14 18:55               ` Hans Hagen
@ 2006-09-14 22:03                 ` Sanjoy Mahajan
  0 siblings, 0 replies; 16+ messages in thread
From: Sanjoy Mahajan @ 2006-09-14 22:03 UTC (permalink / raw)


Hans Hagen wrote:
> texexec --dvi test --nobackend

That works.  As another test, using --output=dvi instead of --dvi
produces pdf even with --nobackend.

Just to be thorough, or difficult, I also tried

   texexec test --nobackend

where pdftex is both front- and backend.  It did the right thing (ran
pdftex anyway and produced pdf).

> --nobackend

Thanks, that switch was news to me.

-Sanjoy

`Never underestimate the evil of which men of power are capable.'
         --Bertrand Russell, _War Crimes in Vietnam_, chapter 1.

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

end of thread, other threads:[~2006-09-14 22:03 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-09-11 12:05 Making context produce dvi file John R. Culleton
2006-09-11 13:14 ` luigi scarso
2006-09-11 14:58   ` Willi Egger
2006-09-11 14:11 ` Mari Voipio
2006-09-11 15:21   ` Hans Hagen
2006-09-11 18:06     ` John R. Culleton
2006-09-11 19:08       ` Hans Hagen
2006-09-11 21:37         ` Sanjoy Mahajan
2006-09-12 17:27           ` Hans Hagen
2006-09-14 13:28             ` Sanjoy Mahajan
2006-09-14 18:55               ` Hans Hagen
2006-09-14 22:03                 ` Sanjoy Mahajan
2006-09-11 19:14       ` Mojca Miklavec
2006-09-12  7:18         ` Hans Hagen
2006-09-11 16:32 ` Aditya Mahajan
2006-09-11 19:34 ` Sanjoy Mahajan

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).