Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

how to set font and font size in file text

Posted on 2004-09-20
4
Medium Priority
?
203 Views
Last Modified: 2013-12-03
i am using pro C file manipulation operations to generate a text file. (fprintf etc) How do I set the font size of the output text. Currently the file opens with the defualt font settings.
0
Comment
Question by:chmrz
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 

Expert Comment

by:l3st4rd
ID: 12110802
a plain text file does not contain any information on the font to use. that's only possible for files that are formatted in any way like word documents, PDF's, HTML pages, aso...
so it's impossible.
0
 
LVL 55

Accepted Solution

by:
Jaime Olivares earned 80 total points
ID: 12111445
You can generate an HTML file instead a plain text because last one doesn't contain any font information, as l3st4rd pointed out. An example:

<HTML>
<BODY>
This is a plain text<p>
<b>this is a bold text</b><p>
<font color="#FF0000">This is a red text</font><p>
</BODY>

This is the easiest method to produce a formated text, another option is RTF format, it is very similar to HTML, and more suited for printable, non-Web pages.
As you can see, it will be easy to generate with simple fprintf() functions.

Good luck,
Jaime.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Preface I don't like visual development tools that are supposed to write a program for me. Even if it is Xcode and I can use Interface Builder. Yes, it is a perfect tool and has helped me a lot, mainly, in the beginning, when my programs were small…
This tutorial is posted by Aaron Wojnowski, administrator at SDKExpert.net.  To view more iPhone tutorials, visit www.sdkexpert.net. This is a very simple tutorial on finding the user's current location easily. In this tutorial, you will learn ho…
The goal of this video is to provide viewers with basic examples to understand recursion in the C programming language.
Video by: Grant
The goal of this video is to provide viewers with basic examples to understand and use nested-loops in the C programming language.

721 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question