I have a TImage component that I print a Text string to using TCanvas.TextOut(). I set the height and width of the TImage to a large size like 50 pixels X (TextWidth) pixels, and set the Canvas font Height to something a little smaller like 48 pixels. I then BitBlt() the TImage's bitmap on to the main Canvas. What I see on the screen ...
I have a UIButton of fixed width and I want to place text in it. Since the size of the String is unknown in advance, I will have to resize the font as I read the String from a flat file. How can I do that? A function similar to the following will be great:
UIFont resizeFontAs:(UIFont)initialFont andStringAs:(NSString*)string andWidthA...
Hello,
I have a font texture which I use in order to draw text on top of my OpenGL scene.
The problem is that the scene's colors vary so much that any solid color I use is hard to read. Is it possible to draw my font texture with inverted colors?
A call to glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); would just draw it with a sol...
I can use @font-face but it does not work in all browsers.
Are there any way to use custom font file in my site ?
...
I have the following lines in my Java applet init function:
try {
this.font = Font.createFont(
Font.TRUETYPE_FONT,
new File("fonts/myfont.ttf")
).deriveFont(24f);
GraphicsEnvironment.getLocalGraphicsEnvironment().registerFont(font);
} catch(Exception ex){
System.out.println(ex);
}
When I open the applet with the applet...
Hi All,
I wrote small java Swing/canvas program where I can draw some textboxes.
Now I'd like to export those text areas to a set of HTML div.
What would be the best way (font-family ? font-face? css selectors ?) to obtain the same rendering as in Java ?
Thanks
...
Hi,
I am trying to render texture dynamically in my opengl application.
Basically I am tring to use (CGSize)drawAtPoint:(CGPoint)point withFont:(UIFont *)font and capture it to a texture. But I am not able to figure out how to convert CGContext stuff to texture.
...
Update (in response to first answer, from Hans Passant):
I guess I didn't explain my use-case well enough. This application will be designed for people to enter data in a "master" language (most likely English, but not necessarily), and then facilitate the entry of translations in another language. This is all done with a rich-text box ...
I have an application that writes text onto images using system.drawing (C#). I am using specific fonts to do this. Since I can't rely on my shared hosting servers to have all the custom fonts I may need (and since the list of fonts is likely to grow), how can I manage the fonts used for my application? Could I include .ttf files in m...
Is it possible to assign different fonts to different font-weights?
For example, If I have 2 fonts, "helvetica roman" and "helvetica bold" and I want a font-weight of 500 to always display "helvetica roman" and a font-weight of 700 to always display "helvetica bold"
I know this functionality is available through cufon, but would like ...
Hello, I have Google for an hour now and I can't find out if I can use @font-face using the Segoe UI font. Would any body know if the license for the font will allow me to do this?
...
Hello,
What i need to do is have the font file name (not Font Family name) after selecting a font in the FontDialog,
so that if i selected "Harlow Solid Semi" from the Dialog, i need to get the file name, which is "HARLOWSI.TTF"
so is it possible ? if not using the fontDialog, can it be done other way ?
Note: i need the user to see a sa...
Hey everyone, I have a website that i want to use Adobe fonts on it. can anyone please help with it ??? the files i got are .otf
Many thanks
...
How do you add a new line character to a string when using a custom font in cocos2d?
I have my atlas font and i tell i put the new line character into it and then tell it what font to use.
CCBitmapFontAtlas *text = [CCBitmapFontAtlas bitmapFontAtlasWithString:@"Something\nSomething else " fntFile:@"generic_font.fnt"];
In the .fnt fil...
I am having trouble with this assignment because my of my actionlisteners. Right now the panel has 2 checkboxes to change the font into bold and or italic. I want to add 4 radio buttons that can change what font the "saying" is in. Can anyone tell me what I'm doing wrong with my actionlisteners? Thank you!
import javax.swing.*;
impor...
Hey all, I'm looking to simplify the handling of a three-item Boolean expression. "Select Case" doesn't seem offer a solution for triple values, and the If statement seems a bit much. It'll work the way I coded it, but if you have any ideas on how to simplify this, I'd appreciate your insights. If not, I hope this snippet can save someon...
My screen looks good in IE8 under Windows XP. But when I open it in IE8 under Windows Server 2003, all text is more bold than in XP. I can apply styles to it, for example change font-weight in css, but in that case font weight changes under Windows XP too and in any case my screen looks differ.
...
I have an app that contains a custom view, and in it I want to use a custom font. Unfortunately, this results in really ugly text being rendered.
My custom view extends Surface (and just realized: is this a bad idea), and I draw the text with the following code:
// p = new Paint();
Typeface font = Typeface.createFromAsset(parent.getAss...
I was reading now about how it’s a good practice to set the font on <body> to 62.5%, so that later you can use the divide-by-10 conversion from pixel units.
But I was wondering: why not set <body> to 6.25%? Then you can use the same dimensions for em units as for pixel units, assuming the default browser font size is 16 pixels.
E.g.
b...
In a reporting services report, I'm displaying a bullet point by using the expression :
=ChrW(&H2022)
This is in a TextBox setup to use Arial font.
Now, it seems to work fine, but how safe is it ? i.e. is it likely to work on all PCs ? (The application is a web application).
...