Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

How to style/skin Canvas Components ?

Guru ,
Jan 16, 2017 Jan 16, 2017

Couldn´t find any source how to style/skin the new canvas components.

New features summary for the 2017 release of Animate CC

The provided code snippets are not very helpful.

Could anyone point me in the right direction?

I´m especially interested in setting fonts, colors for the input box component and the button component.

1.8K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Community Expert , Feb 21, 2018 Feb 21, 2018

after posting i saw how to use that.  you can use the instance name of the component instance and style with an id (#) and you can change the components class name and style the class (.)

but there are some significant limitations.  eg, i can't see any way to make a textinput multiline.

Translate
Adobe Employee ,
Jan 16, 2017 Jan 16, 2017

Not the exact answer, but all possibilities for HTML5 canvas in Adobe Animate are documented in this article.

Create HTML5 Canvas documents in Animate CC

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 20, 2018 Feb 20, 2018

did you ever find a way to do that?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 21, 2018 Feb 21, 2018

You should be able to use the CSS Component to point to a .css file which provides all style information for skinning HTML5 Canvas components. Is this what you mean?

Refer to the class names of various components in your custom CSS:

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 21, 2018 Feb 21, 2018

after posting i saw how to use that.  you can use the instance name of the component instance and style with an id (#) and you can change the components class name and style the class (.)

but there are some significant limitations.  eg, i can't see any way to make a textinput multiline.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Feb 21, 2018 Feb 21, 2018

kglad  wrote

but there are some significant limitations.  eg, i can't see any way to make a textinput multiline.

Yes, because the textinput component is just a wrapper around an HTML input element, which does not support multiline input, full stop.

For multiline input you use a textarea element. So, you can roll your own overlay, or wait for Adobe to add a textarea component.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 21, 2018 Feb 21, 2018
LATEST

it was such a mess (trying to work around the animate limitations), i decided to just use a html form and location.href to go back and forth between the animate created website and the 'page' with the form rather than integrate the two.

edit: i changed that href stuff to hiding and showing the canvas div and showing and hiding a div containing my form.  that avoids reloading.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines