TinyMCE strings: Merge, remove, reorganize, restore, clarify.
see #27453, #24067. Built from https://develop.svn.wordpress.org/trunk@27618 git-svn-id: http://core.svn.wordpress.org/trunk@27461 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
0f55595472
commit
de8f6c7350
|
@ -517,77 +517,80 @@ final class _WP_Editors {
|
||||||
|
|
||||||
$mce_translation = array(
|
$mce_translation = array(
|
||||||
// Default TinyMCE strings
|
// Default TinyMCE strings
|
||||||
'Cut' => __('Cut'),
|
'New document' => __( 'New document' ),
|
||||||
'Header 2' => __('Header 2'),
|
'Formats' => _x( 'Formats', 'TinyMCE' ),
|
||||||
'Your browser doesn\'t support direct access to the clipboard. Please use the Ctrl+X/C/V keyboard shortcuts instead.' => __('Your browser does not support direct access to the clipboard. Please use the Ctrl+X/C/V keyboard shortcuts instead.'),
|
'Headers' => _x( 'Headers', 'TinyMCE' ),
|
||||||
'Div' => __('Div'),
|
'Header 1' => __( 'Heading 1' ),
|
||||||
'Paste' => __('Paste'),
|
'Header 2' => __( 'Heading 2' ),
|
||||||
'Close' => __('Close'),
|
'Header 3' => __( 'Heading 3' ),
|
||||||
'Pre' => __('Pre'),
|
'Header 4' => __( 'Heading 4' ),
|
||||||
'Align right' => __('Align right'),
|
'Header 5' => __( 'Heading 5' ),
|
||||||
'New document' => __('New document'),
|
'Header 6' => __( 'Heading 6' ),
|
||||||
'Blockquote' => __('Blockquote'),
|
|
||||||
'Numbered list' => __('Numbered list'),
|
/* translators: block tags */
|
||||||
'Increase indent' => __('Increase indent'),
|
'Blocks' => _x( 'Blocks', 'TinyMCE' ),
|
||||||
'Formats' => __('Formats'),
|
'Paragraph' => __( 'Paragraph' ),
|
||||||
'Headers' => __('Headers'),
|
'Blockquote' => __( 'Blockquote' ),
|
||||||
'Select all' => __('Select all'),
|
'Div' => _x( 'Div', 'HTML tag' ),
|
||||||
'Header 3' => __('Header 3'),
|
'Pre' => _x( 'Pre', 'HTML tag' ),
|
||||||
'Blocks' => __('Blocks'),
|
|
||||||
'Undo' => __('Undo'),
|
'Inline' => _x( 'Inline', 'HTML elements' ),
|
||||||
'Strikethrough' => __('Strikethrough'),
|
'Underline' => __( 'Underline' ),
|
||||||
'Bullet list' => __('Bullet list'),
|
'Strikethrough' => __( 'Strikethrough' ),
|
||||||
'Header 1' => __('Header 1'),
|
'Subscript' => __( 'Subscript' ),
|
||||||
'Superscript' => __('Superscript'),
|
'Superscript' => __( 'Superscript' ),
|
||||||
'Clear formatting' => __('Clear formatting'),
|
'Clear formatting' => __( 'Clear formatting' ),
|
||||||
'Subscript' => __('Subscript'),
|
|
||||||
'Header 6' => __('Header 6'),
|
|
||||||
'Redo' => __('Redo'),
|
|
||||||
'Paragraph' => __('Paragraph'),
|
|
||||||
'Ok' => __('Ok'),
|
|
||||||
'Bold' => __('Bold'),
|
'Bold' => __('Bold'),
|
||||||
'Code' => __('Code'),
|
|
||||||
'Italic' => __('Italic'),
|
'Italic' => __('Italic'),
|
||||||
|
'Code' => _x( 'Code', 'editor button' ),
|
||||||
|
'Source code' => __( 'Source code' ),
|
||||||
|
|
||||||
'Align center' => __('Align center'),
|
'Align center' => __('Align center'),
|
||||||
'Header 5' => __('Header 5'),
|
'Align right' => __('Align right'),
|
||||||
'Decrease indent' => __('Decrease indent'),
|
'Align left' => __( 'Align left' ),
|
||||||
'Header 4' => __('Header 4'),
|
|
||||||
'Paste is now in plain text mode. Contents will now be pasted as plain text until you toggle this option off.' => __('Paste is now in plain text mode. Contents will now be pasted as plain text until you toggle this option off.'),
|
|
||||||
'Underline' => __('Underline'),
|
|
||||||
'Cancel' => __('Cancel'),
|
|
||||||
'Justify' => __('Justify'),
|
'Justify' => __('Justify'),
|
||||||
'Inline' => __('Inline'),
|
'Increase indent' => __('Increase indent'),
|
||||||
'Copy' => __('Copy'),
|
'Decrease indent' => __('Decrease indent'),
|
||||||
'Align left' => __('Align left'),
|
|
||||||
'Visual aids' => __('Visual aids'),
|
'Cut' => __( 'Cut' ),
|
||||||
'Lower Greek' => __('Lower Greek'),
|
'Copy' => __( 'Copy' ),
|
||||||
'Square' => __('Square'),
|
'Paste' => __( 'Paste' ),
|
||||||
'Default' => __('Default'),
|
'Select all' => __( 'Select all' ),
|
||||||
'Lower Alpha' => __('Lower Alpha'),
|
'Undo' => __( 'Undo' ),
|
||||||
'Circle' => __('Circle'),
|
'Redo' => __( 'Redo' ),
|
||||||
'Disc' => __('Disc'),
|
|
||||||
'Upper Alpha' => __('Upper Alpha'),
|
'Ok' => __( 'OK' ),
|
||||||
'Upper Roman' => __('Upper Roman'),
|
'Cancel' => __( 'Cancel' ),
|
||||||
'Lower Roman' => __('Lower Roman'),
|
'Close' => __( 'Close' ),
|
||||||
'Name' => __('Name'),
|
'Visual aids' => __( 'Visual aids' ),
|
||||||
'Anchor' => __('Anchor'),
|
|
||||||
'You have unsaved changes are you sure you want to navigate away?' => __('You have unsaved changes are you sure you want to navigate away?'),
|
'Bullet list' => __( 'Bulleted list' ),
|
||||||
'Restore last draft' => __('Restore last draft'),
|
'Numbered list' => __('Numbered list'),
|
||||||
'Special character' => __('Special character'),
|
'Square' => _x( 'Square', 'list style' ),
|
||||||
'Source code' => __('Source code'),
|
'Default' => _x( 'Default', 'list style' ),
|
||||||
'Right to left' => __('Right to left'),
|
'Circle' => _x( 'Circle', 'list style' ),
|
||||||
'Left to right' => __('Left to right'),
|
'Disc' => _x('Disc', 'list style' ),
|
||||||
'Emoticons' => __('Emoticons'),
|
'Lower Greek' => _x( 'Lower Greek', 'list style' ),
|
||||||
'Robots' => __('Robots'),
|
'Lower Alpha' => _x( 'Lower Alpha', 'list style' ),
|
||||||
'Document properties' => __('Document properties'),
|
'Upper Alpha' => _x( 'Upper Alpha', 'list style' ),
|
||||||
'Title' => __('Title'),
|
'Upper Roman' => _x( 'Upper Roman', 'list style' ),
|
||||||
'Keywords' => __('Keywords'),
|
'Lower Roman' => _x( 'Lower Roman', 'list style' ),
|
||||||
'Encoding' => __('Encoding'),
|
|
||||||
'Description' => __('Description'),
|
// Anchor plugin
|
||||||
'Author' => __('Author'),
|
'Name' => _x( 'Name', 'Name of link anchor (TinyMCE)' ),
|
||||||
'Fullscreen' => __('Fullscreen'),
|
'Anchor' => _x( 'Anchor', 'Link anchor (TinyMCE)' ),
|
||||||
'Horizontal line' => __('Horizontal line'),
|
'Anchors' => _x( 'Anchors', 'Link anchors (TinyMCE)' ),
|
||||||
'Horizontal space' => __('Horizontal space'),
|
|
||||||
|
// Fullpage plugin
|
||||||
|
'Document properties' => __( 'Document properties' ),
|
||||||
|
'Robots' => __( 'Robots' ),
|
||||||
|
'Title' => __( 'Title' ),
|
||||||
|
'Keywords' => __( 'Keywords' ),
|
||||||
|
'Encoding' => __( 'Encoding' ),
|
||||||
|
'Description' => __( 'Description' ),
|
||||||
|
'Author' => __( 'Author' ),
|
||||||
|
|
||||||
|
// Media, image plugins
|
||||||
'Insert/edit image' => __('Insert/edit image'),
|
'Insert/edit image' => __('Insert/edit image'),
|
||||||
'General' => __('General'),
|
'General' => __('General'),
|
||||||
'Advanced' => __('Advanced'),
|
'Advanced' => __('Advanced'),
|
||||||
|
@ -600,96 +603,115 @@ final class _WP_Editors {
|
||||||
'Dimensions' => __('Dimensions'),
|
'Dimensions' => __('Dimensions'),
|
||||||
'Insert image' => __('Insert image'),
|
'Insert image' => __('Insert image'),
|
||||||
'Insert date/time' => __('Insert date/time'),
|
'Insert date/time' => __('Insert date/time'),
|
||||||
'Remove link' => __('Remove link'),
|
|
||||||
'Url' => __('Url'),
|
|
||||||
'Text to display' => __('Text to display'),
|
|
||||||
'Anchors' => __('Anchors'),
|
|
||||||
'Insert link' => __('Insert link'),
|
|
||||||
'New window' => __('New window'),
|
|
||||||
'None' => __('None'),
|
|
||||||
'Target' => __('Target'),
|
|
||||||
'Insert/edit link' => __('Insert/edit link'),
|
|
||||||
'Insert/edit video' => __('Insert/edit video'),
|
'Insert/edit video' => __('Insert/edit video'),
|
||||||
'Poster' => __('Poster'),
|
'Poster' => __('Poster'),
|
||||||
'Alternative source' => __('Alternative source'),
|
'Alternative source' => __('Alternative source'),
|
||||||
'Paste your embed code below:' => __('Paste your embed code below:'),
|
'Paste your embed code below:' => __('Paste your embed code below:'),
|
||||||
'Insert video' => __('Insert video'),
|
'Insert video' => __('Insert video'),
|
||||||
'Embed' => __('Embed'),
|
'Embed' => __('Embed'),
|
||||||
'Nonbreaking space' => __('Nonbreaking space'),
|
|
||||||
'Page break' => __('Page break'),
|
// Each of these have a corresponding plugin
|
||||||
'Paste as text' => __('Paste as text'),
|
'Special character' => __( 'Special character' ),
|
||||||
'Preview' => __('Preview'),
|
'Right to left' => _x( 'Right to left', 'editor button' ),
|
||||||
'Print' => __('Print'),
|
'Left to right' => _x( 'Left to right', 'editor button' ),
|
||||||
'Save' => __('Save'),
|
'Emoticons' => __( 'Emoticons' ),
|
||||||
'Could not find the specified string.' => __('Could not find the specified string.'),
|
'Nonbreaking space' => __( 'Nonbreaking space' ),
|
||||||
'Replace' => __('Replace'),
|
'Page break' => __( 'Page break' ),
|
||||||
'Next' => __('Next'),
|
'Paste as text' => __( 'Paste as text' ),
|
||||||
'Whole words' => __('Whole words'),
|
'Preview' => __( 'Preview' ),
|
||||||
'Find and replace' => __('Find and replace'),
|
'Print' => __( 'Print' ),
|
||||||
'Replace with' => __('Replace with'),
|
'Save' => __( 'Save' ),
|
||||||
'Find' => __('Find'),
|
'Fullscreen' => __( 'Fullscreen' ),
|
||||||
'Replace all' => __('Replace all'),
|
'Horizontal line' => __( 'Horizontal line' ),
|
||||||
|
'Horizontal space' => __( 'Horizontal space' ),
|
||||||
|
'Restore last draft' => __( 'Restore last draft' ),
|
||||||
|
|
||||||
|
// Spelling, search/replace plugins
|
||||||
|
'Could not find the specified string.' => __( 'Could not find the specified string.' ),
|
||||||
|
'Replace' => _x( 'Replace', 'find/replace' ),
|
||||||
|
'Next' => _x( 'Next', 'find/replace' ),
|
||||||
|
/* translators: previous */
|
||||||
|
'Prev' => _x( 'Prev', 'find/replace' ),
|
||||||
|
'Whole words' => _x( 'Whole words', 'find/replace' ),
|
||||||
|
'Find and replace' => __('Find and replace' ),
|
||||||
|
'Replace with' => _x('Replace with', 'find/replace' ),
|
||||||
|
'Find' => _x( 'Find', 'find/replace' ),
|
||||||
|
'Replace all' => _x( 'Replace all', 'find/replace' ),
|
||||||
'Match case' => __('Match case'),
|
'Match case' => __('Match case'),
|
||||||
'Prev' => __('Prev'),
|
'Spellcheck' => __( 'Check Spelling' ),
|
||||||
'Spellcheck' => __('Spellcheck'),
|
'Finish' => _x( 'Finish', 'spellcheck' ),
|
||||||
'Finish' => __('Finish'),
|
'Ignore all' => _x( 'Ignore all', 'spellcheck' ),
|
||||||
'Ignore all' => __('Ignore all'),
|
'Ignore' => _x( 'Ignore', 'spellcheck' ),
|
||||||
'Ignore' => __('Ignore'),
|
|
||||||
'Insert row before' => __('Insert row before'),
|
// TinyMCE tables
|
||||||
'Rows' => __('Rows'),
|
'Insert table' => __( 'Insert table' ),
|
||||||
'Height' => __('Height'),
|
'Delete table' => __( 'Delete table' ),
|
||||||
'Paste row after' => __('Paste row after'),
|
'Table properties' => __( 'Table properties' ),
|
||||||
'Alignment' => __('Alignment'),
|
'Row properties' => __( 'Table row properties' ),
|
||||||
'Column group' => __('Column group'),
|
'Cell properties' => __( 'Table cell properties' ),
|
||||||
'Row' => __('Row'),
|
|
||||||
'Insert column before' => __('Insert column before'),
|
'Row' => __( 'Row' ),
|
||||||
'Split cell' => __('Split cell'),
|
'Rows' => __( 'Rows' ),
|
||||||
'Cell padding' => __('Cell padding'),
|
'Column' => _x( 'Column', 'table column' ),
|
||||||
'Cell spacing' => __('Cell spacing'),
|
'Cols' => _x( 'Cols', 'table columns' ),
|
||||||
'Row type' => __('Row type'),
|
'Cell' => _x( 'Cell', 'table cell' ),
|
||||||
'Insert table' => __('Insert table'),
|
'Header cell' => __( 'Header cell' ),
|
||||||
'Body' => __('Body'),
|
'Header' => _x( 'Header', 'table header' ),
|
||||||
'Caption' => __('Caption'),
|
'Body' => _x( 'Body', 'table body' ),
|
||||||
'Footer' => __('Footer'),
|
'Footer' => _x( 'Footer', 'table footer' ),
|
||||||
'Delete row' => __('Delete row'),
|
|
||||||
'Paste row before' => __('Paste row before'),
|
'Insert row before' => __( 'Insert row before' ),
|
||||||
'Scope' => __('Scope'),
|
|
||||||
'Delete table' => __('Delete table'),
|
|
||||||
'Header cell' => __('Header cell'),
|
|
||||||
'Column' => __('Column'),
|
|
||||||
'Cell' => __('Cell'),
|
|
||||||
'Header' => __('Header'),
|
|
||||||
'Cell type' => __('Cell type'),
|
|
||||||
'Copy row' => __('Copy row'),
|
|
||||||
'Row properties' => __('Row properties'),
|
|
||||||
'Table properties' => __('Table properties'),
|
|
||||||
'Row group' => __('Row group'),
|
|
||||||
'Right' => __('Right'),
|
|
||||||
'Insert column after' => __('Insert column after'),
|
|
||||||
'Cols' => __('Cols'),
|
|
||||||
'Insert row after' => __('Insert row after'),
|
'Insert row after' => __('Insert row after'),
|
||||||
'Width' => __('Width'),
|
'Insert column before' => __( 'Insert column before' ),
|
||||||
'Cell properties' => __('Cell properties'),
|
'Insert column after' => __( 'Insert column after' ),
|
||||||
'Left' => __('Left'),
|
'Paste row before' => __( 'Paste table row before' ),
|
||||||
'Cut row' => __('Cut row'),
|
'Paste row after' => __( 'Paste table row after' ),
|
||||||
|
'Delete row' => __( 'Delete row' ),
|
||||||
'Delete column' => __('Delete column'),
|
'Delete column' => __('Delete column'),
|
||||||
'Center' => __('Center'),
|
'Cut row' => __('Cut table row' ),
|
||||||
'Merge cells' => __('Merge cells'),
|
'Copy row' => __( 'Copy table row' ),
|
||||||
'Insert template' => __('Insert template'),
|
'Merge cells' => __( 'Merge table cells' ),
|
||||||
'Templates' => __('Templates'),
|
'Split cell' => __( 'Split merged table cells' ),
|
||||||
'Background color' => __('Background color'),
|
|
||||||
'Text color' => __('Text color'),
|
'Height' => __( 'Height' ),
|
||||||
'Show blocks' => __('Show blocks'),
|
'Width' => __('Width'),
|
||||||
'Show invisible characters' => __('Show invisible characters'),
|
'Caption' => __( 'Caption' ),
|
||||||
'Words: {0}' => __('Words: {0}'),
|
'Alignment' => __( 'Alignment' ),
|
||||||
'Insert' => __('Insert'),
|
'Left' => __( 'Left' ),
|
||||||
'File' => __('File'),
|
'Center' => __( 'Center' ),
|
||||||
'Edit' => __('Edit'),
|
'Right' => __( 'Right' ),
|
||||||
|
|
||||||
|
'Row group' => __( 'Row group' ),
|
||||||
|
'Column group' => __( 'Column group' ),
|
||||||
|
'Row type' => __( 'Row type' ),
|
||||||
|
'Cell type' => __( 'Cell type' ),
|
||||||
|
'Cell padding' => __( 'Cell padding' ),
|
||||||
|
'Cell spacing' => __( 'Cell spacing' ),
|
||||||
|
'Scope' => _x( 'Scope', 'table cell scope attribute' ),
|
||||||
|
|
||||||
|
'Insert template' => _x( 'Insert template', 'TinyMCE' ),
|
||||||
|
'Templates' => _x( 'Templates', 'TinyMCE' ),
|
||||||
|
|
||||||
|
'Background color' => __( 'Background color' ),
|
||||||
|
'Text color' => __( 'Text color' ),
|
||||||
|
'Show blocks' => _x( 'Show blocks', 'editor button' ),
|
||||||
|
'Show invisible characters' => __( 'Show invisible characters' ),
|
||||||
|
|
||||||
|
/* translators: word count */
|
||||||
|
'Words: {0}' => sprintf( __( 'Words: %s' ), '{0}' ),
|
||||||
|
'Paste is now in plain text mode. Contents will now be pasted as plain text until you toggle this option off.' => __('Paste is now in plain text mode. Contents will now be pasted as plain text until you toggle this option off.'),
|
||||||
'Rich Text Area. Press ALT-F9 for menu. Press ALT-F10 for toolbar. Press ALT-0 for help' => __('Rich Text Area. Press ALT-F9 for menu. Press ALT-F10 for toolbar. Press ALT-0 for help'),
|
'Rich Text Area. Press ALT-F9 for menu. Press ALT-F10 for toolbar. Press ALT-0 for help' => __('Rich Text Area. Press ALT-F9 for menu. Press ALT-F10 for toolbar. Press ALT-0 for help'),
|
||||||
'Tools' => __('Tools'),
|
'You have unsaved changes are you sure you want to navigate away?' => __( 'The changes you made will be lost if you navigate away from this page.' ),
|
||||||
'View' => __('View'),
|
'Your browser doesn\'t support direct access to the clipboard. Please use the Ctrl+X/C/V keyboard shortcuts instead.' => __('Your browser does not support direct access to the clipboard. Please use the Ctrl+X/C/V keyboard shortcuts instead.'),
|
||||||
'Table' => __('Table'),
|
|
||||||
'Format' => __('Format'),
|
// TinyMCE menus
|
||||||
|
'Insert' => _x( 'Insert', 'TinyMCE menu' ),
|
||||||
|
'File' => _x( 'File', 'TinyMCE menu' ),
|
||||||
|
'Edit' => _x( 'Edit', 'TinyMCE menu' ),
|
||||||
|
'Tools' => _x( 'Tools', 'TinyMCE menu' ),
|
||||||
|
'View' => _x( 'View', 'TinyMCE menu' ),
|
||||||
|
'Table' => _x( 'Table', 'TinyMCE menu' ),
|
||||||
|
'Format' => _x( 'Format', 'TinyMCE menu' ),
|
||||||
|
|
||||||
// WordPress strings
|
// WordPress strings
|
||||||
'Help' => __('Help'),
|
'Help' => __('Help'),
|
||||||
|
@ -701,11 +723,20 @@ final class _WP_Editors {
|
||||||
$baseurl = self::$baseurl;
|
$baseurl = self::$baseurl;
|
||||||
$mce_locale = self::$mce_locale;
|
$mce_locale = self::$mce_locale;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Filter translated strings prepared for TinyMCE.
|
||||||
|
*
|
||||||
|
* @since 3.9.0
|
||||||
|
*
|
||||||
|
* @param array $mce_translation Key/value pairs of strings.
|
||||||
|
* @param string $mce_locale Locale.
|
||||||
|
*/
|
||||||
$mce_translation = apply_filters( 'wp_mce_translation', $mce_translation, $mce_locale );
|
$mce_translation = apply_filters( 'wp_mce_translation', $mce_translation, $mce_locale );
|
||||||
|
|
||||||
foreach ( $mce_translation as $key => $value ) {
|
foreach ( $mce_translation as $key => $value ) {
|
||||||
if ( strpos( $value, '&' ) !== false )
|
if ( false !== strpos( $value, '&' ) ) {
|
||||||
$mce_translation[$key] = html_entity_decode( $value, ENT_QUOTES, 'UTF-8' );
|
$mce_translation[$key] = html_entity_decode( $value, ENT_QUOTES, 'UTF-8' );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return "tinymce.addI18n( '$mce_locale', " . json_encode( $mce_translation ) . ");\n" .
|
return "tinymce.addI18n( '$mce_locale', " . json_encode( $mce_translation ) . ");\n" .
|
||||||
|
|
Loading…
Reference in New Issue