Solved

How to make Scale method scale fonts in contained controls

Posted on 2008-06-19
1
370 Views
Last Modified: 2013-11-26
Hello, Experts,

I have a custom control (i.e. inherited from Control) that contains a Label.  When I apply the Scale method to this custom control, all of the contained controls also scale as expected.  However, the Label's Font does not scale.  I have an old vb.net (also v1.1) application that contains a similar custom control.  This control contains another custom control that contains a Label.  In this case the Label's Font size does change when the Scale method is applied to the outermost control.  

This makes me think that it must be possible to make the Font scale with the size of the control, but though I have studied it in detail, I cannot find the difference between my new custom control and the custom control in this older application that causes its contained fonts to scale.

Is there something obvious that I am overlooking?

Thanks for any suggestions.

Cheers,
Randy
0
Comment
Question by:omegaomega
1 Comment
 
LVL 12

Accepted Solution

by:
omegaomega earned 0 total points
ID: 21825056
I found the answer shortly after posting.  

There was an override of ScaleCore in one of the ancestors of the older application's cusotom control that was adjusting the Fonts.  Easy, I guess.  (Don't know how I managed to miss it on my earlier searches.)  (There are only three ancestors between it and Control...)

Sorry for any inconvenience.

Cheers,
Randy
0

Featured Post

DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

Question has a verified solution.

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

It’s quite interesting for me as I worked with Excel using vb.net for some time. Here are some topics which I know want to share with others whom this might help. First of all if you are working with Excel then you need to Download the Following …
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
In a recent question (https://www.experts-exchange.com/questions/28997919/Pagination-in-Adobe-Acrobat.html) here at Experts Exchange, a member asked how to add page numbers to a PDF file using Adobe Acrobat XI Pro. This short video Micro Tutorial sh…
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.

777 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