How to set same pixel size for each character ?
Hi! All,
Does anybody know how to set same pixel size for each character ?
Please do the needful..
Thanks in advance..
Regards
Sam
Re: How to set same pixel size for each character ?
What are you talking about ? What character ?
Re: How to set same pixel size for each character ?
Quote:
Originally Posted by
mr.sam1024
Does anybody know how to set same pixel size for each character ?
As usual, your question is NOT clear. :confused:
However, if you still continue to struggle with your Richedit control then I'd recommend you to look at the Monospaced font
IOW you need to choose some of available monospaced fonts (like courier or some others)
Re: How to set same pixel size for each character ?
Yes, Monospaced font have fixed-wdith, but other fonts like "Terminal" "MS Gothic" "Times New Roman" Each character (A - Z , a -Z , 0 - 9) have occupy different size (in pixels). So that can we do it programmetically to set same size for each character ?
Re: How to set same pixel size for each character ?
Quote:
Originally Posted by
mr.sam1024
Yes, Monospaced font have fixed-wdith, but other fonts like "Terminal" "MS Gothic" "Times New Roman" Each character (A - Z , a -Z , 0 - 9) have occupy different size (in pixels). So that can we do it programmetically to set same size for each character ?
No, we cannot! Period.
Or you would have to implement your own window class where you'd make all drawing with your own fonts (but again, these "your own fonts" will have nothing to do with the standard ones)
Re: How to set same pixel size for each character ?
Quote:
Originally Posted by
mr.sam1024
Yes, Monospaced font have fixed-wdith, but other fonts like "Terminal" "MS Gothic" "Times New Roman" Each character (A - Z , a -Z , 0 - 9) have occupy different size (in pixels). So that can we do it programmetically to set same size for each character ?
To do that you set some mono space font for your window. :)
Re: How to set same pixel size for each character ?
Quote:
Originally Posted by
mr.sam1024
Yes, Monospaced font have fixed-wdith, but other fonts like "Terminal" "MS Gothic" "Times New Roman" Each character (A - Z , a -Z , 0 - 9) have occupy different size (in pixels). So that can we do it programmetically to set same size for each character ?
You can't. But as you've been told, you're headed in the wrong direction. I'd still like to know why you're insisting on a RichEdit Control. There are other, much more appropriate ways to do what you're trying to do.
Re: Set same Pixel size for each character
GCDEF,
can you tell me what are the other appropriate ways to do ?
I'm implementing terminal (lly like Hyper Terminal) So that i choosen RichEdit Control and Need to implement VT-100 Emulation type to support ANSI escape sequences. I'd discussed about this in other thread.
Re: Set same Pixel size for each character
I'd be looking at CWnd or perhaps CView.
Re: Set same Pixel size for each character
Quote:
Originally Posted by
mr.sam1024
... and Need to implement VT-100 Emulation type to support ANSI escape sequences. I'd discussed about this in other thread.
No, you did not.
Instead you only asked some meaningless questions about rows/columns in the empty rich edit control! :thumbd:
Note also that "Hyper Terminal" window is not a rich edit control nor does it support any row/column concept.
Re: Set same Pixel size for each character
How Hyper Terminal is implemented ? which control is used ? or is it a CView ?
Re: Set same Pixel size for each character
Quote:
Originally Posted by
mr.sam1024
How Hyper Terminal is implemented ?
Well, I guess only Hyper Terminal developers could answer this question
Quote:
Originally Posted by
mr.sam1024
which control is used ? or is it a CView ?
No, it is NOT a CView. You could find it out using Spy++.
Re: Set same Pixel size for each character
Quote:
Originally Posted by
mr.sam1024
How Hyper Terminal is implemented ? which control is used ? or is it a CView ?
I doubt it's a control at all. Quite possibly not even MFC.
Re: Set same Pixel size for each character
If i check in Spy++. It is showing the class of the window: TermClass.