trichview.support
calculate line height? |
Author |
Message |
Wayne Edward |
Posted: 12/29/2002 15:10:12 I'm working on a text-based editor that uses special text-based formatting for paragraph borders. For example a paragraph will have a top and bottom border using ========== or some user specified character. I learned that I can create a style component that inherits from TRVStyle for the new properties and then use the custom-drawing events to draw the borders. I will set the SpaceBefore and SpaceAfter to make room for drawn borders. My question is since I need the editor to look as much like a simple text file (text borders are automatic) I need the space used for borders to be the same height as the text line height. How do I calculate the line height? I want to dynamically calculate the SpaceBefore and SpaceAfter to get the value of one line height. I assume it is a little more that what I get from Canvas.TextHeight but I don't know how to get the exact value. Any ideas? |
Powered by ABC Amber Outlook Express Converter