loleaflet/css/toolbar.css | 1 + loleaflet/images/lc_text.svg | 1 + loleaflet/js/toolbar.js | 3 ++- loleaflet/src/unocommands.js | 3 +-- 4 files changed, 5 insertions(+), 3 deletions(-)
New commits: commit 517a5eaaff0a60773d541c9d8acafdc5eceefd04 Author: Jan Holesovsky <ke...@collabora.com> AuthorDate: Thu May 23 16:45:46 2019 +0200 Commit: Miklos Vajna <vmik...@collabora.com> CommitDate: Fri May 24 17:53:49 2019 +0200 Add textbox creation to the Impress toolbar. Uses the newly added parameter to insert it directly, instead of using the mouse to define the bounds first. Change-Id: I3c10f379151b6789908585af02a8a18f3103e001 Reviewed-on: https://gerrit.libreoffice.org/72913 Reviewed-by: Miklos Vajna <vmik...@collabora.com> Tested-by: Miklos Vajna <vmik...@collabora.com> diff --git a/loleaflet/css/toolbar.css b/loleaflet/css/toolbar.css index 881707038..a8fe95076 100644 --- a/loleaflet/css/toolbar.css +++ b/loleaflet/css/toolbar.css @@ -559,6 +559,7 @@ button.leaflet-control-search-next .w2ui-icon.bullet{ background: url('images/lc_defaultbullet.svg') no-repeat center !important; } .w2ui-icon.incrementindent{ background: url('images/lc_decrementlevel.svg') no-repeat center !important; } .w2ui-icon.decrementindent{ background: url('images/lc_decrementindent.svg') no-repeat center !important; } +.w2ui-icon.text{ background: url('images/lc_text.svg') no-repeat center !important; } .w2ui-icon.annotation{ background: url('images/lc_showannotations.svg') no-repeat center !important; } .w2ui-icon.inserttable{ background: url('images/lc_inserttable.svg') no-repeat center !important; } .w2ui-icon.insertgraphic{ background: url('images/lc_gallery.svg') no-repeat center !important; } diff --git a/loleaflet/images/lc_text.svg b/loleaflet/images/lc_text.svg new file mode 100644 index 000000000..e766b7390 --- /dev/null +++ b/loleaflet/images/lc_text.svg @@ -0,0 +1 @@ +<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="m1.5 2.5h21v19h-21z" fill="#fff" stroke="#808080" stroke-linecap="round" stroke-linejoin="round"/><text fill="#4d82b8" font-family="sans-serif" font-size="18.365749" letter-spacing="0" transform="scale(.99242009 1.0076378)" word-spacing="0" x="2.987043" y="15.878721"><tspan fill="#4d82b8" font-family="Carlito" font-weight="bold" x="2.987043" y="15.878721">A</tspan></text><g fill="#808080"><rect height="1" ry=".5" width="6" x="15" y="14"/><rect height="1" ry=".5" width="6" x="15" y="10"/><rect height="1" ry=".5" width="6" x="15" y="6"/><rect height="1" ry=".5" width="18" x="3" y="18"/></g></svg> \ No newline at end of file diff --git a/loleaflet/js/toolbar.js b/loleaflet/js/toolbar.js index 69f63e3f0..874d574e8 100644 --- a/loleaflet/js/toolbar.js +++ b/loleaflet/js/toolbar.js @@ -797,6 +797,7 @@ function createToolbar() { {type: 'button', id: 'numberformatdecdecimals', img: 'numberformatdecdecimals', hint: _UNO('.uno:NumberFormatDecDecimals', 'spreadsheet', true), hidden: true, uno: 'NumberFormatDecDecimals', disabled: true}, {type: 'button', id: 'numberformatincdecimals', img: 'numberformatincdecimals', hint: _UNO('.uno:NumberFormatIncDecimals', 'spreadsheet', true), hidden: true, uno: 'NumberFormatIncDecimals', disabled: true}, {type: 'break', id: 'break-number', hidden: true}, + {type: 'button', id: 'inserttextbox', img: 'text', hint: _UNO('.uno:Text', '', true), uno: 'Text?CreateDirectly:bool=true', hidden: true}, {type: 'button', id: 'insertannotation', img: 'annotation', hint: _UNO('.uno:InsertAnnotation', '', true), hidden: true}, {type: 'drop', id: 'inserttable', img: 'inserttable', hint: _('Insert table'), hidden: true, overlay: {onShow: insertTable}, html: '<div id="inserttable-wrapper"><div id="inserttable-popup" class="inserttable-pop ui-widget ui-corner-all"><div class="inserttable-grid"></div><div id="inserttable-status" class="loleaflet-font" style="padding: 5px;"><br/></div></div></div>'}, @@ -1703,7 +1704,7 @@ function onDocLayerInit() { // FALLTHROUGH intended case 'drawing': toolbarUp.show('leftpara', 'centerpara', 'rightpara', 'justifypara', 'breakpara', 'linespacing', - 'breakspacing', 'defaultbullet', 'defaultnumbering', 'breakbullet', 'inserttable'); + 'breakspacing', 'defaultbullet', 'defaultnumbering', 'breakbullet', 'inserttextbox', 'inserttable'); statusbar.show('prev', 'next'); $('#presentation-toolbar').show(); diff --git a/loleaflet/src/unocommands.js b/loleaflet/src/unocommands.js index 7a0ad5f65..7812790ac 100644 --- a/loleaflet/src/unocommands.js +++ b/loleaflet/src/unocommands.js @@ -179,8 +179,6 @@ var unoCommandsArray = { ParaspaceDecrease:{global:{context:_('Decrease Paragraph Spacing'),menu:_('Decrease Paragraph Spacing'),},}, ParaspaceIncrease:{global:{context:_('Increase Paragraph Spacing'),menu:_('Increase Paragraph Spacing'),},}, Paste:{global:{menu:_('~Paste'),},}, - PasteSpecialMenu:{global:{menu:_('Paste ~Special'),},}, - PasteUnformatted:{global:{context:_('~Unformatted Text'),menu:_('Paste Unformatted Text'),},}, PickList:{global:{menu:_('~File'),},}, PreviousTrackedChange:{text:{menu:_('Pr~evious'),},}, Print:{global:{menu:_('~Print...'),},}, @@ -241,6 +239,7 @@ var unoCommandsArray = { TableMenu:{text:{menu:_('T~able'),},}, TableSelectMenu:{text:{menu:_('~Select'),},}, TaskPaneInsertPage:{presentation:{menu:_('Insert Slide'),},}, + Text:{global:{context:_('Insert Text Box'),menu:_('~Text Box'),},}, TextAlign:{global:{menu:_('Alig~n'),},}, ThesaurusDialog:{global:{menu:_('~Thesaurus...'),},text:{menu:_('~Thesaurus...'),},}, ToggleMergeCells:{spreadsheet:{menu:_('M~erge and Center Cells'),},}, _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits