Solved

MFC : Set window title bar text center alligned

Posted on 2014-04-04
6
1,172 Views
Last Modified: 2014-04-09
How to set window title bar text center alligned?
0
Comment
Question by:RahulKajave
  • 3
  • 2
6 Comments
 
LVL 12

Expert Comment

by:satsumo
ID: 39977952
There is no way to do that unless the windows has its own frame drawing code.
0
 

Author Comment

by:RahulKajave
ID: 39977980
Hi Satsumo,
Do we have any link to support this?

Thanks
0
 
LVL 12

Expert Comment

by:satsumo
ID: 39978036
Not really because it doesn't happen, that's not how Windows works. There is a function to set title bar text. There is no function to set title bar alignment, font or any other style settings. Its difficult to find support for things not happening but I could probably find example of code for custom window frame drawing. Do you have any examples of centered title bar text?
0
ScreenConnect 6.0 Free Trial

Discover new time-saving features in one game-changing release, ScreenConnect 6.0, based on partner feedback. New features include a redesigned UI, app configurations and chat acknowledgement to improve customer engagement!

 

Author Comment

by:RahulKajave
ID: 39978056
Sorry, I dont have any of such examples
0
 
LVL 16

Accepted Solution

by:
HooKooDooKu earned 500 total points
ID: 39978066
I'll second satsumo's comment that there is no way affect the title bar other than to set the title bar text.

Basically, the title bar is totally controlled by the operating system.  It's operating system properties that sets the font and color of the title bar, and even when a program is deadlocked and not responding to the operating system, the operating system still has the power to update the title bar.

In other words, you could say that the title bar is outside of the control of the application EXCEPT for the API function that lets you modify the text.

Now of course you could create a window without a title bar, and draw your own title bar.  Then you could have full control over your title bar.  But then you would be losing all the benefits that come with a title bar (such as the power of the operating system to update the title bar even when the application is no longer responding to the operating system).
0
 
LVL 12

Expert Comment

by:satsumo
ID: 39989815
Thanks for the zero points. Question's like this really inspire me to keep using EE.
0

Featured Post

Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
logging Access violation 6 18
How to create project in Eclipse ? 1 193
Using unmanaged DLL from managed application 14 290
Test against App 49 133
Have you thought about creating an iPhone application (app), but didn't even know where to get started? Here's how: ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ Important pre-programming comments: I’ve never tri…
An Outlet in Cocoa is a persistent reference to a GUI control; it connects a property (a variable) to a control.  For example, it is common to create an Outlet for the text field GUI control and change the text that appears in this field via that Ou…
The goal of this video is to provide viewers with basic examples to understand and use pointers in the C programming language.
The goal of this video is to provide viewers with basic examples to understand recursion in the C programming language.

920 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

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now