Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fonts cannot be scaled #278

Open
avidrucker opened this issue Sep 23, 2023 · 1 comment
Open

Fonts cannot be scaled #278

avidrucker opened this issue Sep 23, 2023 · 1 comment

Comments

@avidrucker
Copy link
Contributor

Issue:

Attempting to scale text results in the error message "Can't scale non-shape: #shapes.core.Shape..." being displayed. A more helpful error message would be useful here such as, "You can't scale fonts in Maria just yet." I was hoping there was a way to create horizontally flipped text.

Interesting side note, I realized that we can manipulate font size in Maria like so: (assoc (text "hello") :font-size 30)

Environment:

  • Browser: Chrome
  • Platform (Mac/Windows/Linux): Linux

URL to a gist replicating the issue (if possible/relevant)

https://www.maria.cloud/gist/b5fa4caaa90ccf9e00da100dc91ad188

@daveliepmann
Copy link
Collaborator

Hmm, maybe something like

(-> (text "hello")
    (update :font-size (partial * 2))
    (update :y (partial * 2))
    (update :width (partial * 2)))

added to shapes.core/scale could do the trick

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants