Solved

Superscript text in dialog boxes

Posted on 1998-02-23
3
423 Views
Last Modified: 2013-11-20
How can superscript text (x^2, y^3, etc. without having to show the carrot symbol) be displayed in dialog boxes? Also, to update this at run-time, how can the strings be concatenated to indicate superscript text?
0
Comment
Question by:makarand031097
3 Comments
 
LVL 15

Expert Comment

by:Tommy Hui
ID: 1316500
Most of the regular controls in a dialog can only use one font. A particular font can either be superscripted or not, but it cannot change once created. If you need to use more than one font, then you will have to use a rich edit control, but then you will have some work ahead of you because a rich edit control can not be easily placed in a dialog without some work.
0
 

Author Comment

by:makarand031097
ID: 1316501
I am using a *single* font in the dialog box. However, I could not find a way to display superscripted text. Secondly, I will need to update the text fields dynamically. How do I compose strings and how do I indicate that certain text in it should be superscripted?
0
 
LVL 7

Accepted Solution

by:
galkin earned 100 total points
ID: 1316502
No common control allows you to use superscript text since as thui pointed out absolutly correctly these controls can use only one font. You have to choices. First you can use UNICODE, create you own font when you can define characters you need. Since in UNICODE you can display up to 65536 characters you can do this. But only windows NT supports UNICODE windows 95 uses ANSI. Other way is to create you own control, i.g. ActiveX control and perform your own painting characters as superscripted. This involves rather much work but this is the only way to do this.
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
has22 challenge 11 94
modThree challenge 4 90
noX challenge 17 116
Excel file not created as expected 7 72
Here is how to use MFC's automatic Radio Button handling in your dialog boxes and forms.  Beginner programmers usually start with a OnClick handler for each radio button and that's just not the right way to go.  MFC has a very cool system for handli…
Introduction: Ownerdraw of the grid button.  A singleton class implentation and usage. Continuing from the fifth article about sudoku.   Open the project in visual studio. Go to the class view – CGridButton should be visible as a class.  R…
This Micro Tutorial will teach you how to censor certain areas of your screen. The example in this video will show a little boy's face being blurred. This will be demonstrated using Adobe Premiere Pro CS6.
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.

770 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