diff options
author | Muhammet Kara <muhammet.kara@collabora.com> | 2019-02-20 14:36:12 +0300 |
---|---|---|
committer | Muhammet Kara <muhammet.kara@collabora.com> | 2019-02-23 15:59:34 +0100 |
commit | 10edac7eccc74aca057a086fed6a58f4387920b6 (patch) | |
tree | bed86e5db929af1fc2597f9754da2aab9fb59b15 /sd/uiconfig | |
parent | e99a7a8dfa6f85a8b8bc53298f9300cf2fc77ec2 (diff) |
Add style options to redaction export
* Add 2 new uno command aliases to handle 2 different
styles of redaction export/sanitization:
* .uno:RedactedExportBlack & .uno:RedactedExportWhite
* Replace the single export button with the 2 new buttons
* Add a new toolbox names .uno:RedactedExportToolbox which
consists of the new 2 commands. It will be added to the Redaction
toolbar after we solve the icon issue.
* Now new redaction shapes are named as RectangleRedactionShape
or FreeformRedactionShape based on their type.
* While exporting to PDF, a seamless step of "Sanitization"
takes place, in which, all shapes in the Draw doc are traversed
and turned into opaq black or white (with black border) shapes,
then the whole doc is converted into bitmap (page by page).
* After the export operation is completed. All shapes are converted
back to the usual redaction style (gray and transparent).
* Icon issue:
* We need 2 new icons for our new commands, one for black redaction
shapes without border, and one for white redaction shapes with black
border.
* I tried adding links to a current icon, but it didn't work, so they
are iconless for now.
* Next to do: Handle icon issue, and take the redaction implementation
into a separate helper class because it is growing fast.
Change-Id: I9b2b7716289b800cdbe7bf3ffa4a442fe5afc474
Reviewed-on: https://gerrit.libreoffice.org/68072
Tested-by: Jenkins
Reviewed-by: Muhammet Kara <muhammet.kara@collabora.com>
Diffstat (limited to 'sd/uiconfig')
-rw-r--r-- | sd/uiconfig/sdraw/toolbar/redactedexportbar.xml | 23 | ||||
-rw-r--r-- | sd/uiconfig/sdraw/toolbar/redactionbar.xml | 3 |
2 files changed, 25 insertions, 1 deletions
diff --git a/sd/uiconfig/sdraw/toolbar/redactedexportbar.xml b/sd/uiconfig/sdraw/toolbar/redactedexportbar.xml new file mode 100644 index 000000000000..06468d459409 --- /dev/null +++ b/sd/uiconfig/sdraw/toolbar/redactedexportbar.xml @@ -0,0 +1,23 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE toolbar:toolbar PUBLIC "-//OpenOffice.org//DTD OfficeDocument 1.0//EN" "toolbar.dtd"> +<!-- + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . +--> +<toolbar:toolbar xmlns:toolbar="http://openoffice.org/2001/toolbar" xmlns:xlink="http://www.w3.org/1999/xlink"> + <toolbar:toolbaritem xlink:href=".uno:ExportDirectToPDF?IsRedactMode:bool=true"/> + <toolbar:toolbaritem xlink:href=".uno:ExportDirectToPDF"/> +</toolbar:toolbar> diff --git a/sd/uiconfig/sdraw/toolbar/redactionbar.xml b/sd/uiconfig/sdraw/toolbar/redactionbar.xml index 43ce5e856f7a..bb27cd01acb4 100644 --- a/sd/uiconfig/sdraw/toolbar/redactionbar.xml +++ b/sd/uiconfig/sdraw/toolbar/redactionbar.xml @@ -21,5 +21,6 @@ <toolbar:toolbaritem xlink:href=".uno:Rect?FillTransparence:short=50&FillColor:string=COL_GRAY7&LineStyle:short=0&IsSticky:bool=true&ShapeName:string=RectangleRedactionShape"/> <toolbar:toolbaritem xlink:href=".uno:Freeline_Unfilled?Transparence:short=50&Color:string=COL_GRAY7&Width:short=500&IsSticky:bool=true&ShapeName:string=FreeformRedactionShape"/> <toolbar:toolbarseparator/> - <toolbar:toolbaritem xlink:href=".uno:ExportDirectToPDF?IsRedactMode:bool=true"/> + <toolbar:toolbaritem xlink:href=".uno:RedactedExportBlack"/> + <toolbar:toolbaritem xlink:href=".uno:RedactedExportWhite"/> </toolbar:toolbar> |