Using own font in j2me

Hi,
i am facing problem using own font( bangla font) in my j2me application. i dont know how can i install my own font in the mobile and use it in my application. if u have any idea then please help me.
======================== mamun

The only way to do it is using some custom code to display fonts, since there is no way to install new fonts onto a device.

Similar Messages

  • How to use unicode font in J2ME

    Hi,
    I want to create some mobile application using Unicode Font in J2ME.
    Please help me about how to use Unicode Font in J2ME and how to configure Unicode Font in J2ME SDK 3.0 Early Access

    http://saloon.javaranch.com/cgi-bin/ubb/ultimatebb.cgi?ubb=get_topic&f=2&t=001235
    http://www.linuxforum.net/chinese/develop/java.html
    Hope its of help to you.

  • PS CS6 has a different set of installed fonts than my old PS CS4.  How do I get my old fonts back?  Don't like most of the CS6 fonts.  Dell Precision, Windows 7.  Does PS use the fonts in the Windows directory or does it use its own?  A lot of my preferre

    PS CS6 has a different set of installed fonts than my old PS CS4.  How do I get my old fonts back?  Don't like most of the newer CS6 fonts.  Dell Precision, Windows 7.  Does PS use the fonts in the Windows directory or does it use its own?  If so, where are they in the directory?  A lot of my preferred fonts show in the Windows directory but not in Photoshop, which does not display them within the program.  Please help.  If I get free fonts (NOT CC fonts) from elsewhere, where do I put them for Photoshop[ CS6 to use them?  Thanks.

    All versions of Photoshop get their fonts from your OS.  Just install any missing font wherever Windows keeps fonts.
    I don't do windows myself.

  • Display problems with allowing web pages to use their own fonts, both on and off.

    I refer to the "Allow pages to choose their own fonts, instead of my selections above" option in the Content > Advanced tab of the Options menu.
    When I have this option unchecked, allowing my font choice to override the default non-image generated text for web pages, it seems that many icons and buttons on numerous sites are replaced by some sort of hex code malfunction. They appear as small boxes with four characters inside. I'm sure someone knows the official term for what these are and why they occur.
    When I have the option checked, however, any non-image generated text on numerous websites appears as an ugly Stencil font that I simply cannot find the origin of. It should not be and clearly isn't the default font for all of these different sites. By "non-image generated text", I mean any text that is not incorporated into the design of the page.
    This issue has persisted through several full re-installs. Any insight into a solution for one or both sides of this problem would be quite appreciated. Thanks for reading.

    You would have to remove (uninstall) or reinstall the Georgia font if it is currently corrupted.
    You can use the System File Checker to check for missing and corrupted font files.
    It needs to be run from an Elevated Command Prompt.
    Open a cmd.exe window as Administrator:
    Start, click Programs, click Accessories
    Right-click Command Prompt, and choose "Run as administrator"
    Click past the UAC Screen
    After the cmd.exe prompt, type: sfc.exe /scannow and press Enter
    * http://windowsforum.com/threads/system-file-checker-a-great-windows-fix-tool.19250/

  • Even with "Allow pages to use their own fonts" enabled, firefox sill dictates fonts on some sites. WTF.

    I built my website to show some work I did, everything was fine in firefox 3.6 but i upgraded today and now the font styles i wrote into the page are being overridden somehow.
    Yes, i checked allow pages to use their own fonts.

    That should work unless the specified font is missing or corrupted and in that case you need to (re)install that font.

  • How can i use my own Fonts in iCloud Pages?

    How can i use my own Fonts in iCloud Pages?

    Baluk wrote:
    And WebHosted Fonts like GoogleFonts?
    No.
    To tell Apple you want such features added, go to
    http://www.apple.com/feedback

  • Can't use my own font due to license restriction?

    I created my own font ("GoudyMusic") using fontlab.com | TypeTool3. When I try to 'print' to a pdf using Adobe PDF, I get:
    %%[ ProductName: Distiller ]%%
    %%[ Error: GoudyMusic cannot be embedded because of licensing restrictions. ]%%
    %%[ Font vendor (Macromedia) does not permit this font to be embedded in PDF. ]%%
    [Warning] The font GoudyMusic could not be embedded because of licensing restrictions.
    Text may display incorrectly on platforms that do not have this font installed.
    %%[ Error: invalidfont; OffendingCommand: show; ErrorInfo: CharOffsets  º %%[ Flushing: rest of job (to end-of-file) will be ignored ]%%
    %%[ Warning: PostScript error. No PDF file produced. ] %%
    Help help!
    THANX!
    william zeitler

    Apparently fontlab.com's TypeTool3 does not allow you to set licensing, and it defaults to 'not-embeddable'.
    You have to upgrade to Fontographer (another $300) to be able to set the licensing. Now that I've done that, it works.

  • Fonts in J2ME

    Hi,
    Iam displaying a string on Canvas.
    I want to know if i can display the string using different font type and size, other than provided by J2ME.
    For eg can i use Times New Roman or Courier.
    Do i have to write my own Font classes?
    Thanks,
    Sangram

    Hi Sangram,
    That's no possible. You can only use the default font settings to create a font object in J2ME.
    You will have to write some Font implementation on your own.
    Cheers,
    Jasper

  • How do I use a font variation in a pages document. I no longer have the "viewer" -glyph option in special characters pane only new mbPro with Lion. I know the variation is available because I can see it in the font book. so now what I just want to be

    How do I use a font variation in a pages document? or other app for that matter? I no longer have the "viewer" - glyph option in the special characters pane (under edit  in toolbar). I know the varaition ia available because I can see it in my font book. I depended on that alot so I need to find a way to still use character and embellishments. I don't want to have to go back to my od computer (from2007) Please Help!

    I really don't understand.
    The menu item is available :
    Maybe, you didn't activate the tool :
    Yvan KOENIG (VALLAURIS, France) mardi 2 août 2011 23:10:17
    iMac 21”5, i7, 2.8 GHz, 4 Gbytes, 1 Tbytes, mac OS X 10.6.8 and 10.7.0
    My iDisk is : <http://public.me.com/koenigyvan>
    Please : Search for questions similar to your own before submitting them to the community
    To be the AW6 successor, iWork MUST integrate a TRUE DB, not a list organizer !

  • Why is getLineMetrics inaccurate when using device fonts* or immediately after resizing a TextField?

    1.  We need getLineMetrics to return correct values immediately after changing a TextField's width/height or any property that would affect the layout metrics, withouth having to alter other properties like setting the text to itself (p1.text = p1.text).  Currently, if you change the width of a text field to match the stage width for example, getLineMetrics will not return correct values until the next frame.... UNLESS you set the text property.
    2.  We also need some kind of "stage scaled" event in addition to the "stage resize" event (which only fires when stage scale mode is no_scale), because stage scaling affects the rendered size of device fonts so dramatically that we must call getLineMetrics again.  This is not the case for fonts antialiased for readability, since their size is relatively stable with scaling, as demonstrated by drawing a box around the first line once and then scaling the stage.
    So those are the problems.  The asterisk in the title of this post is there because it seem that TextField.getLineMetrics is accurate with device fonts, but I cannot take advantage of that accuracy without a way to detect when the player is scaled.  I can only confirm its accuracy at a 1:1 scale, since there is no way to recalculate the size of the line rectangle once the player is scaled, aside from setting a timer of some sort which is a real hack not to mention horribly inefficient with no way to detect when the stage has actually be scaled.
    I use device fonts because embedded fonts look terrible and blurred compared to device font rendering.  The "use device font" setting matches the appearance of text in web browsers exactly.  The only way to get embedded/advanced antialiased text in flash to approximate that of the device font look is to primarily set gridFitType to PIXEL instead of SUBPIXEL, and secondly set autokerning to true to fix problems caused by the PIXEL grid fit type.  That ensure strokes are fitted solidly to the nearest pixel, however it still lacks the "ClearType" rendering that device fonts use, which has notable color offset to improve appearance on LCD monitors, rather than the purely grayscale text that flash uses in its subpixel rendering.  Frankly, failure to use device fonts because of API issues, is the only reason why Flash sometimes doesn't look as good as HTML text and why people say text in Flash "looks blurry".  I'm tired of hearing it.  If the player simply dispatched an event when scaled and updated the metrics immediately when any property of the text field that would affect the metrics is changed, then we could all happily use device fonts and Flash text would look great.  As is stands, because of the two problems I mentioned in the opening paragraph, we're stuck dealing with these problems.
    If you create two text fields named "p1" and "p2" for paragraph 1 and 2, populate them with an identical line of text and set one to "use device fonts" and the other to "antialias for readability", then use this code to draw boxes around the first line of text in each of them:
    import flash.text.TextField;import flash.text.TextLineMetrics;graphics.clear();drawBoxAroundLine( p1, 0 );drawBoxAroundLine( p2, 0 );function drawBoxAroundLine( tf:TextField, line_index:int ):void{          var gutter:Number = 2;          var tlm:TextLineMetrics = tf.getLineMetrics( line_index );          graphics.lineStyle( 0, 0x0000ff );          graphics.drawRect( tf.x + gutter, tf.y + gutter, tlm.width, tlm.height );}
    The box surrounding the line of text in the "use device fonts" box is way off at first.  Scaling the player demonstrates that the text width of the device font field fluctuates wildly, while the "antialias for readability" field scales with the originally drawn rectangle perfectly.  That much is fine, but again to clarify the problems I mentioned at the top of this post:
    Since the text width fluctuates wildly upon player resize, assuming that getLineMetrics actually works on device fonts (and that's an assumption at this point), you'd have to detect the player resize and redraw the text.  Unfortunately, Flash does not fire the player resize event unless the stage scale mode is set to NO_SCALE.  That's problem #1.  And if that's by design, then they should definitely add a SCALE event, because changes in player scale dramatically affect device font layout, which requires recalculation of text metrics.  It's a real issue for fluid layouts.
    The second problem is that even when handling the resize event, and for example setting the text field width's to match the Stage.stageWidth property, when the text line wraps, it's not updated until the next frame.  In other words, at the exact resize event that causes a word to wrap, calling getLineMetrics in this handler reports the previous line length before the last word on the line wrapped.  So it's delayed a frame.  The only way to get the correct metrics immediately is basically to set the text property to itself like "p1.text = p1.text".  That seems to force an update of the metrics.  Otherwise, it's delayed, and useles.  I wrote about this in an answer over a year ago, showing how sensitive the text field property order is: http://stackoverflow.com/a/9558597/88409

    As I've noted several times, setting the text property to its own current value should not be necessary to update the metrics, and in some subclasses of text field, setting a property to its own value is ignored as the property is not actually changing and processing such a change would cause unnecessary work which could impact application performance.  Metrics should be current upon calling getLineMetrics.  They are not.  That's the problem.
    From a programming perspective, having to set the text property (really "htmlText" to preserve formatting) to itself to update metrics is almost unmanagable, and doesn't even make sense considering "htmlText" is just one of a dozen properties and methods on a TextField that could invalidate the layout metrics (alignment, setTextFormat, width, height, antiAliasMode, type, etc.), and I would have to override every one of those properties so that I could set htmlText = htmlText.  Using such a subclass isn't even possible if I want to use the Flash IDE to add text fields to the stage.  I would have to iterate over the display list and replace all existing fields with my subclass, which also isn't a good workaround because there's no way to update any and all variable references that may have been made to those instances.
    Frome what I've read, the invalide+render event system is unreliable.  My layout framework is similar to that of Windows Forms, and performs layout immediately, with dozens of docking modes and uses suspend and resume layout calls for efficiently resizing multiple child objects in a component.  Certain calculations cannot be aggregated for a render event, because some containers are semi-reflexive, meaning they can expand to fit the child contents while also contraining the child size, depending on whether the contain was resized or the child component was resized, so as a matter of correctness the resizing calcultation must occur immediately when the child resizes, otherwise a top-down pass on the display hierarchy for resizing will not be sufficient.
    As far as waiting until the next frame, no that is not possible, as it will cause one frame to be completely wrong.  If I was dragging the browser window to resize it, it would look terrible as virtually every single frame during the resizing operation would be incorrect.  Also, in the case where a user clicks the maximize or restore button of the web browser, the resizing event will occur exactly once, so if the metrics are not correct when that occurs, there is no recalculation occuring on the next frame, it will just be wrong and sit there looking wrong indefinitely.
    In case it's not obvious by now, this is a web application.  It uses the NO_SCALE stage scaling option, so notification of the event is not actually an issue for me personally.  I was just pointing out that for anyone not using the NO_SCALE option, there is no event in Flash to detect player scale.  What you're suggesting is using a JavaScript event and using the ExternalInterface bridge to send a message, which there is no guarantee whether it will be processed in a timely matter by the player and introduces possible platform inconsistancies, depending on whether the browser has actually resized the Flash interface at that point or what state Flash is in when it tries to recalculate the size of the text.  The browser may send that event to flash before the player is actually resized, so it will be processing incorrect sizes and then resized after the fact.  That's not a good solution.  Flash needs a scale event in addition to a resize event.  I'm really surprised it doesn't have one.  At the very least, the existing resize event should be dispatched reguardless of the stage scale mode, rather than occuring exclusively in the NO_SCALE mode.
    Bottom line is that getLineMetrics needs to return correct values every time it is called, without having to set the "text" property immediately before calling it.  If such a requirement exists, which seems to be the case, then that needs documented in the getLineMetrics method.

  • Can't find text in distilled file, using some fonts

    The products I have are Mac OS 10.6.8, Acrobat X and 9, and Word 2011 and Apple Pages for Mac; Acrobat 9 and Word 2007 for Windows XP.
    There are numerous ways to create PDFs on both platforms, whether through save as or creating a PostScript file and distilling it. The problem is that with docs I have using Calibri, Cambria, and Candara, if I distill a PostScript file made from Mac Word or Pages, neither Acrobat nor Apple Preview can find text in the resulting PDF, whether the file distilled with Mac or Windows Distiller. (Meaning a "find" for a string comes up as not found.)  All other combinations are okay, even writing a PS file in Windows Word and distilling with Mac Distiller.
    I mention the fonts specifically because most of the time I use OTF faces, which always work. I even tried using the Windows TTF versions in the Mac operating system -- same failure.
    And even if I force these fonts to be embedded in the Distiller job options, still no joy. If I take so much as a comma and set it to an OTF, I can find the comma. Also, Acrobat *can* find Arial text in a Visio flowchart placed in the Word doc. I don't know how the author placed it there, but it's probably copy from Visio, paste into Word.
    The reason why I care about this is because the distilled PFDs are just a tiny bit better looking on the screen than other options, such as "Save as PDF" from the Mac OS Print dialogue. The only other one that looks as good is the Create PDF button in Windows Word, but I would rather not have to use Windows just to get a better-looking PDF.
    So to summarize:
    Mac app > write PS file > Mac Distiller = fail
    Mac app > write PS file > Win Distiller  = fail
    Win app > write PS file > Mac Distiller  = okay
    Win app > write PS file > Win Distiller  = okay
    Mac app > save as PDF directly > okay
    This might not be a problem with Distiller per se; it could be the Mac OS engine that creates the PS files. You see, I had heard that Apple used their own internally developed engine for the options to save PDF files directly, but was using Adobe code when one used the option to write a PostScript file, so that's why I'm so surprised and disappointed it fails.

    tlmurray23 wrote:
    The reason why I care about this is because the distilled PFDs are just a tiny bit better looking on the screen than other options, such as "Save as PDF" from the Mac OS Print dialogue. The only other one that looks as good is the Create PDF button in Windows Word, but I would rather not have to use Windows just to get a better-looking PDF.
    Hmmm. In what way are Distilled PDFs "a tiny bit better looking on screen" than those made by OS X?
    You are viewing both in the same app and platform?
    And you're referring to font display?
    What settings are you using in Distiller which you think might have some bearing on this?
    tlmurray23 wrote:
    This might not be a problem with Distiller per se; it could be the Mac OS engine that creates the PS files. You see, I had heard that Apple used their own internally developed engine for the options to save PDF files directly, but was using Adobe code when one used the option to write a PostScript file, so that's why I'm so surprised and disappointed it fails.
    OS X's native graphics drawing environment, Quartz, is essentially a "Display PDF", so creating a PDF file is a very simple procedure.
    Writing PostScript for printing uses Apple's own cgpdftops CUPS filter. I doubt there is any "Adobe code" as such, and I dispute the implication that "Apple code == bad; Adobe code == good", which you seem to suggest.
    The specifications for PDF and PostScript are clearly documented, and it should be easy for anyone to follow them.
    However, the fact remains that when Apple converts these MS fonts to PS, something goes wrong. It may be a bug in Apple's code; or it may be that Apple it strictly interpreting font data which MS is playing fast and loose with. Windows' own PS export would no doubt be designed to work with the looser implementation in MS's fonts. This is just hypothetical of course, though is in keeping with tradition.
    What you could do is use a decent text editor like TextWrangler (free from BareBones software) to compare the PostScript code from Windows and OS X.
    You could also look a the Properties tab in Acrobat of the PDFs, and compare the font encoding.
    You could also test running out PostScript from any other app on OS X that you have using those fonts.
    However, I think it is unlikely that you will see resolution unless MS releases a new version of their fonts, or some new version of OS X makes an amendment to fix the bug or cater for the MS issue. Perhaps Lion will do this; perhaps it won't.
    Are you using the versions of these fonts that came with Office 2011 for Mac? What happens if you use the Windows versions of the fonts on OS X?

  • "Allow pages to choose own fonts" doesn't always work

    I don't know if this is a problem with my browser preferences or with how the browser sees certain websites.
    In Preferences, I have the box checked for "Allow pages to choose their own fonts, instead of my selections above." It's been checked for as long as I've been using Firefox. (Now using 6.14)
    Now, for certain sites, this no longer works -- the site always comes up using my default fonts. Since I'm trying to tinker with CSS on one of these sites, it's very annoying not to be able to see what I'm doing. The page looks fine in Safari, so I'm fairly sure the problem is with my computer rather than the website.
    This only happens with some sites. I have no idea why it would do this to some sites and not others. Some sites display their own fonts just fine.
    This started happening just a few day ago (but before I upgraded to 6.14). Shutting down and rebooting the computer doesn't help. Clearing the browser cache and quitting and restarting Firefox didn't help either.

    At first I thought this wouldn't work -- but after I removed a troublesome font, and replaced it with another version of the SAME font, it actually did.
    Bizarro. ;)

  • Showing bangla character in all types of java mobile using bitmap fonts

    i am a new user of j2me.but i cannot find any helps.
    i want to do english to bangla dictionary for all types of java mobile using bitmap
    fonts.
    initially how can i display bangla character using bitmap font in non unicode supported java mobile???
    but i cant do it.
    please send me source code or any helping resource.
    i am waiting for your reply.

    More info; installed mplayer2 which should work better with vdpau and this happened;
    VO: [vdpau] 800x468 => 800x468 Planar YV12
    [vdpau] Got display refresh rate 60.015 Hz.
    [vdpau] If that value looks wrong give the -vo vdpau:fps=X suboption manually.
    A: 6.3 V: 6.4 A-V: -0.000 ct: 0.000 0/ 0 1% 2% 0.2% 0 0
    [h264 @ 0xb6b41640]left block unavailable for requested intra mode at 0 23
    [h264 @ 0xb6b41640]error while decoding MB 0 23, bytestream (1111)
    [h264 @ 0xb6b41640]concealing 399 DC, 399 AC, 399 MV errors
    A: 6.5 V: 6.6 A-V: 0.000 ct: -0.000 0/ 0 1% 2% 0.2% 0 0
    Seek failed
    Seek failed
    Seek failed
    Seek failed
    Seek failed
    Seek failed
    Alot of those "Seek failed"!

  • How can I use two fonts in swing components?

    I want to implement a project. When a part of the JMenuBar, JButton or other swing components' text is English, I use Tahoma font, and other of these components' text is Chinese, I use SimSun font, just like the Chinese Windows OS. How can I implement it??
    Thanks!!

    Ooh, thats a tricky one. I'm not sure whether you can do that, but maybe someone else with more experienced can correct me.
    You'll probably have to create your own custom JMenu that displays two labels, one for English and one for the Chinese parts?

  • Some sites don't have symbols unless "allow pages to choose their own fonts" is checked

    With option "allow pages to choose their own fonts..." deselected, some symbols are improperly displayed.
    I think I know what's happening. With the option selected, FF displays some symbol characters with the wrong font.
    But, this doesn't make sense, since these symbols are not in any language font. None of them will produce the correct symbols if selected as the personal preferred font. So, it's incorrect to render these symbols in any of the fonts selected as my personal preference, regardless of status of this option.
    So, FF should use the a symbol font for these symbols regardless of this preference setting.

    You can accomplish what you want with a user style. Here are step-by-step directions. If you need any more help, just ask.
    # Leave "Allow pages to choose their own fonts" enabled.
    # Install Stylish.
    #* https://addons.mozilla.org/firefox/addon/stylish/
    # After Stylish is installed, open the Add-ons Manager, User Styles category.
    # Click the Write New Style button at the top.
    # In the style editor window, paste either of the following. Give the style a name and then click the Save button.
    <u>'''Variant #1'''</u><br>
    This is the easiest and safest thing to do. It applies your default sans-serif font to all sites, except those you specify. To specify exceptions, replace the placeholders with actual domain names. To add new exceptions, add another '''|''' symbol followed by the domain name.
    <pre><nowiki>@-moz-document regexp("https?://(?!(example-of-an-exception.com|www.placeholder.site-exception.net)).*") {
    * { font-family: sans-serif !important; }
    }</nowiki></pre>
    <u>'''Variant #2'''</u><br>
    This requires a bit of work on your part. You must know the font that's being used to display the symbols in question. Right-click a symbol and choose Inspect Element. In the Inspector pane, click the Fonts tab. You should see the font family names listed there, labeled with "remote". The actual font family name is below, under "Used as:".<br>
    You're going to want to specify your ideal font first, then the site's fonts after that. If certain characters can't be rendered with the font you want, then Firefox should fall back to the second font in the list, or the third, and so on. If none of the specified fonts contain the required characters, then Firefox will display the Unicode codepoints (rectangles with numbers in them).
    <pre><nowiki>@-moz-document url-prefix("http://"), url-prefix("https://") {
    * { font-family: Arial, "Segoe UI Symbol", FontAwesome, PlaceholderFontOne, "Placeholder Font Two", sans-serif !important; }
    }</nowiki></pre>
    ----

Maybe you are looking for