Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development


Thank you for visiting the BlackBerry Support Community Forums.

BlackBerry will be closing the BlackBerry Support Community Forums Device Forums on April 1st (Developers, see below)

BlackBerry remains committed to providing excellent customer support to our customers. We are delighted to direct you to the CrackBerry Forums, a well-established and thorough support channel, for continued BlackBerry support. Please visit http://forums.crackberry.com or http://crackberry.com/ask. You can also continue to visit BlackBerry Support or the BlackBerry Knowledge Base for official support options available for your BlackBerry Smartphone.

"When we launched CrackBerry.com 10 years ago, we set out to make it a fun and useful destination where BlackBerry Smartphone owners could share their excitement and learn to unleash the full potential of their BlackBerry. A decade later, the CrackBerry community is as active and passionate as ever and I know our knowledgeable members and volunteers will be excited to welcome and assist more BlackBerry owners with their questions."

- Kevin Michaluk, Founder, CrackBerry.com

Developers, for more information about the BlackBerry Developer Community please review Join the Conversation on the BlackBerry Developer Community Forums found on Inside BlackBerry.


Reply
Super Contributor
Posts: 440
Registered: ‎01-13-2011
My Device: Playbook
My Carrier: NA

Custom Fonts

Is it possible to use my own font with a label? I read that it was not possible before, but the posts are quite old, can it be done now?

--------------------------------------------------------------------------------------------------
BlackBerry Apps: Instruments | ARTPAD | Piano | Drums | Xylophone
Visitor
Posts: 1
Registered: ‎04-20-2011
My Device: Torch 9810, PlayBook
My Carrier: Movistar

Re: Custom Fonts

Hi Jeff. Did you finally get to change label font family at all? I dont' get it even with Arial or any other standard apart from default
Super Contributor
Posts: 440
Registered: ‎01-13-2011
My Device: Playbook
My Carrier: NA

Re: Custom Fonts

Nope, still waiting for a reply from someone who might know how to do it.

--------------------------------------------------------------------------------------------------
BlackBerry Apps: Instruments | ARTPAD | Piano | Drums | Xylophone
Developer
Posts: 1,068
Registered: ‎11-24-2011
My Device: PlayBook
My Carrier: x

Re: Custom Fonts

You are talking about Momentics, right? With Qt it is possible.

Developer
Posts: 19
Registered: ‎11-11-2012
My Device: Z10, DevAlphaC, Torch 9810, PlayBook
My Carrier: Movistar

Re: Custom Fonts

Right, we know how to do it, but the font won't show changed on dev alpha or bb10 simulator... nor in the qml view of the momentics IDE
Super Contributor
Posts: 440
Registered: ‎01-13-2011
My Device: Playbook
My Carrier: NA

Re: Custom Fonts

Could you post your code? Thanks!
--------------------------------------------------------------------------------------------------
BlackBerry Apps: Instruments | ARTPAD | Piano | Drums | Xylophone
Developer
Posts: 19
Registered: ‎11-11-2012
My Device: Z10, DevAlphaC, Torch 9810, PlayBook
My Carrier: Movistar

Re: Custom Fonts

Sure!

// Default empty project template
import bb.cascades 1.0
import bbornot2b.lib 1.0

// creates one page with a label
Page {
Container {
layout: DockLayout {
}
ImageView {
imageSource: "asset:///images/background_portrait.png"
}
ImageView {
imageSource: "asset:///images/message-box.png"
}
Label {
id: message
objectName: "app_message"
text: "Slide to unlock"
textStyle.fontFamily: "Arial"
textStyle.textAlign: TextAlign.Center
textStyle.color: Color.White
translationY: 60
preferredWidth: 768.0
preferredHeight: 230.0
textStyle.fontSizeValue: 15.0
}
...
Super Contributor
Posts: 440
Registered: ‎01-13-2011
My Device: Playbook
My Carrier: NA

Re: Custom Fonts

Does anyone know how to load in custom fonts yet?

--------------------------------------------------------------------------------------------------
BlackBerry Apps: Instruments | ARTPAD | Piano | Drums | Xylophone
Developer
Posts: 19
Registered: ‎11-11-2012
My Device: Z10, DevAlphaC, Torch 9810, PlayBook
My Carrier: Movistar

Re: Custom Fonts

Not yet... any comment about the code I posted? Thanks, Diego
Highlighted
Super Contributor
Posts: 440
Registered: ‎01-13-2011
My Device: Playbook
My Carrier: NA

Re: Custom Fonts

[ Edited ]

Yoru code doesnt mention anything about loading in a customer font, it just says arial

 

Thanks anyway

--------------------------------------------------------------------------------------------------
BlackBerry Apps: Instruments | ARTPAD | Piano | Drums | Xylophone