diff options
author | Olivier Hallot <olivier.hallot@libreoffice.org> | 2019-04-25 11:34:05 -0300 |
---|---|---|
committer | Olivier Hallot <olivier.hallot@libreoffice.org> | 2019-04-26 20:46:16 +0200 |
commit | 3c494b6e6db198099f4641aaef3f608842d53faa (patch) | |
tree | 363947b39315cb4dfd6ac284fe46b36c4c517fb3 /help3xsl/online_transform.xsl | |
parent | c1053ceff3ede558b858a30270324430c940311c (diff) |
tdf#122548 copy bascode and pycode to clipboard
This will allow easy testing of coding examples.
Change-Id: I30fc53642b1579744591f2de0c84a615d1755352
Reviewed-on: https://gerrit.libreoffice.org/71385
Tested-by: Jenkins
Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
Diffstat (limited to 'help3xsl/online_transform.xsl')
-rw-r--r-- | help3xsl/online_transform.xsl | 20 |
1 files changed, 16 insertions, 4 deletions
diff --git a/help3xsl/online_transform.xsl b/help3xsl/online_transform.xsl index 630aa8a938..95d19bc56a 100644 --- a/help3xsl/online_transform.xsl +++ b/help3xsl/online_transform.xsl @@ -892,17 +892,29 @@ </xsl:template> <xsl:template match="bascode"> - <div class="bascode" itemscope="true" itemtype="http://schema.org/SoftwareSourceCode" itemprop="codeSampleType" content="snippet"><pre><code class="language-visual-basic line-numbers"><xsl:apply-templates /></code></pre></div> + <div class="bascode" itemscope="true" itemtype="http://schema.org/SoftwareSourceCode" itemprop="codeSampleType" content="snippet"> + <xsl:attribute name="data-tooltip"><xsl:value-of select="$ui_copyclip"/></xsl:attribute> + <pre><code class="language-visual-basic line-numbers"><xsl:apply-templates /></code></pre> + </div> </xsl:template> <xsl:template match="bascode" mode="embedded"> - <div class="bascode" itemscope="true" itemtype="http://schema.org/SoftwareSourceCode" itemprop="codeSampleType" content="snippet"><pre><code class="language-visual-basic line-numbers"><xsl:apply-templates mode="embedded" /></code></pre></div> + <div class="bascode" itemscope="true" itemtype="http://schema.org/SoftwareSourceCode" itemprop="codeSampleType" content="snippet"> + <xsl:attribute name="data-tooltip"><xsl:value-of select="$ui_copyclip"/></xsl:attribute> + <pre><code class="language-visual-basic line-numbers"><xsl:apply-templates mode="embedded" /></code></pre> + </div> </xsl:template> <xsl:template match="pycode"> - <div class="pycode" itemscope="true" itemtype="http://schema.org/SoftwareSourceCode" itemprop="codeSampleType" content="snippet"><pre><code class="language-python line-numbers"><xsl:apply-templates /></code></pre></div> + <div class="pycode" itemscope="true" itemtype="http://schema.org/SoftwareSourceCode" itemprop="codeSampleType" content="snippet"> + <xsl:attribute name="data-tooltip"><xsl:value-of select="$ui_copyclip"/></xsl:attribute> + <pre><code class="language-python line-numbers"><xsl:apply-templates /></code></pre> + </div> </xsl:template> <xsl:template match="pycode" mode="embedded"> - <div class="pycode" itemscope="true" itemtype="http://schema.org/SoftwareSourceCode" itemprop="codeSampleType" content="snippet"><pre><code class="language-python line-numbers"><xsl:apply-templates mode="embedded" /></code></pre></div> + <div class="pycode" itemscope="true" itemtype="http://schema.org/SoftwareSourceCode" itemprop="codeSampleType" content="snippet"> + <xsl:attribute name="data-tooltip"><xsl:value-of select="$ui_copyclip"/></xsl:attribute> + <pre><code class="language-python line-numbers"><xsl:apply-templates mode="embedded" /></code></pre> + </div> </xsl:template> <!-- Insert Logo code snippet --> |