Is there any way in a ifstream to change the font it writes in???
Thanks! Im using Microsoft Visual C++ Extended Edition 2005 on Windows XP

Recommended Answers

All 2 Replies

Is there any way in a ifstream to change the font it writes in???
Thanks! Im using Microsoft Visual C++ Extended Edition 2005 on Windows XP

Do you mean ofstream? ifstream doesn't write.

ofstream doesn't write with a font. It will write text to a file. What text is displayed and what font the text is displayed in is determined by how whatever program is reading the file interprets that text. For example, a browser parses the text looking for tags/tokens like <body>, "style", "color" and "font" and displays certain text based on those. But ofstream neither knows about nor cares about any of that. It simply outputs text to a file.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.