-
Notifications
You must be signed in to change notification settings - Fork 14
Font size change is not permanent #2
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
Comments
Greetings, |
Same here, using Moodle 20140908. |
Hi all, Sorry about the delay. I was away and then forgot to comment on this issue. Thanks for bringing it to my attention. This is actually (and frustratingly) an issue with Atto. It's currently removing the font tag entirely. I'm going to chat to Damyon about the best approach here and then I'll update things. Andrew |
Andrew, I think if you changed moodle-atto_fontsize-button.js#L66 to the following: text: '<span style="'font-size: + size.name + ;'">' + size.name + '</span>' Unfortunately I'm not sure off-hand if a span is a semantically appropriate replacement. Notice the dual use of 'size.name' as CSS uses the name value, not the integer value. |
As stated in #4 (comment), this part of the code only affects the drop-down menu itself (at button.js#L76), whereas the actual command sent to the editor is button.js#L89. |
Like I said, untested 😛 Unfortunately it looks like the support for this across different browsers is pretty lousy: for example this http://codepen.io/thedannywahl/pen/KjnFv?editors=101 tl;dr- I would call this a browser problem, not a plugin problem or a moodle problem. that said my suggestion is 1) to make sure useCSS() and styleWithCSS() are set for browsers that support it |
as always with Moodle there's a method for that: enableCssStyling, example |
Switch to formatSelectionInlineStyle rather than 'fontsize' command. Note that the sizes are smaller than in the original font-tag based approach, but CSS font-sizes don't go up to xxx-large.
Hi Andrew,
I just installed the plugin font size in Moodle 2.7+ (Build: 20140703). In the text editor I can't see any change in the code when I toggle to plain text in Google Chrome. Same result in Mozilla Firefox. There is a change of the font size, but it doesn't "stick" or it's not applied properly, meaning I can see the change in the text editor before I toggle to plain text or save the text.
With kind regards,
Hartmut
The text was updated successfully, but these errors were encountered: