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

x
?
Solved

Drawing text with antialiasing

Posted on 1998-05-27
3
Medium Priority
?
353 Views
Last Modified: 2013-11-20
Hi all,
I have to draw text with antialiasing .
I try to draw text using largest possible font to compatible DC. Then strech it to the size I need but effect is worst ....

Thanks in advance.
0
Comment
Question by:Livepix
[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
3 Comments
 

Expert Comment

by:rosborn051498
ID: 1315523
I'm just curious about why you need antialiasing.
0
 
LVL 2

Expert Comment

by:lucidity
ID: 1315524
why do you think, so text doesn't look like crap. From my experience MFC doesn't do that, unless you make your own font class, that sort of thing is no fun. Depending on the situation you can load DIBs or BMPs (onto a button or directly to the sreen)  which you create with the appropriate anti-aliased text. You can use transparent images or simply keep the background of the image the same as your apps background. There are several methods for different situations, depending on where you want this text. If you are interested let me know where you are trying to put this text.
0
 
LVL 3

Accepted Solution

by:
tma050898 earned 200 total points
ID: 1315525
Livepix,

You need to set the lfQuality member of the LOGFONT structure used to write text to ANTIALIASED_QUALITY. In addition, you need to make sure the OS you are running under (95 or NT) has font smoothing installed. In NT 4.0, this feature is a part of the OS. However, in 95 you will need to install it from the Microsoft web site (http://www.microsoft.com/opentype/free.htm). I believe that it also comes with MS Plus (for 95).

Tom

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

Introduction: Hints for the grid button.  Nested classes, templated collections.  Squash that darned bug! Continuing from the sixth article about sudoku.   Open the project in visual studio. First we will finish with the SUD_SETVALUE messa…
Introduction: Dialogs (1) modal - maintaining the database. Continuing from the ninth article about sudoku.   You might have heard of modal and modeless dialogs.  Here with this Sudoku application will we use one of each type: a modal dialog …
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
Video by: ITPro.TV
In this episode Don builds upon the troubleshooting techniques by demonstrating how to properly monitor a vSphere deployment to detect problems before they occur. He begins the show using tools found within the vSphere suite as ends the show demonst…

722 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