Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion Groups
General
GeneralPortable MacsHardwareNetworking
Applications
Mac ApplicationsEudoraFirefox / MozillaInternet ExplorerOutlook ExpressMS OfficeEntourageExcelPowerPointWordVirtual PCMedia PlayerOther MS Products
Programming
Mac ProgrammingCodeWarriorPerl
Country Specific
Australian Mac GroupUK Mac Group

Mac Forum / Programming / CodeWarrior / December 2004



Tip: Looking for answers? Try searching our database.

Text edit field with custom font

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Magnus Strand - 12 Dec 2004 12:40 GMT
Hi,

I have tried to make a text edit field with custom font with
PowerplantX but I have failed. I have used PPobToXML to generate
the .pobj file for my UI.

Is it possible with PowerplantX to do this?
Or can I use Carbon, Cocoa or Java?
I don't think I can use Java because I also need to
calculate string widths with different fonts.

Also I would like to know if I can enter special characters if I press control key
when entering characters on Mac OS X?

Regards,
Magnus Strand
MW Ron - 16 Dec 2004 21:29 GMT
>Hi,
>
[quoted text clipped - 10 lines]
>key
>when entering characters on Mac OS X?

Is this for something like PPx::EditUnicodeText?  You can setup a
ControlFontStyleRec structure and then tell the control to use that font
with something like:

   ControlFontStyleRec style = { 0 };
   style.flags |= kControlUseThemeFontIDMask;
   style.font = kThemeSmallEmphasizedSystemFont;
   
   editText->SetDataTag(kControlEntireControl,
       kControlEditTextStyleTag, sizeof(style), &style);

You can enter special characters, but normally not with the control key.  
You can hit Option-s for an esset (ß) and Option-d for a delta () and
so on.  Mac OS X has all sorts of ways to enter Unicode characters (some
apps have a Special Characters item in the Edit menu).

Ron  With lots of help

Signature

Metrowerks Community Forum is a free online resource for developers
to discuss CodeWarrior topics with other users and Metrowerks' staff
       --   http://www.metrowerks.com/community  --

Ron Liechty - MWRon@metrowerks.com - http://www.metrowerks.com

 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.