How do i use a custom font and how do i remove the top bar in fullscreen?

i want to make a project where i can print out text with a custom font without having to have millions of costumes all alligned correctly. is there like a google fonts api link or something like that?

how do i remove the top bar in fullscreen?

To use a custom font, you can use this:

You can't remove the top bar in fullscreen without js

Well, that's interesting! I never thought of using the join block to add attributes to the text. I learned a few things today, and this one was genius.

But how do I include a font from a "data:" or font file link? Will that reqiure JavaScript?

Interesting indeed!

Now here’s another useful yet undocumented Snap! feature … can anyone (@bh perhaps) share:

  • A list of available fonts (and if any of those are platform-specific?)
    (so far, apart from the default courier / monaco, I found: arial, avenir, georgia, helvetica, impact, palatino, verdana, and a generic alternative font that looks like times roman - e.g. @ten_6044’s “montserrat” triggers this one, even though it doesn’t look like montserrat, at least on my iOS device)
  • Any other relevant options (bold? italic? strikethrough? subscript? blink? upside down? :smirk:);
  • Any in-text lay-out options (?).

BTW you may have noticed the layout of this post’s header. I stumbled upon this option, ironically, while composing this post. It was triggered by me starting the line below the text with a hyphen (“-“).

yeah how to get fonts from google fonts

i made this
it uses the arial font

:scream:
I didn't know this was a thing in Snap!

If you were to add any styling,there's only bold and italic. This works because of the way the ctx.font parameter allows styling. From the MDN documentation on this:

The CanvasRenderingContext2D.font property of the Canvas 2D API specifies the current text style to use when drawing text. This string uses the same syntax as the CSS font specifier.

This also means that you can use system/browser defaults, like "serif", "sans-serif", and "monospace".

You can get these options by adding these 2 before the normal ones.
[scratchblocks]
join [bold ] [italic ] (textSize) [px ] (fontName) @delInput@addInput :: reporter operators
[/scratchblocks]
You can delete one of those slots if you only want normal formatting.

From what I know, I think that Snap!Forum uses system fonts, so there probably isn't any chance that there are any platform-specific fonts.

Blinking? Impossible. Text wrote on the pen trails stay static, as they are technically costumes. They cannot move or animate by itself without programming for them to do so.

The upside down, can be simply done by turning the sprite 180° degrees (or precisely, 270° if the text would be upright without the upside down).

strikethrought and subscript can easily achieved by your self

blink: you make me smile...

Oh, I read this after reading that...

This is actually exactly what inspired me to make that block!

See also this parallel (and somewhat more extensive) discussion topic.

My proposal is to leave this topic alone - any further discussion may be conducted within the other one.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.