Ok, I know all about how binary numbers translate into text characters.
My question is what exactly IS a text character? Is it a bitmap? 16 2641 th*********@comcast.net wrote: My question is what exactly IS a text character? Is it a bitmap?
This is so off-topic, you wouldn't believe it. Although I shouldn't do this
(because it may encourage others to post OT here as well):
<OT>
In the old days (and still today if you switch to CLI/DOS mode or run a
UNIX-like OS without a GUI like X) the characters were stored in memory in a
special location (setting some pointers in the BIOS memory, you could
override these) as bitmaps. The characters (or glyphs) used in GUI's like
Windows and X use more often than not a combination of curves (and sometimes
hints) to describe what they should look like.
</OT>
--
Martijn http://www.sereneconcepts.nl
Martijn wrote: th*********@comcast.net wrote:
My question is what exactly IS a text character? Is it a bitmap?
This is so off-topic, you wouldn't believe it. Although I shouldn't do this (because it may encourage others to post OT here as well):
<OT> In the old days (and still today if you switch to CLI/DOS mode or run a UNIX-like OS without a GUI like X) the characters were stored in memory in a special location (setting some pointers in the BIOS memory, you could override these) as bitmaps. The characters (or glyphs) used in GUI's like Windows and X use more often than not a combination of curves (and sometimes hints) to describe what they should look like. </OT>
Nonsense. In the old days, characters were little metal
dies that pressed an inked ribbon against paper (various
mechanical arrangements were used). With the right sequences of
characters you could get some printers to emit sounds that had
pitch and could produce recognizable tunes, but that tended to
eat holes in the ribbon and earn you a stern talking-to from the
computer operators.
--
Eric Sosman es*****@acm-dot-org.invalid
In article <-O********************@comcast.com>,
Eric Sosman <es*****@acm-dot-org.invalid> wrote: Martijn wrote:
th*********@comcast.net wrote:
My question is what exactly IS a text character? Is it a bitmap?
This is so off-topic, you wouldn't believe it. Although I shouldn't do this (because it may encourage others to post OT here as well):
<OT> In the old days (and still today if you switch to CLI/DOS mode or run a UNIX-like OS without a GUI like X) the characters were stored in memory in a special location (setting some pointers in the BIOS memory, you could override these) as bitmaps. The characters (or glyphs) used in GUI's like Windows and X use more often than not a combination of curves (and sometimes hints) to describe what they should look like. </OT>
Nonsense. In the old days, characters were little metal dies that pressed an inked ribbon against paper (various mechanical arrangements were used). With the right sequences of characters you could get some printers to emit sounds that had pitch and could produce recognizable tunes, but that tended to eat holes in the ribbon and earn you a stern talking-to from the computer operators.
Nonsense. Everyone knows that in the old days, characters
were shapes chiseled in stone.
--
rr th*********@comcast.net wrote on 02/10/05 : Ok, I know all about how binary numbers translate into text characters. My question is what exactly IS a text character? Is it a bitmap?
A text file is just another binary file. What counts is the way it is
opened and read. Use fopen() with "r", so that the end of line markers
and end of file marker (if exist) will be correctly interpreted.
I recommend fgets() for a line-oriented reading
Similary, when you create a text file, be sure to open it in text mode
("w" or "a") so that the '\n' character is properly encoded on the
file.
(The actual value is compiler dependent). Not to mention that some
system (say MS-DOS) append a special character (say Ctrl-Z) to mark the
end of text files.
--
Emmanuel
The C-FAQ: http://www.eskimo.com/~scs/C-faq/faq.html
The C-library: http://www.dinkumware.com/refxc.html
..sig under repair
"Martijn" <su*********************@hot-remove-mail.com> wrote My question is what exactly IS a text character? Is it a bitmap?
This is so off-topic, you wouldn't believe it. Although I shouldn't do this (because it may encourage others to post OT here as well):
The question is not actually off topic. It's a bit like "what does the add
sign mean?", or "when I multiply two negative numbers the program outputs a
positive, why?".
In pre-computer days a "text character" was defined by the topology of
lines. So a reasonably geometric circles with a hole in it is an "O", a
vertical triangle with a raised lower bar is a "A", and so on.
It is extremely difficult to get computers to use this system. So instead of
using writing pads, we usually use keyboards. Each key generates a character
code - for English you only need about a hundred codes to represent each
character. Internally, the computer uses these codes, almost always ASCII in
an English-speaking environment. That's why a char is usually an 8 bit
integer.
However when it comes to output, humans don't want codes. They want to see
the glyphs. These could easily be stored as bitmaps (rasters giving the dot
pattern of the character) somewhere in the computer. Alternatively you could
hook the computer up to a teletext, in which case the metal key is carved
into the shape of the character. If the computer is being used by a blind
person, you could have a device that converts the ASCII code into a pattern
of raised bumps.
These days fonts tend to be rather sophisticated, with variable pitch, anti
aliasing, kerning, sometimes other features. So the usual answer is that a
fairly complicated program writes the characters to a raster display.
However if you want to implement printf() yourself, an easy way of doing it
is to define each character by an 8 by 8 block. This gives readable output.
On Sun, 02 Oct 2005 11:14:07 -0400, in comp.lang.c , Eric Sosman
<es*****@acm-dot-org.invalid> wrote: Nonsense. In the old days, characters were little metal dies that pressed an inked ribbon against paper
Goodness me, whats with this ribbon thing? Characters were set into
great plates by highly paid typesetters, put onto a press, inked and
the paper rolled over them. This happened up until the 1980s in the
UK.
--
Mark McIntyre
CLC FAQ <http://www.eskimo.com/~scs/C-faq/top.html>
CLC readme: <http://www.ungerhu.com/jxh/clc.welcome.txt>
----== Posted via Newsfeeds.Com - Unlimited-Uncensored-Secure Usenet News==---- http://www.newsfeeds.com The #1 Newsgroup Service in the World! 120,000+ Newsgroups
----= East and West-Coast Server Farms - Total Privacy via Encryption =----
In article <43***********************@news.xs4all.nl>,
Martijn <su*********************@hot-remove-mail.com> wrote: th*********@comcast.net wrote: My question is what exactly IS a text character? Is it a bitmap?
<OT> In the old days (and still today if you switch to CLI/DOS mode or run a UNIX-like OS without a GUI like X) the characters were stored in memory in a special location (setting some pointers in the BIOS memory, you could override these) as bitmaps.
Character bitmaps stored in BIOS-accessible memory is a new-fangled
innovation. Real video character bitmaps are pulled from ROM in a
character-generator circuit. Provided, that is, that you can
get a high enough yield on the ROMs -- otherwise you Do The Right Thing
and use AND and NOT chips and shift registers.
--
Programming is what happens while you're busy making other plans.
Malcolm wrote: "Martijn" <su*********************@hot-remove-mail.com> wrote
My question is what exactly IS a text character? Is it a bitmap?
This is so off-topic, you wouldn't believe it. Although I shouldn't do this (because it may encourage others to post OT here as well):
The question is not actually off topic. It's a bit like "what does the add sign mean?", or "when I multiply two negative numbers the program outputs a positive, why?".
<snip>
Riiiight. That's not far from claiming that just about any topic
involving programming is alright for c.l.c, since C is a programming
language.
It definitely has nothing to do with C specifically, since obviously,
the rest of what you posted applies to computers in general, whether
you're using C, Pascal, Ada, or a Turing machine. The question of how C
handles characters is another matter.
But if we're on that track, let's pull in the whole
character/glyph/encoding story, rather than stick to the ASCII world. http://www.cs.tut.fi/~jkorpela/chars.html seems like a nice start.
Dealing with characters in terms of what they represent on an abstract
level tends to be more common than having to know how they're displayed,
but of course that's an important area of study as well. See http://redsun.com/type/abriefhistoryoftype/ for a nice overview of the
history of typography, including early digital typography.
S.
Emmanuel Delahaye wrote: th*********@comcast.net wrote on 02/10/05 :
Ok, I know all about how binary numbers translate into text characters. My question is what exactly IS a text character? Is it a bitmap?
A text file is just another binary file. What counts is the way it is opened and read. Use fopen() with "r", so that the end of line markers and end of file marker (if exist) will be correctly interpreted.
I recommend fgets() for a line-oriented reading
Similary, when you create a text file, be sure to open it in text mode ("w" or "a") so that the '\n' character is properly encoded on the file. (The actual value is compiler dependent). Not to mention that some system (say MS-DOS) append a special character (say Ctrl-Z) to mark the end of text files.
Don't frighten the children. If you fopen() a text file with mode "r"
you will never see '\r' nor 0x1a (^Z). Trust me on this. :-)
--
Joe Wright
"Everything should be made as simple as possible, but not simpler."
--- Albert Einstein ---
Joe Wright wrote: Emmanuel Delahaye wrote:
th*********@comcast.net wrote on 02/10/05 :
Ok, I know all about how binary numbers translate into text characters. My question is what exactly IS a text character? Is it a bitmap? A text file is just another binary file. What counts is the way it is opened and read. Use fopen() with "r", so that the end of line markers and end of file marker (if exist) will be correctly interpreted.
I recommend fgets() for a line-oriented reading
Similary, when you create a text file, be sure to open it in text mode ("w" or "a") so that the '\n' character is properly encoded on the file. (The actual value is compiler dependent). Not to mention that some system (say MS-DOS) append a special character (say Ctrl-Z) to mark the end of text files.
Don't frighten the children. If you fopen() a text file with mode "r" you will never see '\r' nor 0x1a (^Z). Trust me on this. :-)
Unfortunately, if you try to open an MS-DOS, Windows or Mac OS text file
on a Unix-style system with fopen mode "r", you will see '\r'
characters. If people used tools like ftp to transfer files between
computers, which can be told to handle files as text or binary, then if
told to use text it will handle the format conversion properly. However,
most recent methods of file transfer just copy the files exactly, and
don't convert text formats. It is left up to the destination application
to be robust to different formats.
My point is that portable C applications can no longer afford to just
use fopen in text mode and hope that the file is in the same format that
the local C library was expecting. It makes more sense to read files as
binary, and be robust to all the competing text file formats. Not just
different line endings (CR, CRLF and LF), but different character
encodings as well. I have text files in UTF-8, UTF-16, ISO-8859-1,
GB2312 and Big5 here. Wherever possible, I expect programs to not barf
on any of those formats.
--
Simon. th*********@comcast.net wrote: Ok, I know all about how binary numbers translate into text characters. My question is what exactly IS a text character? Is it a bitmap?
That depends *entirely* on the output device. A bitmap works for a
raster display, but not so well for a vector display or a teletype.
This is way beyond the scope of the C programming language, btw.
Eric Sosman wrote: Martijn wrote:
th*********@comcast.net wrote:
My question is what exactly IS a text character? Is it a bitmap?
This is so off-topic, you wouldn't believe it. Although I shouldn't do this (because it may encourage others to post OT here as well):
<OT> In the old days (and still today if you switch to CLI/DOS mode or run a UNIX-like OS without a GUI like X) the characters were stored in memory in a special location (setting some pointers in the BIOS memory, you could override these) as bitmaps. The characters (or glyphs) used in GUI's like Windows and X use more often than not a combination of curves (and sometimes hints) to describe what they should look like. </OT>
Nonsense. In the old days, characters were little metal dies that pressed an inked ribbon against paper (various mechanical arrangements were used). With the right sequences of characters you could get some printers to emit sounds that had pitch and could produce recognizable tunes, but that tended to eat holes in the ribbon and earn you a stern talking-to from the computer operators.
Characters? In the old days?
:P
--
Martijn http://www.sereneconcepts.nl
Walter Roberson wrote: In article <43***********************@news.xs4all.nl>, Martijn <su*********************@hot-remove-mail.com> wrote: th*********@comcast.net wrote: My question is what exactly IS a text character? Is it a bitmap?
<OT> In the old days (and still today if you switch to CLI/DOS mode or run a UNIX-like OS without a GUI like X) the characters were stored in memory in a special location (setting some pointers in the BIOS memory, you could override these) as bitmaps.
Character bitmaps stored in BIOS-accessible memory is a new-fangled innovation. Real video character bitmaps are pulled from ROM in a character-generator circuit.
You are right - I remember specifically liking the glyphs of one video card,
while disliking those of another (I think the latter was the Diamond Fire).
Either way I was saying that setting some pointers in the mapped BIOS memory
space - I am not sure which ones anymore - allowed you to specify one or two
alternate sets, not that they were actually stored in the BIOS. Hopefully I
am using proper nomenclature here, because I am not sure that I am.
--
Martijn http://www.sereneconcepts.nl
In article <43***********************@news.xs4all.nl>,
Martijn <su*********************@hot-remove-mail.com> wrote: Walter Roberson wrote: Character bitmaps stored in BIOS-accessible memory is a new-fangled innovation. Real video character bitmaps are pulled from ROM in a character-generator circuit.
You are right - I remember specifically liking the glyphs of one video card, while disliking those of another (I think the latter was the Diamond Fire). Either way I was saying that setting some pointers in the mapped BIOS memory space - I am not sure which ones anymore - allowed you to specify one or two alternate sets, not that they were actually stored in the BIOS. Hopefully I am using proper nomenclature here, because I am not sure that I am.
BIOS?? You must be one of them Pro-gress-ives chaps. You probably
didn't even build your own terminal !! Back in my day, we had to worry
about re-using scan lines in the ROM because 256 byte ROMs were so
expensive.
--
I was very young in those days, but I was also rather dim.
-- Christopher Priest
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Walter Roberson wrote: In article <43***********************@news.xs4all.nl>, Martijn <su*********************@hot-remove-mail.com> wrote:
Walter Roberson wrote:
Character bitmaps stored in BIOS-accessible memory is a new-fangled innovation. Real video character bitmaps are pulled from ROM in a character-generator circuit.
You are right - I remember specifically liking the glyphs of one video card, while disliking those of another (I think the latter was the Diamond Fire). Either way I was saying that setting some pointers in the mapped BIOS memory space - I am not sure which ones anymore - allowed you to specify one or two alternate sets, not that they were actually stored in the BIOS. Hopefully I am using proper nomenclature here, because I am not sure that I am.
BIOS?? You must be one of them Pro-gress-ives chaps. You probably didn't even build your own terminal !! Back in my day, we had to worry about re-using scan lines in the ROM because 256 byte ROMs were so expensive.
Well, ain't you fancy!!
I still have a printer that you can change the print head on to get different
characters for the same codepoint. The one I have downstairs is a
"daisy-wheel" printer that used a print head shaped like a 100-petal daisy.
Each petal has a different glyph embossed in it's surface, and the printer
rotates the print head to position each glyph behind a hammer.
My old Teletype ASR33 used a cylinder which had 60 or so glyphs embossed on
it. The hardware rotated the cylinder so that the proper glyph was positioned
behind the print hammer.
In both cases, the hammer whacked the print head, which drove the embossed
glyph into the print ribbon, and smacked the ribbon against the paper, leaving
an imprint of the glyph in ribbon ink on the paper. No fancy ROMs or BIOS for
those babies. Just good old typewriter and printing press technology.
:-)
- --
Lew Pitcher
Master Codewright & JOAT-in-training | GPG public key available on request
Registered Linux User #112576 ( http://counter.li.org/)
Slackware - Because I know what I'm doing.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.7 (GNU/Linux)
iD8DBQFDRHcAagVFX4UWr64RAprpAKCfIqxj1jRFt2CV99IV4W 6Df0PatACglSEj
vWHiYCccKxvErfyEdqJnq0Y=
=3dqM
-----END PGP SIGNATURE-----
"Rouben Rostamian" <ro****@pc18.math.umbc.edu> wrote in message
news:dh**********@pc18.math.umbc.edu... In article <-O********************@comcast.com>, Eric Sosman <es*****@acm-dot-org.invalid> wrote:Martijn wrote: th*********@comcast.net wrote: My question is what exactly IS a text character? Is it a bitmap? This is so off-topic, you wouldn't believe it. Although I
shouldn't do this (because it may encourage others to post OT here as well): In the old days (and still today if you switch to CLI/DOS mode or
run a UNIX-like OS without a GUI like X) the characters were stored in
memory in a special location (setting some pointers in the BIOS memory, you
could override these) as bitmaps. The characters (or glyphs) used in
GUI's like Windows and X use more often than not a combination of curves (and
sometimes hints) to describe what they should look like. Nonsense. In the old days, characters were little metal dies that pressed an inked ribbon against paper (various mechanical arrangements were used). With the right sequences of characters you could get some printers to emit sounds that had pitch and could produce recognizable tunes, but that tended to eat holes in the ribbon and earn you a stern talking-to from the computer operators. Nonsense. Everyone knows that in the old days, characters were shapes chiseled in stone.
Chisels? You were lucky.
In the old days, we had to lick shapes into the stones with our tongues.
Whole villages were forced into slavery for 5 years just to make one
"Keep Left" sign.
--
Mabden This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: red |
last post by:
What is this and why does it appear on my web pages:  ?
In case the font doesn't translate into newsgroups, its a funny looking
i with two dots over the top, two greater than signs real close...
|
by: Sarah Tanembaum |
last post by:
Beside its an opensource and supported by community, what's the fundamental
differences between PostgreSQL and those high-price commercial database (and
some are bloated such as Oracle) from...
|
by: Steven T. Hatton |
last post by:
I'm still not completely sure what's going on with C++ I/O regarding the
extractors and inserters. The following document seems a bit inconsistent:...
|
by: typingcat |
last post by:
First of all, I'm an Asian and I need to input Japanese, Korean and so
on. I've tried many PHP IDEs today, but almost non of them supported
Unicode (UTF-8) file.
I've found that the only Unicode...
|
by: jacob navia |
last post by:
I would like to add at the beginning of the C tutorial I am writing
a short blurb about what "types" are. I came up with the following text.
Please can you comment?
Did I miss something?
Is...
| |
by: Michael Goldshteyn |
last post by:
Consider the following two lines of code, the first intended to print "Hello
world\n" and the second intended to print the character 'P' to stdout.
---
std::cout <<...
|
by: Matthew Zhou |
last post by:
I check the ISO 9899 standard,
\r (carriage return) Movesthe active position to the initial position
of the current line.
What does it do? How to input?
I tried to use Flex to check this...
|
by: Banfa |
last post by:
I felt that this was a good point to start a tutorial on C/C++ programming because clearly we need to have some idea of what we are trying to achieve before we start out. I recently found this...
|
by: rynato |
last post by:
I have a <spanof width X px and height Y px. I want to read the text
of an article, which is stored in a mySQL table, and pass to that
<spanonly just enough text to fit in it, along with a 'read...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
| |
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...
| |