| Page 1 of 1 | [ 9 posts ] |
|
Hi, guys!
I'm using YUI Editor in my project and I have the following problem. Font name is stuck on "Arial" after using "Ctrl+A" for selecting all text inside the editor and changing font to any from list. In other words, here are the steps to reproduce it (in Firefox only): 1. Go, for example, here. 2. Press "Ctrl+A" to select all the text inside the editor. 3. Change font by selecting from the dropdown list. 4. Observe the result. Actual result: font changes, but label not. Expected result: both font and label changes. I'm sorry if there is a ticket for this defect I haven't found. Thanks for any help! |
|
This is a known issue, since you are selecting multiple elements Editor will default to the top of the list of fonts since it can't display the selection of several fonts at once.
|
|
Thanks, Dav!
But font jumps to "Arial" not only after "Ctrl+A", it does it after changing font to another. I mean, when all the editor's inside text font is, for example, "Verdana" (not several fonts), it still shows "Arial". Though, if select all the text by cursor dragging and change the font, then everything is fine. |
|
When there is more than one item in the selection, Editor bails on even looking at the fonts since it doesn't support showing multiple fonts. Selecting with the cursor is different, it goes by mouseup and sets the font to where the mouse was lifted.
|
|
Dave, is this issue fixed in YUI 3 Editor? If it's not, could you, please, give me any advice of how to fix it by myself, performing some changes in the editor code? Thanks!
Last edited by Halfist on Thu Aug 09, 2012 8:25 am, edited 1 time in total. |
|
There is no GUI to the 3.x Editor, so it's "sort of" fixed since you control the buttons and how they activate
I haven't looked at the 2.x Editor in more than 2 years. Off the top of my head I would say you could: * Listen for the `afterNodeChange` event * Determine what you want the menu to be set to * Set it |
|
davglass wrote: This is a known issue, since you are selecting multiple elements Editor will default to the top of the list of fonts since it can't display the selection of several fonts at once. Dav, but why in IE9 and Google Chrome it defaults not to the top of the list, but to the "Times New Roman"? I'd prefer it will default to empty string, like in MS Word in that cases, if it's possible. |
|
In FF after:
Code: family = Dom.getStyle(elm, 'font-family'); family comes to 'serif', when actual font is another. Dav, have you any ideas why is it so? |
|
Without looking at the code I can't tell you, but just so you know IE9 and Chrome did not exist when these components were written nor have they ever been tested on them. So they are pretty unpredictable in what they support or how they act.
|
| Page 1 of 1 | [ 9 posts ] |
| You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum |
© 2006-2013 Yahoo! Inc. All rights reserved.
All code on this site is licensed under the BSD License unless stated otherwise.
About This Site · Security Contact Info
Powered by phpBB® Forum Software © phpBB Group