Make WordPress Core

Opened 12 years ago

Closed 11 years ago

Last modified 11 years ago

#21197 closed defect (bug) (fixed)

There are two diffrent full screen editors

Reported by: janwoostendorp's profile janw.oostendorp Owned by: azaozz's profile azaozz
Milestone: 3.5 Priority: normal
Severity: normal Version: 3.4.1
Component: TinyMCE Keywords:
Focuses: Cc:

Description

In the WP editor there is a full screen button. It has shortcut ALT+SHIFT+G. When the button is pressed it shows a different full screen editor then when the shortcut is used.

I tried this on multiple 3.4.1 installations, one of them had no plugins to interfere.

I'm not sure if this is a bug, maybe it is intended.
If so can someone explain why?

Attachments (1)

21197.patch (1.1 KB) - added by SergeyBiryukov 11 years ago.

Download all attachments as: .zip

Change History (27)

#1 @helenyhou
12 years ago

Confirmed. Looks like alt+shift+g brings up the TinyMCE fullscreen editor instead of the WordPress fullscreen (distraction-free) editor - not sure what the right command is to bind to that key combo instead, if there is one, or else I'd try patching it :)

#2 @SergeyBiryukov
12 years ago

I think I've found a related bug:

  1. Press Alt + Shift + G.
  2. In the opened window, press "Toggle fullscreen mode" button. Nothing happens.
  3. Press Alt + Shift + G once again. The DFW editor shows up.
  4. "Exit fullscreen" link doesn't work. There's an error message in JS console:
Error: edd is undefined
Source File: wp-includes/js/tinymce/plugins/wpfullscreen/editor_plugin_src.js?ver=3541-21229
Line: 31
Last edited 12 years ago by SergeyBiryukov (previous) (diff)

#3 @janw.oostendorp
12 years ago

@Sergey I also saw that but first I wanted to make sure it was a bug

#4 @azaozz
12 years ago

Currently there are several problems with the shortcuts in the editors. One is that Firefox uses Alt + Shift + letter for the accesskey HTML attribute and it's no longer possible to overwrite/prevent that default. Another is that in the latest version TinyMCE has different/new API for handling key strokes (still working out few bugs there).

Thinking it would be best to redo all custom shortcuts we add in TinyMCE avoiding all browser limitations even if they would be different for different browsers (the shortcuts are already different for MacOS and Windows).

#6 @azaozz
12 years ago

  • Owner set to azaozz
  • Resolution set to fixed
  • Status changed from new to closed

In [21266]:

TinyMCE: update the keyboard shortcuts: Alt + letter for Firefox and WebKit, Alt + Shift + letter for IE and Opera, add shortcut for DFW (Alt + W), see #21214, fixes #21197, fixes #17992

#7 @azaozz
12 years ago

  • Component changed from Editor to TinyMCE
  • Milestone changed from Awaiting Review to 3.5

#8 @SergeyBiryukov
12 years ago

  • Resolution fixed deleted
  • Status changed from closed to reopened

comment:2 is still an issue.

Tested in Firefox 13, Chrome 20, IE 8, Opera 12. In Opera, a blank window with a scrollbar appears in step 3 instead of the DFW editor.

#9 @azaozz
12 years ago

  • Resolution set to fixed
  • Status changed from reopened to closed

In [21272]:

TinyMCE: add the Alt + W shortcut only when DFW is loaded and Alt + G only when MCE fullscreen is loaded, fixes #21197

#10 @azaozz
12 years ago

  • Resolution fixed deleted
  • Status changed from closed to reopened

In some languages Alt + letter is used regularly to type characters like ç (Alt+C), ł (Alt+l), ż (Alt+z), etc.

In that terms I'm not sure what shortcuts can be used for the editor buttons. Alt + Shift + letter works in Chrome, IE and Opera but doesn't work in Firefox (it triggers the "accesskey" attributes regardless of whether the element is visible or not).

The only key combination left is Ctrl + Alt + letter (Command + Option + letter on Mac), however that may run into keystroke conflicts too.

#11 @azaozz
12 years ago

For now thinking we should revert to Alt + Shift + letter for Chrome and use Ctrl + Alt + letter (Command + Option + letter) in Firefox for the custom editor shortcuts.

In the long term perhaps we can use the "Keyboard Shortcuts" checkbox in the user profile to turn on/off the shortcuts not only for moderating comments but also for the editor and any other place we may use them as well.

Edit: opened #21414 for that.

Last edited 12 years ago by azaozz (previous) (diff)

#12 @azaozz
12 years ago

In [21359]:

TinyMCE shortcuts: revert to Alt + Shift + letter for WebKit and Ctrl + Alt + letter (Command + Option + letter) in Firefox, see #21197

#13 @azaozz
12 years ago

  • Resolution set to fixed
  • Status changed from reopened to closed

In [21415]:

TinyMCE: revert Firefox shortcuts to match all other browsers (Alt+Shift+letter), fix the labels for the shortcuts, update description in wp-mce-help, fixes #21197

#14 @miqrogroove
12 years ago

#21933 was marked as a duplicate.

#15 follow-up: @SergeyBiryukov
11 years ago

  • Resolution fixed deleted
  • Status changed from closed to reopened

TinyMCE help still lists Alt + Shift + G shortcut for non-DFW fullscreen mode:
http://core.trac.wordpress.org/browser/trunk/wp-includes/js/tinymce/wp-mce-help.php?rev=21545#L216

However, unless 'wpfullscreen' plugin is manually disabled via tiny_mce_before_init filter, the shortcut is not registered (since [21272]).

Perhaps the shortcut should still work if 'wpfullscreen' is loaded but not active at the moment. Or should just be removed from help.

#16 in reply to: ↑ 15 @azaozz
11 years ago

Replying to SergeyBiryukov:

Think best would be to remove the TinyMCE's fullscreen from the default config. Opened #21976 for that.

#17 @miqrogroove
11 years ago

Something missing from the discussion so far is the "fullscreen" button in the HTML tab. That button opens DFW. So if a button is being removed from TinyMCE it might make sense to remove it in both places. Or were you fixing the existing button(s)?

#18 @navjotjsingh
11 years ago

  • Cc navjotjsingh@… added

#19 follow-up: @helenyhou
11 years ago

What's left to do here? I see #21976 for removing the TinyMCE fullscreen plugin. Anything else?

#20 in reply to: ↑ 19 @SergeyBiryukov
11 years ago

Replying to miqrogroove:

Something missing from the discussion so far is the "fullscreen" button in the HTML tab. That button opens DFW. So if a button is being removed from TinyMCE it might make sense to remove it in both places. Or were you fixing the existing button(s)?

The button on the Visual tab also opens DFW. What's being removed here is TinyMCE's fullscreen plugin (which has "Alt + Shift + G" shortcut), not the DFW button.

Replying to helenyhou:

What's left to do here?

21197.patch replaces TinyMCE's fullscreen shortcut in the help window with the one for DFW.

Last edited 11 years ago by SergeyBiryukov (previous) (diff)

#21 @miqrogroove
11 years ago

Is it possible to hook up Alt + Shift + G for DFW? That would make a lot more sense to me than removing it. That was how I found DFW in the first place, along with its many related keyboard shortcuts.

#22 @SergeyBiryukov
11 years ago

DFW has its own shortcut, Alt + Shift + W.

#23 @miqrogroove
11 years ago

Alt + Shift + W does not work, version 3.4.2. Is it a trunk only feature?

#24 @SergeyBiryukov
11 years ago

Yes, added as Alt + W in [21266], changed to Alt + Shift + W in [21415].

#25 @azaozz
11 years ago

  • Resolution set to fixed
  • Status changed from reopened to closed

This has been fixed by [21266] and [21415].

#26 @azaozz
11 years ago

In 22394:

Remove the Alt + Shift + G (old fullscreen mode) shortcut from the TinyMCE help popup, props SergeyBiryukov, see #21197

Note: See TracTickets for help on using tickets.