Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

How can I add rich text to a field?

A topic by eoin2 created Feb 26, 2023 Views: 477 Replies: 2
Viewing posts 1 to 3
(1 edit) (+1)

I'd like to add hyperlinks, bolding and italics to text in a field. I've set it to rich text, but cannot figure out how to format the text and add the link. I also cannot figure out how it was done in the Decker guided tour deck's "Fields" card.

Developer(+1)

With the "Interact" tool selected, click in a field, and you will be given a "Text" menu with options for adding links or changing the font of selections:

For a hyperlink to be "clickable", you'll need to "lock" the field once you're finished editing it, as shown above.

If the "link string" you provide begins with "http://" or "https://", Decker will try to open a new browser tab at the provided URL. If the link string is the name of a card within the current deck, it will instead take you directly to that card. Both of these behaviors can be overridden with scripts if needed.

If you copy images (via the Select or Lasso tools) to the clipboard, it is possible to paste them into rich text fields using the Interact tool: this is a handy way to add custom bullet points or fancy headers to rich text fields.

All the text styles are in Decker are individual bitmapped fonts, and unfortunately Decker does not include an italic font built-in. There is a collection of additional fonts available that might do what you want, and the "fontedit.deck" example provides a very basic font editor for creating new ones. The Decker community is still very small, but I hope that over time users will help furnish more options.

(+1)

thanks for your swift reply! 

I may need to override the hyperlink-clicking action for mailto: links. Will let you know how I get on. 

Thanks so much for this great tool!