Dave Jarvis' Repositories

git clone https://repo.autonoma.ca/repo/delibero.git

Reformatted code to fit on a page without line breakage.

AuthorDave Jarvis <email>
Date2014-08-06 10:24:29 GMT-0700
Commit3f2b24b1887f0c8a74705e7d1e78602a36b2333a
Parent0dae068
xml/account.xml
<entry>
<comment>
- Data retention can <xref id="2">overturn</xref> the presumption of
- innocence.
+ Data retention can <xref id="2">overturn</xref> the
+ presumption of innocence.
</comment>
<policy><xref id="3">Digital Freedom Act</xref></policy>
<timestamp><date>Jun 15, 2014</date><time>16:12:50</time></timestamp>
<state>Accepted</state>
</entry>
<entry>
<comment>
- Ensure anonymity when seeking or communicating sensitive health-related information.
+ Ensure anonymity when seeking or communicating sensitive
+ health-related information.
</comment>
<policy><xref id="3">Digital Freedom Act</xref></policy>
</related>
</account>
+
xml/chart.xsl
| Copyright 2014, Dave Jarvis, White Magic Software, Inc.
|
- | Permission is hereby granted, free of charge, to any person obtaining a copy
- | of this software and associated documentation files (the "Software"), to deal
- | in the Software without restriction, including without limitation the rights
- | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- | copies of the Software, and to permit persons to whom the Software is
- | furnished to do so, subject to the following conditions:
+ | Permission is hereby granted, free of charge, to any person
+ | obtaining a copy of this software and associated documentation
+ | files (the "Software"), to deal in the Software without
+ | restriction, including without limitation the rights to use,
+ | copy, modify, merge, publish, distribute, sublicense, and/or
+ | sell copies of the Software, and to permit persons to whom the
+ | Software is furnished to do so, subject to the following
+ | conditions:
|
- | The above copyright notice and this permission notice shall be included in
- | all copies or substantial portions of the Software.
+ | The above copyright notice and this permission notice shall be
+ | included in all copies or substantial portions of the Software.
|
- | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- | THE SOFTWARE.
+ | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ | OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ | NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ | HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ | WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ | FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ | OTHER DEALINGS IN THE SOFTWARE.
+-->
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
-<xsl:include href="math.xsl" />
+<xsl:include href="math.xsl"/>
<!-- Pie wedge colours based on this hue. -->
-<xsl:variable name="base_colour" select="'46A5E5'" />
+<xsl:variable name="base_colour" select="'46A5E5'"/>
<!-- Pie wedge stroke colour. -->
-<xsl:variable name="stroke_colour" select="'white'" />
+<xsl:variable name="stroke_colour" select="'white'"/>
<!-- Pie chart width and height. -->
-<xsl:variable name="width" select="200" />
-<xsl:variable name="height" select="$width" />
+<xsl:variable name="width" select="200"/>
+<xsl:variable name="height" select="$width"/>
<!-- Convert XML data into a pie chart. -->
<xsl:template match="dataset" mode="piechart">
<!-- Number of wedges. -->
- <xsl:variable name="wedges" select="count(data)" />
+ <xsl:variable name="wedges" select="count(data)"/>
- <!-- Calculate the total value for all wedges (for percentages). -->
- <xsl:variable name="total" select="sum(data//value)" />
+ <!-- Calculate the sum of all wedge values. -->
+ <xsl:variable name="total" select="sum(data//value)"/>
<div class="chart">
<div class="graph">
- <svg width="{$width}" height="{$height}" version="1.1" xmlns="http://www.w3.org/2000/svg">
+ <svg width="{$width}" height="{$height}" version="1.1"
+ xmlns="http://www.w3.org/2000/svg">
<xsl:for-each select="data">
<xsl:apply-templates select="value" mode="piechart">
<xsl:with-param name="colour">
<xsl:call-template name="fill">
- <xsl:with-param name="wedge" select="position()" />
- <xsl:with-param name="wedges" select="$wedges" />
- <xsl:with-param name="colour" select="$base_colour" />
+ <xsl:with-param name="wedge" select="position()"/>
+ <xsl:with-param name="wedges" select="$wedges"/>
+ <xsl:with-param name="colour" select="$base_colour"/>
</xsl:call-template>
</xsl:with-param>
- <xsl:with-param name="total" select="$total" />
- <xsl:with-param name="runningTotal" select="sum(preceding-sibling::data/value)" />
- <xsl:with-param name="radius" select="$width * 0.5" />
+ <xsl:with-param name="total"
+ select="$total"/>
+ <xsl:with-param name="runningTotal"
+ select="sum(preceding-sibling::data/value)"/>
+ <xsl:with-param name="radius"
+ select="$width * 0.5"/>
</xsl:apply-templates>
</xsl:for-each>
</svg>
</div>
- <!-- SVG 1.1 has no text flow abilities: legend is plain HTML. -->
+ <!-- SVG 1.1 has no text flow abilities. -->
<div class="legend">
<xsl:for-each select="data//name">
<xsl:variable name="colour">
<xsl:call-template name="fill">
- <xsl:with-param name="wedge" select="position()" />
- <xsl:with-param name="wedges" select="$wedges" />
- <xsl:with-param name="colour" select="$base_colour" />
+ <xsl:with-param name="wedge" select="position()"/>
+ <xsl:with-param name="wedges" select="$wedges"/>
+ <xsl:with-param name="colour" select="$base_colour"/>
</xsl:call-template>
</xsl:variable>
- <xsl:variable name="percent" select="concat(.,' (',format-number(../value div $total, '0.00%'),')')" />
+ <xsl:variable name="percent">
+ <xsl:value-of select="."/>
+ <xsl:text> (</xsl:text>
+ <xsl:value-of
+ select="format-number(../value div $total, '0.00%')"/>
+ <xsl:text>)</xsl:text>
+ </xsl:variable>
<div class="piece">
- <div class="bullet" style="background-color:{$colour}" />
- <xsl:value-of select="$percent" />
+ <div class="bullet" style="background-color:{$colour}"/>
+ <xsl:value-of select="$percent"/>
</div>
</xsl:for-each>
<xsl:template match="value" mode="piechart">
<!-- Colour of the pie wedge. -->
- <xsl:param name="colour" />
+ <xsl:param name="colour"/>
<!-- Sum of all the wedge values. -->
- <xsl:param name="total" />
+ <xsl:param name="total"/>
<!-- Sum of all preceding wedge values. -->
- <xsl:param name="runningTotal" />
+ <xsl:param name="runningTotal"/>
<!-- Pie radius. -->
- <xsl:param name="radius" />
+ <xsl:param name="radius"/>
<!-- Hover text. -->
- <xsl:variable name="title" select="concat(../name,' (',format-number(., '###,###'),')')" />
+ <xsl:variable name="title"
+ select="concat(../name,' (',format-number(., '###,###'),')')"/>
<!-- Abbreviation. -->
- <xsl:variable name="r" select="$radius" />
+ <xsl:variable name="r" select="$radius"/>
<!-- Set the start and ending angles. -->
- <xsl:variable name="sa" select="360.0 * ($runningTotal div $total)" />
- <xsl:variable name="ea" select="360.0 * (($runningTotal + .) div $total)" />
+ <xsl:variable name="sa"
+ select="360.0 * ($runningTotal div $total)"/>
+ <xsl:variable name="ea"
+ select="360.0 * (($runningTotal + .) div $total)"/>
<!-- Calculate the starting Cartesian coordinate. -->
<xsl:variable name="x1">
<xsl:call-template name="sine">
- <xsl:with-param name="degrees" select="-$sa" />
+ <xsl:with-param name="degrees" select="-$sa"/>
</xsl:call-template>
</xsl:variable>
<xsl:variable name="y1">
<xsl:call-template name="sine">
- <xsl:with-param name="degrees" select="(-$sa - 90)" />
+ <xsl:with-param name="degrees" select="(-$sa - 90)"/>
</xsl:call-template>
</xsl:variable>
<!-- Calculate the ending Cartesian coordinate. -->
<xsl:variable name="x2">
<xsl:call-template name="sine">
- <xsl:with-param name="degrees" select="-$ea" />
+ <xsl:with-param name="degrees" select="-$ea"/>
</xsl:call-template>
</xsl:variable>
<xsl:variable name="y2">
<xsl:call-template name="sine">
- <xsl:with-param name="degrees" select="(-$ea - 90)" />
+ <xsl:with-param name="degrees" select="(-$ea - 90)"/>
</xsl:call-template>
</xsl:variable>
</xsl:choose>
</xsl:variable>
+
+ <!-- Help the path's d attribute fit on a printed page. -->
+ <xsl:variable name="x1r" select="$x1 * $r"/>
+ <xsl:variable name="y1r" select="$y1 * $r"/>
+ <xsl:variable name="x2r" select="$x2 * $r"/>
+ <xsl:variable name="y2r" select="$y2 * $r"/>
<!-- Create the wedge path. -->
<path xmlns="http://www.w3.org/2000/svg"
fill="{$colour}"
title="{$title}"
stroke="{$stroke_colour}"
transform="translate({$radius},{$radius})"
- d="M 0 0 L {$x1 * $r} {$y1 * $r} A {$r} {$r} 0 {$sweep} 0 {$x2 * $r} {$y2 * $r} Z" />
+ d="M 0 0 L {$x1r} {$y1r} A {$r} {$r} 0 {$sweep} 0 {$x2r} {$y2r} Z"/>
</xsl:template>
<xsl:template name="fill">
<!-- Current wedge number for generating a colour. -->
- <xsl:param name="wedge" />
+ <xsl:param name="wedge"/>
<!-- Total number of wedges in the pie. -->
- <xsl:param name="wedges" />
+ <xsl:param name="wedges"/>
<!-- RGB colour in hexadecimal. -->
- <xsl:param name="colour" />
+ <xsl:param name="colour"/>
<!-- Derive the colour decimal values from $colour's HEX code. -->
<xsl:variable name="r">
<xsl:call-template name="hex2dec">
- <xsl:with-param name="hex" select="substring( $colour, 1, 2 )" />
+ <xsl:with-param name="hex"
+ select="substring( $colour, 1, 2 )"/>
</xsl:call-template>
</xsl:variable>
<xsl:variable name="g">
<xsl:call-template name="hex2dec">
- <xsl:with-param name="hex" select="substring( $colour, 3, 2 )" />
+ <xsl:with-param name="hex"
+ select="substring( $colour, 3, 2 )"/>
</xsl:call-template>
</xsl:variable>
<xsl:variable name="b">
<xsl:call-template name="hex2dec">
- <xsl:with-param name="hex" select="substring( $colour, 5, 2 )" />
+ <xsl:with-param name="hex"
+ select="substring( $colour, 5, 2 )"/>
</xsl:call-template>
</xsl:variable>
- <xsl:variable name="alpha" select="(2 * $r - $g - $b) * 0.5" />
- <xsl:variable name="beta" select="0.86602540378 * ($g - $b)" />
+ <xsl:variable name="alpha"
+ select="(2 * $r - $g - $b) * 0.5"/>
+ <xsl:variable name="beta"
+ select="0.86602540378 * ($g - $b)"/>
<xsl:variable name="base_hue">
<xsl:call-template name="atan2">
- <xsl:with-param name="x" select="$alpha" />
- <xsl:with-param name="y" select="$beta" />
+ <xsl:with-param name="x" select="$alpha"/>
+ <xsl:with-param name="y" select="$beta"/>
</xsl:call-template>
</xsl:variable>
<xsl:variable name="chroma">
<xsl:call-template name="sqrt">
- <xsl:with-param name="n" select="($alpha * $alpha) + ($beta * $beta)" />
+ <xsl:with-param name="n"
+ select="($alpha * $alpha) + ($beta * $beta)"/>
</xsl:call-template>
</xsl:variable>
<xsl:variable name="value">
<xsl:variable name="max_rg">
<xsl:call-template name="max">
- <xsl:with-param name="a" select="$r" />
- <xsl:with-param name="b" select="$g" />
+ <xsl:with-param name="a" select="$r"/>
+ <xsl:with-param name="b" select="$g"/>
</xsl:call-template>
</xsl:variable>
<xsl:variable name="max_gb">
<xsl:call-template name="max">
- <xsl:with-param name="a" select="$g" />
- <xsl:with-param name="b" select="$b" />
+ <xsl:with-param name="a" select="$g"/>
+ <xsl:with-param name="b" select="$b"/>
</xsl:call-template>
</xsl:variable>
<xsl:call-template name="max">
- <xsl:with-param name="a" select="$max_rg" />
- <xsl:with-param name="b" select="$max_gb" />
+ <xsl:with-param name="a" select="$max_rg"/>
+ <xsl:with-param name="b" select="$max_gb"/>
</xsl:call-template>
</xsl:variable>
<!-- Calculate the wedge hue from the base colour. -->
- <xsl:variable name="h_rotate" select="($base_hue + ((240 div $wedges) * $wedge) mod 240)"></xsl:variable>
- <xsl:variable name="h_prime" select="$h_rotate div 60.0" />
- <xsl:variable name="h_mod" select="$h_prime mod 2 - 1" />
- <xsl:variable name="h_abs" select="($h_mod &gt;= 0) * $h_mod - not($h_mod &gt;= 0) * $h_mod" />
+ <xsl:variable name="h_rotate"
+ select="($base_hue + ((240 div $wedges) * $wedge) mod 240)"/>
+ <xsl:variable name="h_prime"
+ select="$h_rotate div 60.0"/>
+ <xsl:variable name="h_mod"
+ select="$h_prime mod 2 - 1"/>
+ <xsl:variable name="h_abs"
+ select="($h_mod &gt;= 0) * $h_mod - not($h_mod &gt;= 0) * $h_mod"/>
- <xsl:variable name="c" select="$chroma" />
- <xsl:variable name="x" select="$c * (1 - $h_abs)" />
- <xsl:variable name="m" select="$value - $c" />
+ <xsl:variable name="c" select="$chroma"/>
+ <xsl:variable name="x" select="$c * (1 - $h_abs)"/>
+ <xsl:variable name="m" select="$value - $c"/>
- <xsl:variable name="cm" select="round( $c + $m )" />
- <xsl:variable name="xm" select="round( $x + $m )" />
- <xsl:variable name="zm" select="round( 0 + $m )" />
+ <xsl:variable name="cm" select="round( $c + $m )"/>
+ <xsl:variable name="xm" select="round( $x + $m )"/>
+ <xsl:variable name="zm" select="round( 0 + $m )"/>
<xsl:text>rgb(</xsl:text>
<xsl:choose>
<xsl:when test="0 &lt;= $h_prime and $h_prime &lt; 1">
- <xsl:value-of select="concat( $cm, ',', $xm, ',', $zm )" />
+ <xsl:value-of select="concat( $cm, ',', $xm, ',', $zm )"/>
</xsl:when>
<xsl:when test="1 &lt;= $h_prime and $h_prime &lt; 2">
- <xsl:value-of select="concat( $xm, ',', $cm, ',', $zm )" />
+ <xsl:value-of select="concat( $xm, ',', $cm, ',', $zm )"/>
</xsl:when>
<xsl:when test="2 &lt;= $h_prime and $h_prime &lt; 3">
- <xsl:value-of select="concat( $zm, ',', $cm, ',', $xm )" />
+ <xsl:value-of select="concat( $zm, ',', $cm, ',', $xm )"/>
</xsl:when>
<xsl:when test="3 &lt;= $h_prime and $h_prime &lt; 4">
- <xsl:value-of select="concat( $zm, ',', $xm, ',', $cm )" />
+ <xsl:value-of select="concat( $zm, ',', $xm, ',', $cm )"/>
</xsl:when>
<xsl:when test="4 &lt;= $h_prime and $h_prime &lt; 5">
- <xsl:value-of select="concat( $xm, ',', $zm, ',', $cm )" />
+ <xsl:value-of select="concat( $xm, ',', $zm, ',', $cm )"/>
</xsl:when>
<xsl:when test="5 &lt;= $h_prime and $h_prime &lt; 6">
- <xsl:value-of select="concat( $cm, ',', $zm, ',', $xm )" />
+ <xsl:value-of select="concat( $cm, ',', $zm, ',', $xm )"/>
</xsl:when>
<xsl:otherwise>
- <xsl:value-of select="concat( $r, ',', $g, ',', $b )" />
+ <xsl:value-of select="concat( $r, ',', $g, ',', $b )"/>
</xsl:otherwise>
</xsl:choose>
<xsl:text>)</xsl:text>
</xsl:template>
</xsl:stylesheet>
+
xml/common.xsl
| Copyright 2014, Dave Jarvis, White Magic Software, Inc.
|
- | Permission is hereby granted, free of charge, to any person obtaining a copy
- | of this software and associated documentation files (the "Software"), to deal
- | in the Software without restriction, including without limitation the rights
- | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- | copies of the Software, and to permit persons to whom the Software is
- | furnished to do so, subject to the following conditions:
+ | Permission is hereby granted, free of charge, to any person
+ | obtaining a copy of this software and associated documentation
+ | files (the "Software"), to deal in the Software without
+ | restriction, including without limitation the rights to use,
+ | copy, modify, merge, publish, distribute, sublicense, and/or
+ | sell copies of the Software, and to permit persons to whom the
+ | Software is furnished to do so, subject to the following
+ | conditions:
|
- | The above copyright notice and this permission notice shall be included in
- | all copies or substantial portions of the Software.
+ | The above copyright notice and this permission notice shall be
+ | included in all copies or substantial portions of the Software.
|
- | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- | THE SOFTWARE.
+ | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ | OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ | NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ | HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ | WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ | FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ | OTHER DEALINGS IN THE SOFTWARE.
+-->
<xsl:stylesheet version="1.0"
<title>World Policies: rational, moderated, transparent deliberation</title>
- <link rel="stylesheet" type="text/css" href="common.css" />
- <link rel="stylesheet" type="text/css" href="//fonts.googleapis.com/css?family=Open+Sans" />
- <link rel="stylesheet" type="text/css" href="//fonts.googleapis.com/css?family=Montserrat" />
+ <link rel="stylesheet" type="text/css"
+ href="common.css" />
+ <link rel="stylesheet" type="text/css"
+ href="//fonts.googleapis.com/css?family=Open+Sans" />
+ <link rel="stylesheet" type="text/css"
+ href="//fonts.googleapis.com/css?family=Montserrat" />
<script type="text/javascript">
<!-- The 'id' attribute indicates a link. -->
<xsl:template match="*[@id]">
- <div class="{local-name()}"><a href="{$action}?action={local-name()}&amp;id={@id}"><xsl:apply-templates select="node()|*" /></a></div>
+ <div class="{local-name()}"><a
+ href="{$action}?action={local-name()}&amp;id={@id}"><xsl:apply-templates
+ select="node()|*" /></a></div>
</xsl:template>
</xsl:template>
-<xsl:template match="/policy/resources/expenses/dataset/*[name()='data' or name()='footer']/value">
- <div class="value"><xsl:value-of select="format-number(., '###,###')" /></div>
+<xsl:template match="//dataset/*[name()='data' or name()='footer']/value">
+ <div class="value"><xsl:value-of
+ select="format-number(., '###,###')" /></div>
</xsl:template>
xml/discuss.xml
<?xml version="1.0" encoding="utf-8"?>
-<?xml-stylesheet type="text/xsl" href="common.xsl" ?>
+<?xml-stylesheet type="text/xsl" href="common.xsl"?>
<policy>
<summary>
</votes>
<paragraph>
- Without highly secure private data, individuals are at risk of
- <xref id="8">discrimination</xref> by virtue of their membership
- in groups.
+ Without highly secure private data, individuals are at risk
+ of <xref id="8">discrimination</xref> by virtue of their
+ membership in groups.
</paragraph>
</implication>
</votes>
<paragraph>
- Ensure the <xref id="10">rights</xref> freedom of assembly and
- freedom of association.
+ Ensure the <xref id="10">rights</xref> freedom of assembly
+ and freedom of association.
</paragraph>
</implication>
<paragraph>
Offline and online rights attain <xref id="11">equal</xref>
- treatment under law. [<xref id="7">§ Article 12 of the Universal
- Declaration of Human Rights</xref>]
+ treatment under law. [<xref id="7">§ Article 12 of the
+ Universal Declaration of Human Rights</xref>]
</paragraph>
</implication>
<implication>
<votes>
<pro>210</pro>
<con>14</con>
</votes>
<paragraph>
As documented in <xref id="12">Naked Citizens</xref>, once a
- computer algorithm ascribes someone as suspicious, all else in that
- person's life becomes sinister and suspect.
+ computer algorithm ascribes someone as suspicious, all else
+ in that person's life becomes sinister and suspect.
</paragraph>
</implication>
<implication>
<votes>
<pro>114</pro>
<con>22</con>
</votes>
<paragraph>
- Dragnet surveillance gives police greater powers with less oversight,
- producing false positives due to <xref id="14">profiling
- problems</xref>.
+ Dragnet surveillance gives police greater powers with less
+ oversight, producing false positives due to
+ <xref id="14">profiling problems</xref>.
</paragraph>
</implication>
<implication>
<votes>
<pro>94</pro>
<con>8</con>
</votes>
<paragraph>
- Data retention can <xref id="13">overturn</xref> the presumption of
- innocence.
+ Data retention can <xref id="13">overturn</xref> the
+ presumption of innocence.
</paragraph>
</implication>
<implication>
<votes>
<pro>718</pro>
<con>132</con>
</votes>
<paragraph>
- Unchecked access to big data enabled the <xref id="14">Holocaust</xref>.
+ Unchecked access to big data enabled the
+ <xref id="14">Holocaust</xref>.
</paragraph>
</implication>
xml/edit-discuss-flag.css
.related > .flag::after {
content: "";
- padding-right: 0p;
+ padding-right: 0;
}
xml/hypothesis.xml
<?xml version="1.0" encoding="utf-8"?>
-<?xml-stylesheet type="text/xsl" href="common.xsl" ?>
+<?xml-stylesheet type="text/xsl" href="common.xsl"?>
<policy>
<summary>
<title>Digital Freedom Act</title>
</summary>
<hypotheses>
<overview>
<paragraph>
- Freedom is the power or right, to act, speak, or think as one wants
- without hindrance or restraint. Freedom is the absence of subjection
- to foreign domination or despotic government. Freedom means people
- may choose their own actions in an environment that nurtures the full
- development of human potential. By enacting and enforcing this
- policy, several positive societal outcomes should be observed.
+ Freedom is the power or right, to act, speak, or think as one
+ wants without hindrance or restraint. Freedom is the absence
+ of subjection to foreign domination or despotic government.
+ Freedom means people may choose their own actions in an
+ environment that nurtures the full development of human
+ potential. By enacting and enforcing this policy, several
+ positive societal outcomes should be observed.
</paragraph>
</overview>
<general>
<paragraph>
The freedom experienced by world citizens can be ranked by
various indices, including: <xref id="1">Economic Freedom
- of the World Index</xref>, <xref id="2">Index of Freedom in the
- World</xref>, <xref id="3">Worldwide Press Freedom Index</xref>, the
- <xref id="4">Democracy Index</xref>, <xref id="5">Freedom in the
- World Report</xref>, <xref id="6">Index of Economic Freedom</xref>,
+ of the World Index</xref>, <xref id="2">Index of Freedom in
+ the World</xref>, <xref id="3">Worldwide Press Freedom
+ Index</xref>, the <xref id="4">Democracy Index</xref>,
+ <xref id="5">Freedom in the World Report</xref>,
+ <xref id="6">Index of Economic Freedom</xref>,
<xref id="7">CIRI Human Rights Data Project</xref>, and the
- Transparency International <xref id="8">Corruption Perceptions
- Index</xref>.
+ Transparency International <xref id="8">Corruption
+ Perceptions Index</xref>.
</paragraph>
</general>
<directional>
<paragraph>
- Nations that empower their citizens with the most freedoms rank
- the highest in various indices, relative to nations that restrict
- citizen freedoms the most. More freedom is correlated with higher
- earnings, increased happiness, protected civil rights, cleaner
- environments, less corruption, lower infant mortality rates, less
- child labour, and longer life expectancy.
+ Nations that empower their citizens with the most freedoms
+ rank the highest in various indices, relative to nations that
+ restrict citizen freedoms the most. More freedom is
+ correlated with higher earnings, increased happiness,
+ protected civil rights, cleaner environments, less
+ corruption, lower infant mortality rates, less child labour,
+ and longer life expectancy.
</paragraph>
</directional>
<measurable>
<paragraph>
If a nation's citizens' freedom to private communications is
- restricted (through surveillance or policy), then that country's
- average rank across the given indices will decrease.
+ restricted (through surveillance or policy), then that
+ country's average rank across the given indices will
+ decrease.
</paragraph>
</measurable>
</hypotheses>
+
<related>
<discuss id="1" />
xml/index.xml
<?xml version="1.0" encoding="utf-8"?>
-<?xml-stylesheet type="text/xsl" href="common.xsl" ?>
+<?xml-stylesheet type="text/xsl" href="common.xsl"?>
<policies>
<policy>
xml/math.xsl
| Copyright 2014, Dave Jarvis, White Magic Software, Inc.
|
- | Permission is hereby granted, free of charge, to any person obtaining a copy
- | of this software and associated documentation files (the "Software"), to deal
- | in the Software without restriction, including without limitation the rights
- | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- | copies of the Software, and to permit persons to whom the Software is
- | furnished to do so, subject to the following conditions:
+ | Permission is hereby granted, free of charge, to any person
+ | obtaining a copy of this software and associated documentation
+ | files (the "Software"), to deal in the Software without
+ | restriction, including without limitation the rights to use,
+ | copy, modify, merge, publish, distribute, sublicense, and/or
+ | sell copies of the Software, and to permit persons to whom the
+ | Software is furnished to do so, subject to the following
+ | conditions:
|
- | The above copyright notice and this permission notice shall be included in
- | all copies or substantial portions of the Software.
+ | The above copyright notice and this permission notice shall be
+ | included in all copies or substantial portions of the Software.
|
- | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- | THE SOFTWARE.
+ | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ | OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ | NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ | HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ | WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ | FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ | OTHER DEALINGS IN THE SOFTWARE.
+-->
<xsl:stylesheet version="1.0"
<xsl:otherwise>
<xsl:call-template name="sqrt">
- <xsl:with-param name="n" select="$n"/>
- <xsl:with-param name="try" select="$try - (($try * $try - $n) div (2 * $try))"/>
- <xsl:with-param name="iter" select="$iter - 1"/>
+ <xsl:with-param name="n"
+ select="$n"/>
+ <xsl:with-param name="try"
+ select="$try - (($try * $try - $n) div (2 * $try))"/>
+ <xsl:with-param name="iter"
+ select="$iter - 1"/>
</xsl:call-template>
</xsl:otherwise>
<xsl:param name="degrees" />
<!-- Used internally to convert degrees to radians. -->
- <xsl:param name="radians" select="$degrees * $PI div 180" />
+ <xsl:param name="rad" select="$degrees * $PI div 180" />
<!-- Maximum number of iterations (decreases recursively). -->
<xsl:param name="iter" select="31" />
<!-- Collects the value of all the terms. -->
<xsl:param name="result" select="1" />
<xsl:choose>
<xsl:when test="$iter &gt; 2">
<xsl:call-template name="sine">
- <xsl:with-param name="radians" select="$radians" />
- <xsl:with-param name="iter" select="$iter - 2" />
- <xsl:with-param name="result" select="1 - ((($radians * $radians) div (($iter - 1) * $iter)) * $result)" />
+ <xsl:with-param name="rad"
+ select="$rad" />
+ <xsl:with-param name="iter"
+ select="$iter - 2" />
+ <xsl:with-param name="result"
+ select="1 - ((($rad * $rad) div (($iter - 1) * $iter)) * $result)" />
</xsl:call-template>
</xsl:when>
- <xsl:otherwise><xsl:value-of select="$radians * $result" /></xsl:otherwise>
+ <xsl:otherwise><xsl:value-of select="$rad * $result" /></xsl:otherwise>
</xsl:choose>
</xsl:template>
<!-- Calculates the normalized arc tangent form. -->
<xsl:template name="atan2">
<xsl:param name="y" />
<xsl:param name="x" />
- <!-- http://lists.apple.com/archives/PerfOptimization-dev/2005/Jan/msg00051.html -->
- <!-- http://permalink.gmane.org/gmane.text.xml.xslt.extensions/840 -->
+ <!--
+ | http://lists.apple.com/archives/PerfOptimization-dev/2005/Jan/msg00051.html
+ ! http://permalink.gmane.org/gmane.text.xml.xslt.extensions/840
+ +-->
<xsl:variable name="PIBY2" select="$PI div 2.0"/>
<xsl:choose>
</xsl:when>
<xsl:otherwise>
- <xsl:variable name="z" select="$y div $x"/>
- <xsl:variable name="absZ" select="($z &gt;= 0) * $z - not($z &gt;= 0) * $z"/>
+ <xsl:variable name="z"
+ select="$y div $x"/>
+ <xsl:variable name="absZ"
+ select="($z &gt;= 0) * $z - not($z &gt;= 0) * $z"/>
<xsl:choose>
<xsl:when test="($absZ &lt; 1.0)">
</xsl:when>
<xsl:otherwise>
- <xsl:variable name="f2Z" select="$PIBY2 - ($z div ($z*$z + 0.28))"/>
+ <xsl:variable name="f2Z"
+ select="$PIBY2 - ($z div ($z*$z + 0.28))"/>
<xsl:choose>
<xsl:when test="($y &lt; 0.0)">
<xsl:variable name="X" select="substring( $hex, 1, 1 )" />
<xsl:variable name="Y" select="substring( $hex, 2, 1 )" />
- <xsl:variable name="Xval" select="string-length(substring-before($digits,$X))" />
- <xsl:variable name="Yval" select="string-length(substring-before($digits,$Y))" />
-
+ <xsl:variable name="Xval"
+ select="string-length(substring-before($digits,$X))" />
+ <xsl:variable name="Yval"
+ select="string-length(substring-before($digits,$Y))" />
<xsl:value-of select="16 * $Xval + $Yval" />
</xsl:template>
xml/proposal.xml
<?xml version="1.0" encoding="utf-8"?>
-<?xml-stylesheet type="text/xsl" href="common.xsl" ?>
+<?xml-stylesheet type="text/xsl" href="common.xsl"?>
<policy>
<summary>
<synopsis>
<paragraph>
- We have the right to protect our private and family life. Wanting privacy is not a suspicious activity. Government programmes track all electronic and phone communications: an excessively <xref id="4">expensive</xref> intrusion. The funds allotted to such programmes should be directed to building secure digital infrastructures, not surveillance.
+ We have the right to protect our private and family life.
+ Wanting privacy is not a suspicious activity. Government
+ programmes track all electronic and phone communications:
+ an excessively <xref id="4">expensive</xref> intrusion.
+ The funds allotted to such programmes should be directed
+ to building secure digital infrastructures, not surveillance.
</paragraph>
</synopsis>
<title>Protection of Privacy &amp; Civil Rights</title>
<paragraph>
- The expansion of our civil rights and protection of our freedom is the primary motivation for this act.
+ The expansion of our civil rights and protection of our
+ freedom is the primary motivation for this act.
</paragraph>
<sections>
<section>
<title>Data Protection &amp; Surveillance</title>
<content>
<paragraph>
- The threat posed by unlawful and excessive <xref id="1">surveillance</xref> measures, imposed on us by governments both foreign and domestic, whether in response to <xref id="2">terrorism</xref> or other threats is grave. There is an immediate need for action to redress the balance and restore our <xref id="3">privacy</xref>.
+ The threat posed by unlawful and excessive
+ <xref id="1">surveillance</xref> measures, imposed on
+ us by governments both foreign and domestic, whether
+ in response to <xref id="2">terrorism</xref> or other
+ threats is grave. There is an immediate need for
+ action to redress the balance and restore our
+ <xref id="3">privacy</xref>.
</paragraph>
</content>
</section>
<section>
<title>Data Retention</title>
<content>
<paragraph>
- Regarding the <xref id="6">collection</xref> of <xref id="4">personal information</xref>, <xref id="5">citizens</xref> have a right to know the:
+ Regarding the <xref id="6">collection</xref> of
+ <xref id="4">personal information</xref>,
+ <xref id="5">citizens</xref> have a right to know
+ the:
<list>
<item>rules that govern collection;</item>
<content>
<paragraph>
- Cameras monitor movement of people and vehicles in public spaces. Facial tracking combined with secondary information sources erodes privacy without significantly reducing crime rates. Police personnel will transition from passive monitoring to active patrolling.
+ Cameras monitor movement of people and vehicles in
+ public spaces. Facial tracking combined with
+ secondary information sources erodes privacy without
+ significantly reducing crime rates. Police personnel
+ will transition from passive monitoring to active
+ patrolling.
</paragraph>
</content>
xml/resources.xml
<title>Executive Summary</title>
<paragraph>
- The estimated budget to ensure the protection of privacy in <xref id="1">digital communications</xref> for the 2014-2015 fiscal year is $1.4 million. The majority of these funds are allocated to employee salaries and benefits. As this policy takes effect, the employee count is expected to halve by 2016.
+ The estimated budget to ensure the protection of privacy in
+ <xref id="1">digital communications</xref> for the
+ 2014-2015 fiscal year is $1.4 million. The majority of
+ these funds are allocated to employee salaries and
+ benefits. As this policy takes effect, the employee count
+ is expected to halve by 2016.
</paragraph>
<sections>
<section>
<title>Salaries and Employee Benefits</title>
<content>
<paragraph>
- Employees are paid to contact <xref id="2">Internet Service Providers</xref>, <xref id="3">Telecom Service Providers</xref>, <xref id="4">government agencies</xref>, <xref id="5">hospitals</xref>, and <xref id="6">financial institutions</xref>. The information collected in surveys provides a transparent means to disclose the safety of our citizens' private data. Once the surveys are written and contact lists assembled, the surveys can be dispatched automatically, reducing the number of full-time employees required.
+ Employees are paid to contact <xref id="2">Internet
+ Service Providers</xref>, <xref id="3">Telecom
+ Service Providers</xref>, <xref id="4">government
+ agencies</xref>, <xref id="5">hospitals</xref>, and
+ <xref id="6">financial institutions</xref>. The
+ information collected in surveys provides a
+ transparent means to disclose the safety of our
+ citizens' private data. Once the surveys are
+ written and contact lists assembled, the surveys
+ can be dispatched automatically, reducing the
+ number of full-time employees required.
</paragraph>
</content>
</section>
<section>
<title>Professional and Special Services</title>
<content>
<paragraph>
- Security experts in various fields are necessary to ascertain data privacy. These individuals are highly-trained in <xref id="5">Information Technology</xref>, including: <xref id="6">database vulnerabilities</xref>, <xref id="6">zero-day operating system exploits</xref>, and <xref id="6">social engineering</xref>.
+ Security experts in various fields are necessary to
+ ascertain data privacy. These individuals are
+ highly trained in <xref id="5">Information
+ Technology</xref>, including: <xref id="6">database
+ vulnerabilities</xref>, <xref id="6">zero-day
+ operating system exploits</xref>, and
+ <xref id="6">social engineering</xref>.
</paragraph>
</content>
</section>
<section>
<title>Asset Amortization</title>
<content>
<paragraph>
- The following items (purchased via loans) will be repaid in full within two years, contributing to further reductions in operating expenses: computing devices, peripherals, and software; office furniture; and vehicles.
+ The following items (purchased via loans) will be
+ repaid in full within two years, contributing to
+ further reductions in operating expenses: computing
+ devices, peripherals, and software; office
+ furniture; and vehicles.
</paragraph>
</content>
</section>
<section>
<title>Rentals</title>
<content>
<paragraph>
- Office space is currently being rented near the downtown core. These costs can be reduced by moving the office into urban areas, making use of home offices, and sub-leasing unused areas.
+ Office space is currently being rented near the
+ downtown core. These costs can be reduced by moving
+ the office into urban areas, making use of home
+ offices, and sub-leasing unused areas.
</paragraph>
</content>
xml/summary.xml
<?xml version="1.0" encoding="utf-8"?>
-<?xml-stylesheet type="text/xsl" href="common.xsl" ?>
+<?xml-stylesheet type="text/xsl" href="common.xsl"?>
<policy>
<summary>
<synopsis>
<paragraph>
- We have the right to protect our private and family life. Wanting privacy is not a suspicious activity. Government programmes track all electronic and phone communications: an excessively <xref id="4">expensive</xref> intrusion. The funds allotted to such programmes should be directed to building secure digital infrastructures, not surveillance.
+ We have the right to protect our private and family life.
+ Wanting privacy is not a suspicious activity. Government
+ programmes track all electronic and phone communications:
+ an excessively <xref id="4">expensive</xref> intrusion.
+ The funds allotted to such programmes should be directed
+ to building secure digital infrastructures, not surveillance.
</paragraph>
<paragraph>
- Everyone has the right to private and confidential communication. This requires introducing stronger data protection laws. This act rescinds the authoritarian <xref id="2">decisions</xref> of previous enactments and includes a review of <xref id="3">terrorism legislation</xref>.
+ Everyone has the right to private and confidential communication.
+ This requires introducing stronger data protection laws. This
+ act rescinds the authoritarian <xref id="2">decisions</xref>
+ of previous enactments and includes a review of
+ <xref id="3">terrorism legislation</xref>.
</paragraph>
</synopsis>
<implication>
<paragraph>
- Without highly secure private data, individuals are at risk of
- <xref id="8">discrimination</xref> by virtue of their membership
- in groups.
+ Without highly secure private data, individuals are at risk
+ of <xref id="8">discrimination</xref> by virtue of their
+ membership in groups.
</paragraph>
</implication>
<implication>
<paragraph>
Surveillance data is susceptible to <xref id="9">theft</xref>.
</paragraph>
</implication>
<implication>
<paragraph>
- Ensure the rights to <xref id="10">freedom of assembly</xref> and
- <xref id="11">freedom of association</xref>.
+ Ensure the rights to <xref id="10">freedom of assembly</xref>
+ and <xref id="11">freedom of association</xref>.
</paragraph>
</implication>
<implication>
<paragraph>
- Promote anonymity for seeking or communicating sensitive health-related
- information.
+ Promote anonymity for seeking or communicating sensitive
+ health-related information.
</paragraph>
</implication>
<implication>
<paragraph>
Offline and online rights should be treated equally.
- [<xref id="7">§ Article 12 of the Universal Declaration of Human
- Rights</xref>]
+ [<xref id="7">§ Article 12 of the Universal Declaration of
+ Human Rights</xref>]
</paragraph>
</implication>
xml/support.xml
<?xml version="1.0" encoding="utf-8"?>
-<?xml-stylesheet type="text/xsl" href="common.xsl" ?>
+<?xml-stylesheet type="text/xsl" href="common.xsl"?>
<policy>
<summary>
<support>
<paragraph>
- The <xref id="1">Heartbleed bug</xref>, reported in late 2013, allows
- remote attackers to obtain sensitive information from unprotected
- computer systems. The NSA is <xref id="2">rumoured</xref> to have used
- this bug to advance its own intelligence operations.
+ The <xref id="1">Heartbleed bug</xref>, reported in late
+ 2013, allows remote attackers to obtain sensitive
+ information from unprotected computer systems. The NSA
+ is <xref id="2">rumoured</xref> to have used this bug to
+ advance its own intelligence operations.
</paragraph>
<paragraph>
- In June of 2014, two staff members of a Scarborough hospital were
- reportedly paid by external companies to <xref id="0">leak</xref> the
- contact information for 8,300 patients. The contact information
- included the patient name, phone number, and address. The patients
- were primarily women who became mothers between 2009 and 2013. The data
- was delivered to RESP investment companies, but it could just as
- easily be transferred to people who intimidate or blackmail.
+ In June of 2014, two staff members of a Scarborough hospital
+ were reportedly paid by external companies to
+ <xref id="0">leak</xref> the contact information for 8,300
+ patients. The contact information included the patient name,
+ phone number, and address. The patients were primarily
+ women who became mothers between 2009 and 2013. The data
+ was delivered to RESP investment companies, but it could
+ just as easily be transferred to people who intimidate or
+ blackmail.
</paragraph>
<paragraph>
- Chinese hackers <xref id="3">breached</xref> Google's servers in 2010,
- seeking to identify accounts that had been tagged for surveillance by
- U.S. national security and law enforcement agencies. Similar
- <xref id="4">attacks</xref> against various technology companies, also
- around this time, focused on obtaining information about political
- dissidents. Additional attacks hit companies in <xref id="6">strategic
- industries</xref> where China lags, such as defense companies to
- steal <xref id="7">weapons systems</xref> information.
+ Chinese hackers <xref id="3">breached</xref> Google's servers
+ in 2010, seeking to identify accounts that had been tagged
+ for surveillance by U.S. national security and law
+ enforcement agencies. Similar <xref id="4">attacks</xref>
+ against various technology companies, also around this time,
+ focused on obtaining information about political dissidents.
+ Additional attacks hit companies in <xref id="6">strategic
+ industries</xref> where China lags, such as defense companies
+ to steal <xref id="7">weapons systems</xref> information.
</paragraph>
<paragraph>
- Surveillance data gathered by the <xref id="8">Five Eyes</xref> is
- purportedly used for counter-terrorism and security. The scope of the
- data acquired by the NSA and similar organizations ensures that the
- information can be used politically as well. Were the data vaults
- breached by countries with sinister motivations, the results could
- be disasterous.
+ Surveillance data gathered by the <xref id="8">Five
+ Eyes</xref> is purportedly used for counter-terrorism and
+ security. The scope of the data acquired by the NSA and
+ similar organizations ensures that the information can be
+ used politically as well. Were the data vaults breached by
+ countries with sinister motivations, the results could be
+ disasterous.
</paragraph>
</support>
</implication>
+
<related>
<discuss id="1" />
xml/tex/.gitignore
manual.pdf
manual.tuc
+account.xml.vimout
+chart.xsl.vimout
+common.xsl.vimout
+discuss.xml.vimout
+edit-discuss-flag.css.vimout
+hypothesis.xml.vimout
+index.xml.vimout
+math.xsl.vimout
+proposal.xml.vimout
+related.css.vimout
+resources.xml.vimout
+summary.xml.vimout
+support.xml.vimout
+manual.log
xml/tex/ch-01.tex
\startitemize
\startitem
- Only voters who have registered with the RA may vote.
+ only voters who have registered with the RA may vote;
\stopitem
\startitem
- Voters cannot vote multiple times on an item.
+ voters cannot vote multiple times on an item;
\stopitem
\startitem
- Voters cannot replace votes.
+ voters cannot replace votes;
\stopitem
\startitem
- Voters may change how they voted on an item.
+ voters may change how they voted on an item; and
\stopitem
\startitem
- Third-parties cannot change the tabulation outcome.
+ third-parties cannot change the tabulation outcome.
\stopitem
\stopitemize
xml/tex/ch-03.tex
\startchapter[title={Summary}]
- \WPquote{A rationalist is simply someone for whom it is more important to learn than to be proved right; someone who is willing to learn from others — not by simply taking over another's opinions, but by gladly allowing others to criticize his ideas and by gladly criticizing the ideas of others. The emphasis here is on the idea of criticism or, to be more precise, \it{critical discussion}.}
- {Karl Popper}{All Life is Problem Solving}
+ \WPquote{If one man can be allowed to determine for himself what is
+ law, every man can. That means first chaos, then tyranny. Legal
+ process is an essential part of the democratic process.}
+ {Felix Frankfurter}{United States v. United Mine Workers}
\startsection[title={\WPui{}}]
xml/tex/ch-04.tex
\startchapter[title={Proposal}]
- \WPquote{}
- {Robert David Steele}{The Open-Source Everything Manifesto:
- Transparency, Truth, and Trust}
+ \WPquote{When distant and unfamiliar and complex things are
+ communicated to great masses of people, the truth suffers a
+ considerable and often a radical distortion. The complex is made over
+ into the simple, the hypothetical into the dogmatic, and the
+ relative into the absolute.}
+ {Walter Lippmann}{The Public Philosophy}
\startsection[title={\WPui{}}]
xml/tex/ch-05.tex
\startchapter[title={Hypothesis}]
- \WPquote{}
- {Robert David Steele}{The Open-Source Everything Manifesto:
- Transparency, Truth, and Trust}
+ \WPquote{Truth in science can be defined as the working hypothesis
+ best suited to open the way to the next better one.}
+ {Konrad Lorenz}{On Aggression}
\startsection[title={\WPui{}}]
\placefigure[here]{Hypothesis}{
\externalfigure[hypothesis.svg][
]
}
\stopsection
\stopchapter
+
+% \WPquote{It does not make any difference how beautiful your guess is.
+% It does not make any difference how smart you are, who made the
+% guess, or what his name is \emdash{} if it disagrees with experiment,
+% it is wrong.}
+% {Richard Feynman}{Seeking New Laws}
xml/tex/ch-06.tex
\startchapter[title={Resources}]
- \WPquote{There is no such thing as a free lunch.}
- {Friedrich August von Hayek}{The Fatal Conceit: The Errors of Socialism}
+ \WPquote{There ain't no such thing as a free lunch.}
+ { Robert A. Heinlein}{The Moon Is a Harsh Mistress }
\startsection[title={\WPui{}}]
\placefigure[here]{Resources}{
\externalfigure[resources.svg][
]
}
\stopsection
\stopchapter
-
-% There ain't no such thing as a free lunch.
-% Robert A. Heinlein, The Moon Is a Harsh Mistress
-
-
xml/tex/ch-07.tex
\startchapter[title={Discuss}]
- \WPquote{A rationalist is simply someone for whom it is more important to learn than to be proved right; someone who is willing to learn from others — not by simply taking over another's opinions, but by gladly allowing others to criticize his ideas and by gladly criticizing the ideas of others. The emphasis here is on the idea of criticism or, to be more precise, \it{critical discussion}.}
+ \WPquote{A rationalist is simply someone for whom it is more
+ important to learn than to be proved right; someone who is willing to
+ learn from others \emdash{} not by simply taking over another's
+ opinions, but by gladly allowing others to criticize his ideas and by
+ gladly criticizing the ideas of others. The emphasis here is on the
+ idea of criticism or, to be more precise, \it{critical discussion}.}
{Karl Popper}{All Life is Problem Solving}
xml/tex/ch-08.tex
\startchapter[title={Support}]
- \WPquote{}
- {Robert David Steele}{The Open-Source Everything Manifesto:
- Transparency, Truth, and Trust}
+ \WPquote{If those in charge of our society \emdash{} politicians,
+ corporate executives, and owners of press and television \emdash{}
+ can dominate our ideas, they will be secure in their power. They will
+ not need soldiers patrolling the streets. We will control ourselves.}
+ {Howard Zinn}{Declarations of Independence: Cross-Examining American
+ Ideology}
\startsection[title={\WPui{}}]
xml/tex/ch-09.tex
+\startchapter[title={Account}]
+ \WPquote{To minimize suffering and to maximize security were natural
+ and proper ends of society and Cæsar. But then they became the only
+ ends, somehow, and the only basis of law \emdash{} a perversion.
+ Inevitably, then, in seeking only them, we found only their
+ opposites: maximum suffering and minimum security.}
+ {Walter Miller Jr.}{A Canticle for Leibowitz}
+
+ \startsection[title={\WPui{}}]
+ \placefigure[here]{Account}{
+ \externalfigure[account.svg][
+ ]
+ }
+ \stopsection
+
+\stopchapter
+
xml/tex/ch-10.tex
+\startchapter[title={XML Source}]
+ \WPquote{Value your freedom or you will lose it, teaches history.
+ \quote{Don't bother us with politics,} respond those who don't want
+ to learn.}
+ {Richard Stallman}{Linux, GNU, and Freedom}
+
+ \startsection[title=Overview]
+ The XML source code forms the basis for communications protocols.
+ No XML Schema Definitions were developed at the time of writing.
+ \stopsection
+
+ \startsection[title=Home]
+ \typeXMLfile{../index.xml}
+ \stopsection
+
+ \startsection[title=Summary]
+ \typeXMLfile{../summary.xml}
+ \stopsection
+
+ \startsection[title=Proposal]
+ \typeXMLfile{../proposal.xml}
+ \stopsection
+
+ \startsection[title=Hypothesis]
+ \typeXMLfile{../hypothesis.xml}
+ \stopsection
+
+ \startsection[title=Resources]
+ \typeXMLfile{../resources.xml}
+ \stopsection
+
+ \startsection[title=Discuss]
+ \typeXMLfile{../discuss.xml}
+ \stopsection
+
+ \startsection[title=Support]
+ \typeXMLfile{../support.xml}
+ \stopsection
+
+ \startsection[title=Account]
+ \typeXMLfile{../account.xml}
+ \stopsection
+\stopchapter
+
xml/tex/ch-11.tex
+\startchapter[title={XSL Source}]
+ \WPquote{I think Open Source is the right thing to do the same way I
+ believe science is better than alchemy. Like science, Open Source
+ allows people to build on a solid base of previous knowledge, without
+ some silly hiding.}
+ {Linus Torvalds}{Why I \quote{Absolutely Love} GPL Version 2}
+
+ \startsection[title=Overview]
+ The XSL source code provides a simple transformation applied to
+ all XML source files. The transformation preserves the document
+ structure by converting the XML elements into DIV elements.
+ The XML element name becomes the DIV element class attribute name.
+ \stopsection
+
+ \startsection[title=Common]
+ The main XSL template includes JavaScript to inject a CSS file.
+ The CSS filename is dynamically obtained from the URL. This allows
+ each XML file to be laid out while the XSL code remains generic.
+ \\
+ \typeXSLfile{../common.xsl}
+ \stopsection
+
+ \startsection[title={Pie Chart}]
+ The pie chart on the resources page is rendered as a client-side
+ SVG element using XSLT 1.0.
+ \\
+ \typeXSLfile{../chart.xsl}
+ \stopsection
+
+ \startsection[title=Math]
+ The math stylesheet provides supporting functions required to
+ render the pie chart and select wedge colours from a given
+ base colour.
+ \\
+ \typeXSLfile{../math.xsl}
+ \stopsection
+\stopchapter
+
xml/tex/ch-12.tex
+\startchapter[title={CSS Source}]
+ \WPquote{However, when we make small design adjustments by adding
+ extra {\tt{<div>}} tags or {\tt{class}} attributes, then alter the CSS to
+ take advantage of those markup changes, we confuse the concept of
+ independent structure and presentation.}
+ {Douglas Bowman}{Are they really separated?}
+
+ \startsection[title=Overview]
+ The CSS source code provides the layout for the DIV-structured
+ XHTML page. For the most part, the CSS is unremarkable. The
+ addition of the flex specification, however, allows control
+ over the element presentation order. This goes a fair way to
+ decoupling the XML content from its XHTML presentation.
+ \stopsection
+
+ \startsection[title={Flex}]
+ \typeCSSfile{../related.css}
+ \stopsection
+
+ \startsection[title={Order}]
+ \typeCSSfile{../edit-discuss-flag.css}
+ \stopsection
+\stopchapter
+
xml/tex/manual.tex
\setuppapersize[letter]
+\usemodule[vim]
+\definevimtyping[XML][
+ syntax=xml,
+ strip=yes,
+ lines=split,]
+\definevimtyping[XSL][
+ syntax=xslt,
+ strip=yes,
+ lines=split,]
+\definevimtyping[CSS][
+ syntax=css,
+ strip=yes,
+ lines=split,]
+
\input constants.tex
\input style.tex
\input ch-07.tex
\input ch-08.tex
+ \input ch-09.tex
+ \input ch-10.tex
+ \input ch-11.tex
+ \input ch-12.tex
\stopbodymatter
\startbackmatter
xml/tex/screens/.gitignore
summary.pdf
support.pdf
+m_k_i_v_account.svg.pdf
xml/tex/style/fonts.tex
\setupbodyfont[EventFont]
-\definefont[ChapterFont][SansBold sa 2.5]
\definefont[SectionFont][SansBold sa 1.5]
\definefont[SubSectionFont][SansBold sa 1.25]
+\definefont[ChapterNumberFont][SansBold sa 10]
\setbreakpoints[compound]
\setupalign[hz,hanging,nothyphenated]
\setuptolerance[horizontal,stretch,tolerant]
\definefontfeature[default][default][expansion=quality]
+
+\definefontsize[e]
+\setupbodyfontenvironment[default][e=6.5]
+\setupbodyfontenvironment[default][d=3.5]
+
xml/tex/style/headings.tex
]
+\startMPinclusions
+ numeric ChapterPageDone[];
+\stopMPinclusions
+
+% Draw a thick bar along the side of each chapter page.
+\startuseMPgraphic{chapterbackground}
+ StartPage;
+ n := \somenamedheadnumber{chapter}{current};
+ width := BackSpace;
+
+ if n > 0 :
+ if unknown ChapterPageDone[n] :
+ fill (0,0) -- (width,0) -- (width, PaperHeight) -- (0, PaperHeight) -- cycle
+ withcolor \MPcolor{black};
+ ChapterPageDone[n] := 1 ;
+ fi;
+ fi;
+ StopPage;
+\stopuseMPgraphic
+
+%\definecolor[ChapterNumberColour][h=A1C436]
+\definecolor[ChapterNumberColour][white]
+
+\defineoverlay[chapterbackground][\useMPgraphic{chapterbackground}]
+\setupbackgrounds[page][background=chapterbackground]
+
+\define[1]\WPchapternumber{\inmargin{\ss{\bfd{\color[ChapterNumberColour]{#1}}}}}
+
+\define[1]\WPchaptertitle{%
+ \framed[
+ frame=off,
+ width=\makeupwidth,
+ height=\textheight,
+ align=flushright,
+ ]{\ss{\bfe{#1}}\vfill{}}
+}
+
\setuphead[chapter][
- style=ChapterFont,
+ style=ChapterNumberFont,
after=\pagebreak,
footer=empty,
+ deeptextcommand=\WPchaptertitle,
+ deepnumbercommand=\WPchapternumber,
]
Delta595 lines added, 253 lines removed, 342-line increase