Reputation: 25
I'm trying to develop a simple clock program for a Windows CE 5.0 device in my car, using Visual Studio 2008 professional and C#. I had to use .NET 2.0 since 3.5 doesn't work. The clock program was made as a Form application. It consists of a simple label and a timer, that's it. The clock program works on the device, but I only get a standard font and font-size, no matter what font and size I choose in the label properties in Visual Studio. On my computer the program works fine with several fonts and large font sizes. I can not add anything in the Windows/Font directory on my device since it will be erased after every shut down. It is clear the windows CE version is a totally simplified version with nearly no functions. I guess I have to add the font size in a different way in the program file. How can I do this?
Upvotes: 1
Views: 732
Reputation: 2210
You can call AddFontResource during your application startup to add additional fonts to the system ones: https://msdn.microsoft.com/en-us/library/ee489896(v=winembedded.60).aspx You can use pinvoke.net (http://www.pinvoke.net/) to find the right declaration to use to import this API in your managed code application.
Upvotes: 1