Vous êtes ici : John’s Cornelisse COMPUTER2CASTER diary > 29-01-2004: about programming
The First European Monotype University, Geneva, Swiss, 13-20 june 2004     
  Report 2004

About the caster     
  Here is text about caster description

History of computer to caster     
  MacMono Interface

John Cornelisse’s Computer to caster interface     

John’s Cornelisse COMPUTER2CASTER diary     

Monotype Corporation: an history     
  The Monotype Chronicles by Lawrence W. Wallis

Monotype Special sorts and Unicode     
  How to bring Monotype special sorts in the Unicode system ?

The Monotype system     
  Monotype specimen book
  Monotype units


29-01-2004: about programming

Thursday February 5th, 2004, par John Cornelisse

Monotype diary 29 January

Programming becomes routine again. This a more or less a hobby of me. But it started when I was a analist at the medical department of University of Amsterdam. At that time we used an x-y-tablet to measure the lenght,area and all kinds of other properties of photo’s made in the electron-microscope.

At some time I had compilers for Pascal, several Basic-dialects, Fortran and already C.


Now this happens again, Most is done in two C-compilers. Quick-C, an probably obsolete C-compiler. 1987 !!

But I have it so long already, and I have all the books concerning it. Though documentation on compilers is rather poor. And this compiler is no exception in this matter. And I’m familiar with most of it’s habits...

The functions like fabs( ), labs( ) they do not work at all. The result returned by these functions will surprice you: Something like 10E30 or even bigger.

I use my own and they are quite simple:

float fabsoluut ( float f) return ( f < 0. ? -f : f );

Today most time was spent on a routine calculating the properties of fixed spaces.

I have to cast a lot of text for a book I’m making. The text of it is 19th century Dutch. And at that time handsetting was done a lot wider than we are used now. Using "pasjes" or spaces half the size of character-corps, this will speed the handsetting by weight. Not by text. But if you are supposed to do 800 squares or more the hour, then taking wider spacing helps.

Due to the Swiss typographer Jan Tschichold we don’t do this anymore..

But I would like to the book more or less to mimic the 19th century typography. And the computer has to obey my wishes.

For now, this evokes sometimes a long search after some missing seperators like: ; or . When the balance is lost in these and the place can sure be hard to find...

delta = wsp * .0148 ; /* points didot */ wrow = wig[ pos ] * set / 1296 ; delta -= wrow; delta *= 2000;

a 1/2000 part of an inch, its the precision of the caster...

teken = (delta < 0) ? -1 : 1; delta += ( teken * .5); idelta = (int) delta;

Than rounding off in the proper way. Here a routine like fabs() could work, but it does not.

idelta += 53; /* 3/8 position correction wedges */

fu1 = idelta / 15; fu2 = idelta % 15;

Integer division, and the integer remainder...

if (fu2 == 0) fu2+=15 ; fu1 --; if (fu1>15) fu1=15; if (fu1<1) fu1=1;

The minimum width we can obtain with the adjusment wedges is:

3/8 - 1/1 = 2/7 => 2 * .0075 + 7 * .0005 inch = .0185 inch.

The maximum addition is much larger:

15/15 - 3/8 = 12/7 = 12 * .0075 + 7 + 0005 inch = .0935 inch !

Because the computer calculates better with integers. It’s more easy to calculate with 3 * 15 + 7 = 53.



Dans la même rubrique :
13-01-2004: Making a new box for the interface Diary
17-01-2004: about Monotype code
30-01-2004: indentify the port
01-03-2004: status of the Centronics-parallel port
11-01-2004: presentation of the interface
16-02-2004: C-compilers
22-01-2004: 24 Volt direct current
12-02-2004: Mac or PC ?
13-02-2004: can’t cope with file’s above 64k
26 May 2004: casting sorts

Friday November 24th, 2017
Mail us! | Site Map | Home Computer to Caster | Newsgroup | Admin

Association pour le Patrimoine Industriel - Association Lettres et Images - Imprimerie des Arts