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

write words on the screen ..

Posted on 2004-10-15
Last Modified: 2010-04-01
Hi Experts,

    In the following window, I can use BitBlt to load image to the screen ... but how do I write text on the screen at certain position ??? many thanks !!!

 hWnd = CreateWindow("canvas", "Meow", WS_OVERLAPPEDWINDOW,
 SelectObject(bufdc, map) ;
BitBlt(mdc,x,y, 160, 80, bufdc, 160,0,SRCAND) ; // <----  image ... how do I put the text ???

Question by:meow00
LVL 48

Accepted Solution

AlexFM earned 200 total points
ID: 12326339
TextOut(mdc, 100, 100, _T("Text"), 4);
LVL 55

Assisted Solution

by:Jaime Olivares
Jaime Olivares earned 50 total points
ID: 12329356
DrawText() function will give you more control over alignment, clipping and bounding rectangle:
LVL 12

Assisted Solution

OnegaZhang earned 100 total points
ID: 12332690
SetBkMode(mdc, TRANSPARENT);
TextOut(mdc, 10,10,"aaaa");

welcome to www.fruitfruit.com

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
SetCurrentDirectory path limit 7 130
Lambda for random numbers problem 7 116
I could not build boost code, 10 94
show out valin of json for debugging in visaul c++ 1 41
Introduction This article is the first in a series of articles about the C/C++ Visual Studio Express debugger.  It provides a quick start guide in using the debugger. Part 2 focuses on additional topics in breakpoints.  Lastly, Part 3 focuses on th…
Introduction This article is a continuation of the C/C++ Visual Studio Express debugger series. Part 1 provided a quick start guide in using the debugger. Part 2 focused on additional topics in breakpoints. As your assignments become a little more …
The viewer will learn how to user default arguments when defining functions. This method of defining functions will be contrasted with the non-default-argument of defining functions.
The viewer will be introduced to the member functions push_back and pop_back of the vector class. The video will teach the difference between the two as well as how to use each one along with its functionality.

790 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