forked from amazingfate/help
Replacement done with
find . -name \*.xhp -print0 |xargs -0 -P 0 perl -CS -pi -e \
's#(<link[^>]*?) +name *="[^"]*" *( [^>]+|) *>#$1$2>#g'
(note some inconsistencies with space between name and = and also having
empty value, and some more complicated expression to also clear up
double space before/after the attribute)
translation files will be prepped with:
find */helpcontent2 -name \*.po -print0 |xargs -0 -P 0 perl -CS -pi -e \
$'s#(<link[^>]*?) +name=(?:\\\\"[^"]*\\\\"|\'[^\']*\') *( [^>]+|) *(/?>)#$1$2$3#g unless /^#/'
(note that not all languages use the " as quote character for the
attributes, but that also single quotes appera in the po file. Hence
the use of the shell $'string' syntax to be able to quote ' as \'
It also requires to quote the backslash, so that it needs to be escaped
once for the shell, then another time for perl. Also don't work on
obsolete strings (those are prefixed with #~ in the po files)
Also note that <link..></link> gets turned into <link ../> during
translation extraction (along with removal of the space between the
attribute name and the value), so the pattern needs to be slightly
different here)
Change-Id: I95e53a08e6b0095cd894109ea0de154cc4859d8f
Reviewed-on: https://gerrit.libreoffice.org/c/help/+/143713
Tested-by: Jenkins
Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
97 lines
5.6 KiB
XML
97 lines
5.6 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<helpdocument version="1.0">
|
|
|
|
<!--
|
|
* 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 .
|
|
-->
|
|
|
|
|
|
<meta>
|
|
<topic id="textsharedguideformfieldsxml" indexer="include" status="PUBLISH">
|
|
<title xml-lang="en-US" id="tit">Inserting and Editing Buttons</title>
|
|
<filename>/text/shared/guide/formfields.xhp</filename>
|
|
</topic>
|
|
</meta>
|
|
<body>
|
|
<bookmark xml-lang="en-US" branch="index" id="bm_id3149798"><bookmark_value>command buttons, see push buttons</bookmark_value>
|
|
<bookmark_value>controls;adding to documents</bookmark_value>
|
|
<bookmark_value>inserting;push buttons</bookmark_value>
|
|
<bookmark_value>keys;adding push buttons</bookmark_value>
|
|
<bookmark_value>buttons;adding push buttons</bookmark_value>
|
|
<bookmark_value>press buttons, see push buttons</bookmark_value>
|
|
<bookmark_value>push buttons;adding to documents</bookmark_value>
|
|
</bookmark><comment>MW changed "adding;" to "inserting;"</comment>
|
|
<paragraph xml-lang="en-US" id="hd_id3149798" role="heading" level="1"><variable id="formfields"><link href="text/shared/guide/formfields.xhp">Adding a Command Button to a Document</link>
|
|
</variable></paragraph>
|
|
<paragraph xml-lang="en-US" id="par_idN10731" role="paragraph">You can use the Form Controls toolbar to add checkboxes, buttons, tables showing data records, and other controls to a document.</paragraph>
|
|
<paragraph xml-lang="en-US" id="par_idN1077F" role="heading" level="2">To Add a Button to a Document </paragraph>
|
|
<list type="ordered">
|
|
<listitem>
|
|
<paragraph xml-lang="en-US" id="par_id3154751" role="listitem">Choose <item type="menuitem">View - Toolbars - Form Controls</item>.</paragraph>
|
|
</listitem>
|
|
<listitem>
|
|
<table id="tab_id841604586347865">
|
|
<tablerow>
|
|
<tablecell>
|
|
<paragraph role="paragraph" id="par_id951604586347866">
|
|
<image src="cmd/32/pushbutton.png" id="img_id741604586347866" width="1cm" height="1cm"><alt id="alt_id641604586347866">Push Button Icon</alt></image>
|
|
</paragraph>
|
|
</tablecell>
|
|
<tablecell>
|
|
<paragraph xml-lang="en-US" id="par_id3145345" role="listitem">On the Form Controls toolbar, click the <emph>Push Button</emph> icon.</paragraph>
|
|
</tablecell>
|
|
</tablerow>
|
|
</table>
|
|
<paragraph xml-lang="en-US" id="par_idN107A4" role="listitem">The mouse pointer changes to a cross-hair.</paragraph>
|
|
</listitem>
|
|
<listitem>
|
|
<paragraph xml-lang="en-US" id="par_id3159233" role="listitem">In the document, drag to draw the button.</paragraph>
|
|
</listitem>
|
|
<listitem>
|
|
<paragraph xml-lang="en-US" id="par_idN107B2" role="listitem">Right-click the button and choose <menuitem>Control Properties</menuitem>.</paragraph>
|
|
</listitem>
|
|
<listitem>
|
|
<paragraph xml-lang="en-US" id="par_idN107CD" role="listitem">Specify the properties of the button.</paragraph>
|
|
</listitem>
|
|
<listitem>
|
|
<paragraph xml-lang="en-US" id="par_id3154923" role="listitem">To change the button label, click the <emph>General</emph> tab, and edit the text in the <emph>Label</emph> box.</paragraph>
|
|
</listitem>
|
|
<listitem>
|
|
<paragraph xml-lang="en-US" id="par_id3147303" role="listitem">To attach a macro to the button, click the <emph>Events</emph> tab, and click the <emph>... </emph>button beside the button action that you want to run the macro. In the <emph>Assign Macro</emph> dialog, locate the macro that you want to use, and then click <emph>OK</emph>.<comment>UFI: see #i34509#</comment></paragraph>
|
|
</listitem>
|
|
<listitem>
|
|
<paragraph xml-lang="en-US" id="par_idN10814" role="listitem">Close the <emph>Properties</emph> dialog.</paragraph>
|
|
</listitem>
|
|
<listitem>
|
|
<paragraph xml-lang="en-US" id="par_id3147350" role="listitem">(Optional) Specify the properties of the form that the button belongs to.</paragraph>
|
|
</listitem>
|
|
<listitem>
|
|
<paragraph xml-lang="en-US" id="par_idN10828" role="listitem">Right-click the button and choose <menuitem>Form Properties</menuitem>.</paragraph>
|
|
</listitem>
|
|
<listitem>
|
|
<paragraph xml-lang="en-US" id="par_idN1082F" role="listitem">The <emph>Form Properties</emph> dialog opens.</paragraph>
|
|
</listitem>
|
|
<listitem>
|
|
<paragraph xml-lang="en-US" id="par_idN10837" role="listitem">Specify the properties for the form and then close the dialog.</paragraph>
|
|
</listitem>
|
|
</list>
|
|
<section id="relatedtopics">
|
|
<embed href="text/shared/guide/data_addressbook.xhp#data_addressbook"/>
|
|
</section>
|
|
</body>
|
|
</helpdocument>
|