Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Developing U++ » UppHub » FontSel dialog
FontSel dialog [message #12790] Fri, 16 November 2007 12:40 Go to next message
cbpporter is currently offline  cbpporter
Messages: 1401
Registered: September 2007
Ultimate Contributor
I found that I need a font dialog in lot of different instances and I couldn't find one in U++. So I decide to create one. I tried to make it look and behave like a standard Windows font dialog so that it would seem native and familiar. It doesn't have a Linux look, but Linux users are not se "dependent" on constant user interface. I also removed the encoding option from the dialog, considering that this is more related to the application/control than and actual font.

Here is my result:

index.php?t=getfile&id=851&private=0


But before I release, there are some issues to iron out.

1. GetFontFaceName returns the name of a font, but under windows it seems that fonts also have some magical "caption" property besides name. This is why, as you can see in the screenshot, I have multiple arial fonts. Their name is "arial", but their other textual descriptor is "Arial", "Arial Bold", "Arial Bold Italic" and so on. It would be great if U++ had methods to obtain these descriptors also. I would like to avoid system dependent code.

2. How do you Sort a ColumnList. I know about the Sort method, but I just can't seem to use it correctly. An example would help. I read something about new sorting methods, but they are not in 11 Dev (AFAIK).

3. The "standard font's" name is STDFONT. How can I obtain the real name of that font?

4. I added I18n, this is why you may not recognize the captions in the screenshot. But when I edit the .t file and I switch to my native language's keyboard layout, some of the special keys do not insert the right character. This works in all other windows apps.

5. The last issue is related to chameleon. LineEdit borders don't seem to be chameleonized.
  • Attachment: FontSel.png
    (Size: 23.94KB, Downloaded 522 times)

[Updated on: Mon, 19 November 2007 12:24]

Report message to a moderator

Re: FontSel dialog [message #12805 is a reply to message #12790] Sun, 18 November 2007 16:33 Go to previous messageGo to next message
cbpporter is currently offline  cbpporter
Messages: 1401
Registered: September 2007
Ultimate Contributor
I've done some tests on different computers and it seems number 4 is only Vista related. And also issue 5 is not related to Chameleon, it is only the frame style that is selected by default.

[Updated on: Sun, 18 November 2007 20:54]

Report message to a moderator

Re: FontSel dialog [message #12808 is a reply to message #12805] Sun, 18 November 2007 21:10 Go to previous messageGo to next message
cbpporter is currently offline  cbpporter
Messages: 1401
Registered: September 2007
Ultimate Contributor
I attached the sources. There are structured as a CtrlEx package which serves as a base for third party components. There are still some issues with the font names, but it is quite usable. I'll start using it in my apps and if I find ways to improve it, I will update.

Edit: Added font list sorting and some Russian i18n.
Edit: Download moved to other posts.

[Updated on: Mon, 19 November 2007 12:25]

Report message to a moderator

Re: FontSel dialog [message #12819 is a reply to message #12790] Mon, 19 November 2007 12:28 Go to previous message
cbpporter is currently offline  cbpporter
Messages: 1401
Registered: September 2007
Ultimate Contributor
I finished the final version of the FontSel dialog. Everything works fine, tested under Vista and XP too. Also Vista Chameleon issues are no longer present with 11 Dev 2.

  • Attachment: CtrlEx.rar
    (Size: 2.93KB, Downloaded 319 times)
Previous Topic: Stable Marriage Algorithm: interactive algorithm
Next Topic: Anonymous delegates
Goto Forum:
  


Current Time: Thu Mar 28 21:14:34 CET 2024

Total time taken to generate the page: 0.01724 seconds