Thread View: alt.sources.amiga
6 messages
6 total messages
Started by James Elkinton
Sun, 08 Nov 1992 07:37
New specialized Type function
Author: James Elkinton
Date: Sun, 08 Nov 1992 07:37
Date: Sun, 08 Nov 1992 07:37
19 lines
1008 bytes
1008 bytes
Hi. I am an absolute NEWBIE at C, and I need to make a specialized TYPE command, the purpose of which is to give the ability to view SkyPix still pictures from the CLI. The current way I am doing it is: setfont iff 1tl type <filename> setfont <original font, usually Topaz 8> This works very well! But I would like to make or get a command that does it for me, so that all I have to do is type: SPType <filename> and it does it for me. Any and all ideas, tips, sourcecode, etc would be most appreciated. -- James Elkinton (bbs.zio@tsoft.sf-bay.org)
Re: New specialized Type function
Author: James Elkinton
Date: Tue, 10 Nov 1992 03:15
Date: Tue, 10 Nov 1992 03:15
37 lines
1691 bytes
1691 bytes
bbs.zio@tsoft.sf-bay.org (James Elkinton) writes: > Hi. I am an absolute NEWBIE at C, and I need to make a specialized TYPE > command, the purpose of which is to give the ability to view SkyPix still > pictures from the CLI. The current way I am doing it is: > > setfont iff 1tl > type <filename> > setfont <original font, usually Topaz 8> > > This works very well! But I would like to make or get a command that > does it for me, so that all I have to do is type: > > SPType <filename> > > and it does it for me. Any and all ideas, tips, sourcecode, etc would be > most appreciated. > > > -- > James Elkinton (bbs.zio@tsoft.sf-bay.org) And BTW.......... I have received GOBS of letters saying "Make a Script", and explaining how to do it. If I wanted a script, I would have asked for a script. This, by the nature of its use, must not be a script. It must be in C, or assembler, or something of that sort. I would rather have C tho, since I don't want to mess around with assembler yet. I am having enough of a time with C! Once again, NO SCRIPTS PLEASE!!!! This command is destined to be a c directory command. -- James Elkinton (bbs.zio@tsoft.sf-bay.org)
Re: New specialized Type function
Author: Jakob G}rdsted
Date: Tue, 10 Nov 1992 13:45
Date: Tue, 10 Nov 1992 13:45
34 lines
2046 bytes
2046 bytes
bbs.zio@tsoft.sf-bay.org (James Elkinton) writes:
>bbs.zio@tsoft.sf-bay.org (James Elkinton) writes:
>And BTW..........
>
>I have received GOBS of letters saying "Make a Script", and explaining
>how to do it. If I wanted a script, I would have asked for a script.
>This, by the nature of its use, must not be a script. It must be in C,
>or assembler, or something of that sort. I would rather have C tho,
>since I don't want to mess around with assembler yet. I am having enough
>of a time with C!
>Once again, NO SCRIPTS PLEASE!!!! This command is destined to be a c
>directory command.
I second this, as the info/knowledge on how to change font in a shell
would be most welcomed by me, as it would open up a lot of opportunities
o do various wild, interesting things. I agree, though, with the
responders consensus on a script (with e/x flag set) being the most
easonable and elegant solution, whereas a C version would be much
harder(of course, a c program that simply executed the corresponding\
commands wouldn't count).
Hi, anyway. I guess this ought to hang out in .programmers, but whenver
somebody approached this subject there, nothing happened.
>--
>James Elkinton (bbs.zio@tsoft.sf-bay.org)
--
Jakob Gaardsted . . | The fourth time you stumble across a posting
Computer Science Department . | with this signature, you are allowed to go
University of Aarhus, Jylland(!)| and get yourself a cup of coffee. You may
. pilgrim@daimi.aau.dk . | reselect the article to achieve this effect.
Re: New specialized Type function
Author: James Cooper
Date: Tue, 10 Nov 1992 14:22
Date: Tue, 10 Nov 1992 14:22
30 lines
1770 bytes
1770 bytes
In article <XV7ZTB3w165w@tsoft.sf-bay.org>, bbs.zio@tsoft.sf-bay.org (James Elkinton) writes: >bbs.zio@tsoft.sf-bay.org (James Elkinton) writes: > [stuff about Type command that does fonts...] > >And BTW.......... > >I have received GOBS of letters saying "Make a Script", and explaining >how to do it. If I wanted a script, I would have asked for a script. >This, by the nature of its use, must not be a script. It must be in C, >or assembler, or something of that sort. I would rather have C tho, >since I don't want to mess around with assembler yet. I am having enough >of a time with C! > >Once again, NO SCRIPTS PLEASE!!!! This command is destined to be a c >directory command. Question: Why are you against using a script? If you simply create the script, put it in C:, and do a "protect c:script +s", you only need to type the name, just as you would for any other command, such as DIR or LIST. Is there some reason a script won't do the job? Are you running a version of the OS older than 1.3??? -- --------------- Jim Cooper (jamie@unx.sas.com) bix: jcooper Any opinions expressed herein are mine (Mine, all mine! Ha, ha, ha!), and not necessarily those of my employer.
Re: New specialized Type function
Author: John Bickers
Date: Wed, 11 Nov 1992 20:19
Date: Wed, 11 Nov 1992 20:19
36 lines
1734 bytes
1734 bytes
Quoted from <1992Nov10.134528.6281@daimi.aau.dk> by pilgrim@daimi.aau.dk (Jakob G}rdsted):
> I second this, as the info/knowledge on how to change font in a shell
> would be most welcomed by me, as it would open up a lot of opportunities
If you can get ahold of a pointer to the conunit for the device
for the shell's console (and I imagine it's possible, but in the
case where I had to change the font I was also the opener of the
device, so it was easy to get the conunit), then look at:
<devices/conunit.h>
and the fields:
cu_XMax
cu_YMax
cu_XRSize
cu_YRSize
cu_Font
cu_AlgoStyle
cu_TxFlags
cu_TxHeight
cu_TxWidth
cu_TxBaseline
The first four there are labeled as "read-only", so it's dodgy to
go changing them. If there's some sequence that can be sent to the
console to make it reset its font information, I'd like to know
what is it. Then you could just SetFont() the console window and
reset the console.
> Jakob Gaardsted . . | The fourth time you stumble across a posting
--
*** John Bickers, TAP. jbickers@templar.actrix.gen.nz ***
*** "Radioactivity - It's in the air, for you and me" - Kraftwerk ***
Re: New specialized Type function
Author: Jim Aites
Date: Wed, 11 Nov 1992 22:13
Date: Wed, 11 Nov 1992 22:13
20 lines
815 bytes
815 bytes
Script called 'special'
setfont iff 1tl
type []
setfont <original font, usually Topaz 8>
Make it executable
protection special +s
And make an alias
alias SPtype special []
Or is this totally wrong for what you want to do?
ps...hope I didn't completely mess-up the syntax. Get the idea?
Jim 8')s
aites@hpsmpa.lvld.hp.com
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads