473,395 Members | 1,422 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

String formatting

Hi,

Does any one know how to increase/decrease the size of the charcters in
a string, bolding the string , italicizing the string??
Are there any special functions in C to do that? Is there a way to do
it by writing our own functions? If there is can you suggest me how
to??
Thanks
Sastry

Jun 13 '06 #1
4 1976
Shastri wrote:
Hi,

Does any one know how to increase/decrease the size of the charcters in
a string, bolding the string , italicizing the string??
Are there any special functions in C to do that? Is there a way to do
it by writing our own functions? If there is can you suggest me how
to??


These are features concerning fonts, not C type chars, which is what
you'll use hold strings. There is no way you can do what you're asking
in Standard C.

Jun 13 '06 #2
"Shastri" <sa*****@gmail.com> wrote in message
news:11**********************@p79g2000cwp.googlegr oups.com...
Hi,

Does any one know how to increase/decrease the size of the charcters in
a string, bolding the string , italicizing the string??
Are there any special functions in C to do that? Is there a way to do
it by writing our own functions? If there is can you suggest me how
to??
Thanks
Sastry


Your problem sounds like it should be posted to a newsgroup dealing with the
OS you are developing for There is no font functionality in the C standard
that I know of so channging the font metrics, bolding and italicizing would
need to be handled by some kind of font package or library.
Jun 13 '06 #3
On 2006-06-13, Brand Bogard <br**********@motorola.com> wrote:
"Shastri" <sa*****@gmail.com> wrote in message
news:11**********************@p79g2000cwp.googlegr oups.com...
Hi,

Does any one know how to increase/decrease the size of the charcters in
a string, bolding the string , italicizing the string??
Are there any special functions in C to do that? Is there a way to do
it by writing our own functions? If there is can you suggest me how
to??


Your problem sounds like it should be posted to a newsgroup dealing with the
OS you are developing for There is no font functionality in the C standard
that I know of so channging the font metrics, bolding and italicizing would
need to be handled by some kind of font package or library.


The OP reminds me of Dilbert's boss insisting that he "fax it on green
paper". A string (which in C is a null-terminated array of char) has no
idea how it is displayed (if at all), any more than a faxed document knows
what color paper it will be output on.

--
Andrew Poelstra < http://www.wpsoftware.net/blog >
To email me, use "apoelstra" at the above address.
I know that area of town like the back of my head.
Jun 13 '06 #4
Andrew Poelstra <ap*******@localhost.localdomain> writes:
On 2006-06-13, Brand Bogard <br**********@motorola.com> wrote:
"Shastri" <sa*****@gmail.com> wrote in message
news:11**********************@p79g2000cwp.googlegr oups.com...
Does any one know how to increase/decrease the size of the charcters in
a string, bolding the string , italicizing the string??
Are there any special functions in C to do that? Is there a way to do
it by writing our own functions? If there is can you suggest me how
to??


Your problem sounds like it should be posted to a newsgroup dealing with the
OS you are developing for There is no font functionality in the C standard
that I know of so channging the font metrics, bolding and italicizing would
need to be handled by some kind of font package or library.


The OP reminds me of Dilbert's boss insisting that he "fax it on green
paper". A string (which in C is a null-terminated array of char) has no
idea how it is displayed (if at all), any more than a faxed document knows
what color paper it will be output on.


It's entirely possible to encode color and font information in a
string. For example, the content of the string might be HTML rather
than plain text. But the manner in which this information is encoded
(if it's there at all), and the manner in which you indicate whether
the string is to be interpreted as plain text, as HTML, or whatever,
is entirely beyond the scope of the language, and of this newsgroup.

--
Keith Thompson (The_Other_Keith) ks***@mib.org <http://www.ghoti.net/~kst>
San Diego Supercomputer Center <*> <http://users.sdsc.edu/~kst>
We must do something. This is something. Therefore, we must do this.
Jun 13 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Thomas Philips | last post by:
Consider the following simple dictionary e={1:'one', 2: 'two'} e >>>'one' However, If I attempt to print e using a formatted string print " %(1)s" %e, I get a KeyError: '1'
10
by: Oliver S. | last post by:
I've developed a string-class that holds the string in an array which is a member-variable of the class and that has maximum-size which is con- figurable through a template-parameter. If any...
20
by: hagai26 | last post by:
I am looking for the best and efficient way to replace the first word in a str, like this: "aa to become" -> "/aa/ to become" I know I can use spilt and than join them but I can also use regular...
5
by: Andrew Connell | last post by:
Having fits transforming an XML string using an XSL file. In the 1.1 version of the framework, I see that the XmlResolver is heavily used in the XslTransform class. However, that looks like I am...
4
by: Dennis Myrén | last post by:
Hi. Is there a way to utilize the great primitive data type formatting routines available in .NET without working with strings? I want a byte directly rather than a string. I think it is...
7
by: ilona | last post by:
Hi all, I store phone numbers in the database as 123447775665554(input mask is used for input, and some numbers have extensions), and I also know from db if the number is Canadian, US, or some...
7
by: L. Scott M. | last post by:
Have a quick simple question: dim x as string x = "1234567890" ------------------------------------------------------- VB 6 dim y as string
14
by: Scott M. | last post by:
Ok, this is driving me nuts... I am using VS.NET 2003 and trying to take an item out of a row in a loosely-typed dataset and place it in a label as a currency. As it is now, I am getting my...
1
by: schoedl | last post by:
Hello, we often compose strings via a ostringstream and then create a string from it. What is the rationale of not being able to use string in place of a ostringstream, so I could write ...
6
by: Jack | last post by:
Hi there, Given a standard .NET string, does anyone know what the regular expression would be to locate each (optional) formatting item in the string (or more likely does anyone have a link that...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
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,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.