Files
help/source/text/swriter/guide/table_insert.xhp
Ilmari Lauhakangas 7e42394ecb tdf#152323 drop name attribute from <link> elements
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>
2022-12-07 17:39:02 +00:00

189 lines
9.8 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="textswriterguidetable_insertxml" indexer="include" status="PUBLISH">
<title xml-lang="en-US" id="tit">Inserting Tables</title>
<filename>/text/swriter/guide/table_insert.xhp</filename>
</topic>
</meta>
<body>
<bookmark xml-lang="en-US" branch="index" id="bm_id3156377"><bookmark_value>tables; inserting text tables</bookmark_value>
<bookmark_value>inserting; tables in text</bookmark_value>
<bookmark_value>DDE; inserting tables</bookmark_value>
<bookmark_value>OLE objects; inserting tables in</bookmark_value>
<bookmark_value>cells;inserting from spreadsheets</bookmark_value>
<bookmark_value>tables in spreadsheets;inserting in text</bookmark_value>
<bookmark_value>spreadsheets;inserting tables from</bookmark_value>
</bookmark><comment>mw changed "cell ranges;" to "cells;"</comment>
<paragraph xml-lang="en-US" id="hd_id3156377" role="heading" level="1"><variable id="table_insert"><link href="text/swriter/guide/table_insert.xhp">Inserting Tables</link>
</variable></paragraph>
<paragraph xml-lang="en-US" id="par_id3149489" role="paragraph">There are several ways to create a table in a text document. You can insert a table from a toolbar, through a menu command, or from a spreadsheet. <comment>UFI: from a database?</comment></paragraph>
<paragraph xml-lang="en-US" id="hd_id3155908" role="heading" level="2">To Insert a Table From a Toolbar</paragraph>
<list type="ordered">
<listitem>
<paragraph xml-lang="en-US" id="par_id3155861" role="listitem">Place the cursor in your document where you want to insert the table.</paragraph>
</listitem>
<listitem>
<paragraph xml-lang="en-US" id="par_id3147416" role="listitem">On the <emph>Standard</emph> or the <emph>Insert</emph> bar, click the arrow next to the <emph>Table</emph> icon.</paragraph>
</listitem>
<listitem>
<paragraph xml-lang="en-US" id="par_id3153398" role="listitem">In the table grid, drag to select the numbers of rows and columns that you want, and then release.</paragraph>
</listitem>
</list>
<paragraph xml-lang="en-US" id="par_id3153416" role="paragraph">To cancel, drag to the other side until <emph>Cancel</emph> appears in the preview area of the grid.<comment>make it RTL compliant</comment></paragraph>
<paragraph xml-lang="en-US" id="hd_id3153135" role="heading" level="2">To Insert a Table With a Menu Command</paragraph>
<list type="ordered">
<listitem>
<paragraph xml-lang="en-US" id="par_id3149642" role="listitem">Place the cursor in your document where you want to insert the table.</paragraph>
</listitem>
<listitem>
<paragraph xml-lang="en-US" id="par_id3149609" role="listitem">Choose <emph>Table - Insert Table</emph>. </paragraph>
</listitem>
<listitem>
<paragraph xml-lang="en-US" id="par_id3149858" role="listitem">In the <emph>Size</emph> area, enter the number of rows and columns.</paragraph>
</listitem>
<listitem>
<paragraph xml-lang="en-US" id="par_id3145097" role="listitem">Select the options that you want, click <emph>OK</emph>.</paragraph>
</listitem>
</list>
<paragraph xml-lang="en-US" id="hd_id3149572" role="heading" level="2">To Insert a Table From a Calc Spreadsheet</paragraph>
<list type="ordered">
<listitem>
<paragraph xml-lang="en-US" id="par_id3149594" role="listitem">Open the $[officename] Calc spreadsheet containing the cell range that you want to insert.</paragraph>
</listitem>
<listitem>
<paragraph xml-lang="en-US" id="par_id3156250" role="listitem">In the spreadsheet, drag to select the cells.</paragraph>
</listitem>
<listitem>
<paragraph xml-lang="en-US" id="par_id3154395" role="listitem">Choose <emph>Edit - Copy</emph>.</paragraph>
</listitem>
<listitem>
<paragraph xml-lang="en-US" id="par_id3154420" role="listitem">In your text document, do one of the following:</paragraph>
</listitem>
</list>
<list type="unordered">
<listitem>
<paragraph role="listitem" id="par_id3153383" xml-lang="en-US">Choose <emph>Edit - Paste</emph>. The cell range is pasted as an OLE object. To edit the contents of the cells, double-click the object.</paragraph>
</listitem>
<listitem>
<paragraph role="listitem" id="par_id3154248" xml-lang="en-US">Choose <emph>Edit - Paste Special</emph>, and choose from the following options:</paragraph>
</listitem>
</list>
<table id="tbl_id3152755">
<tablerow>
<tablecell>
<paragraph xml-lang="en-US" id="par_id3154844" role="tablehead">Options</paragraph>
</tablecell>
<tablecell>
<paragraph xml-lang="en-US" id="par_id3154867" role="tablehead">Is inserted as...</paragraph>
</tablecell>
</tablerow>
<tablerow>
<tablecell>
<paragraph xml-lang="en-US" id="par_id3155893" role="tablecontent">$[officename] $[officeversion] Spreadsheet</paragraph>
</tablecell>
<tablecell>
<paragraph xml-lang="en-US" id="par_id3149986" role="tablecontent">OLE object - as with <switchinline select="sys"><caseinline select="MAC">Command
</caseinline><defaultinline>Ctrl</defaultinline></switchinline>+V or drag-and-drop</paragraph>
</tablecell>
</tablerow>
<tablerow>
<tablecell>
<paragraph xml-lang="en-US" id="par_id3148674" role="tablecontent">GDIMetaFile</paragraph>
</tablecell>
<tablecell>
<paragraph xml-lang="en-US" id="par_id3148697" role="tablecontent">Graphic</paragraph>
</tablecell>
</tablerow>
<tablerow>
<tablecell>
<paragraph xml-lang="en-US" id="par_id3153027" role="tablecontent">Bitmap</paragraph>
</tablecell>
<tablecell>
<paragraph xml-lang="en-US" id="par_id3148957" role="tablecontent">Graphic</paragraph>
</tablecell>
</tablerow>
<tablerow>
<tablecell>
<paragraph xml-lang="en-US" id="par_id3147104" role="tablecontent">HTML</paragraph>
</tablecell>
<tablecell>
<paragraph xml-lang="en-US" id="par_id3147126" role="tablecontent">HTML table</paragraph>
</tablecell>
</tablerow>
<tablerow>
<tablecell>
<paragraph xml-lang="en-US" id="par_id3150223" role="tablecontent">Unformatted text</paragraph>
</tablecell>
<tablecell>
<paragraph xml-lang="en-US" id="par_id3150246" role="tablecontent">Text only, tab stops as separators</paragraph>
</tablecell>
</tablerow>
<tablerow>
<tablecell>
<paragraph xml-lang="en-US" id="par_id3145227" role="tablecontent">Formatted text [RTF]</paragraph>
</tablecell>
<tablecell>
<paragraph xml-lang="en-US" id="par_id3150938" role="tablecontent">Text table</paragraph>
</tablecell>
</tablerow>
<tablerow>
<tablecell>
<paragraph xml-lang="en-US" id="par_id3150965" role="tablecontent"><switchinline select="sys"><caseinline select="WIN">DDE link (only under Windows)
</caseinline></switchinline></paragraph>
</tablecell>
<tablecell>
<paragraph xml-lang="en-US" id="par_id3154377" role="tablecontent"><switchinline select="sys"><caseinline select="WIN">Table structure and contents, without formatting. With updating
</caseinline></switchinline></paragraph>
</tablecell>
</tablerow>
</table>
<paragraph xml-lang="en-US" id="hd_id3151093" role="heading" level="3">Drag-and-Drop a Cell Range From a Calc Spreadsheet</paragraph>
<list type="ordered">
<listitem>
<paragraph xml-lang="en-US" id="par_id3151116" role="listitem">Open the $[officename] Calc spreadsheet containing the cell range that you want to insert.</paragraph>
</listitem>
<listitem>
<paragraph xml-lang="en-US" id="par_id3150515" role="listitem">In the spreadsheet, drag to select the cells.</paragraph>
</listitem>
<listitem>
<paragraph xml-lang="en-US" id="par_id3150534" role="listitem">Click and hold the mouse button in the selected cells.</paragraph>
</listitem>
<listitem>
<paragraph xml-lang="en-US" id="par_id3147527" role="listitem">Drag the selected cells into the text document.</paragraph>
</listitem>
</list>
<embed href="text/shared/00/00000004.xhp#related"/>
<embed href="text/swriter/guide/table_select.xhp#table_select"/>
<embed href="text/swriter/guide/table_delete.xhp#table_delete"/>
<embed href="text/swriter/guide/borders.xhp#borders"/>
</body>
</helpdocument>