Commit fb8d72ac authored by Bakaniko's avatar Bakaniko
Browse files

update cours OSGeo

parent 302e5c00
Pipeline #358596 passed with stages
in 1 minute and 41 seconds
This diff is collapsed.
This diff is collapsed.
<!DOCTYPE html>
<html lang="fr" xml:lang="fr">
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<title>5 La communauté OSGeo | L’OSGeo et les logiciels libres en géomatique</title>
<meta name="description" content="This is a list of informations about FOSS4G, what it is, what is free software, licences, the OSGeo foundation for teaching purposes." />
<meta name="generator" content="bookdown 0.19 and GitBook 2.6.7" />
<meta property="og:title" content="5 La communauté OSGeo | L’OSGeo et les logiciels libres en géomatique" />
<meta property="og:type" content="book" />
<meta property="og:description" content="This is a list of informations about FOSS4G, what it is, what is free software, licences, the OSGeo foundation for teaching purposes." />
<meta name="twitter:card" content="summary" />
<meta name="twitter:title" content="5 La communauté OSGeo | L’OSGeo et les logiciels libres en géomatique" />
<meta name="twitter:description" content="This is a list of informations about FOSS4G, what it is, what is free software, licences, the OSGeo foundation for teaching purposes." />
<meta name="author" content="Nicolas Roelandt" />
<meta name="date" content="2020-11-03" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-status-bar-style" content="black" />
<link rel="prev" href="les-logiciels-libres-en-géomatique.html"/>
<link rel="next" href="bibliographie.html"/>
<script src="libs/jquery-2.2.3/jquery.min.js"></script>
<link href="libs/gitbook-2.6.7/css/style.css" rel="stylesheet" />
<link href="libs/gitbook-2.6.7/css/plugin-table.css" rel="stylesheet" />
<link href="libs/gitbook-2.6.7/css/plugin-bookdown.css" rel="stylesheet" />
<link href="libs/gitbook-2.6.7/css/plugin-highlight.css" rel="stylesheet" />
<link href="libs/gitbook-2.6.7/css/plugin-search.css" rel="stylesheet" />
<link href="libs/gitbook-2.6.7/css/plugin-fontsettings.css" rel="stylesheet" />
<link href="libs/gitbook-2.6.7/css/plugin-clipboard.css" rel="stylesheet" />
<style type="text/css">
a.sourceLine { display: inline-block; line-height: 1.25; }
a.sourceLine { pointer-events: none; color: inherit; text-decoration: inherit; }
a.sourceLine:empty { height: 1.2em; }
.sourceCode { overflow: visible; }
code.sourceCode { white-space: pre; position: relative; }
pre.sourceCode { margin: 0; }
@media screen {
div.sourceCode { overflow: auto; }
}
@media print {
code.sourceCode { white-space: pre-wrap; }
a.sourceLine { text-indent: -1em; padding-left: 1em; }
}
pre.numberSource a.sourceLine
{ position: relative; left: -4em; }
pre.numberSource a.sourceLine::before
{ content: attr(data-line-number);
position: relative; left: -1em; text-align: right; vertical-align: baseline;
border: none; pointer-events: all; display: inline-block;
-webkit-touch-callout: none; -webkit-user-select: none;
-khtml-user-select: none; -moz-user-select: none;
-ms-user-select: none; user-select: none;
padding: 0 4px; width: 4em;
color: #aaaaaa;
}
pre.numberSource { margin-left: 3em; border-left: 1px solid #aaaaaa; padding-left: 4px; }
div.sourceCode
{ }
@media screen {
a.sourceLine::before { text-decoration: underline; }
}
code span.al { color: #ff0000; font-weight: bold; } /* Alert */
code span.an { color: #60a0b0; font-weight: bold; font-style: italic; } /* Annotation */
code span.at { color: #7d9029; } /* Attribute */
code span.bn { color: #40a070; } /* BaseN */
code span.bu { } /* BuiltIn */
code span.cf { color: #007020; font-weight: bold; } /* ControlFlow */
code span.ch { color: #4070a0; } /* Char */
code span.cn { color: #880000; } /* Constant */
code span.co { color: #60a0b0; font-style: italic; } /* Comment */
code span.cv { color: #60a0b0; font-weight: bold; font-style: italic; } /* CommentVar */
code span.do { color: #ba2121; font-style: italic; } /* Documentation */
code span.dt { color: #902000; } /* DataType */
code span.dv { color: #40a070; } /* DecVal */
code span.er { color: #ff0000; font-weight: bold; } /* Error */
code span.ex { } /* Extension */
code span.fl { color: #40a070; } /* Float */
code span.fu { color: #06287e; } /* Function */
code span.im { } /* Import */
code span.in { color: #60a0b0; font-weight: bold; font-style: italic; } /* Information */
code span.kw { color: #007020; font-weight: bold; } /* Keyword */
code span.op { color: #666666; } /* Operator */
code span.ot { color: #007020; } /* Other */
code span.pp { color: #bc7a00; } /* Preprocessor */
code span.sc { color: #4070a0; } /* SpecialChar */
code span.ss { color: #bb6688; } /* SpecialString */
code span.st { color: #4070a0; } /* String */
code span.va { color: #19177c; } /* Variable */
code span.vs { color: #4070a0; } /* VerbatimString */
code span.wa { color: #60a0b0; font-weight: bold; font-style: italic; } /* Warning */
</style>
<link rel="stylesheet" href="style.css" type="text/css" />
</head>
<body>
<div class="book without-animation with-summary font-size-2 font-family-1" data-basepath=".">
<div class="book-summary">
<nav role="navigation">
<ul class="summary">
<li><a href="./">Tour d'horizon des logiciels libres en géomatique</a></li>
<li class="divider"></li>
<li class="chapter" data-level="1" data-path="index.html"><a href="index.html"><i class="fa fa-check"></i><b>1</b> Introduction</a><ul>
<li class="chapter" data-level="1.1" data-path="index.html"><a href="index.html#a-propos-de-ce-document"><i class="fa fa-check"></i><b>1.1</b> A propos de ce document</a><ul>
<li class="chapter" data-level="1.1.1" data-path="index.html"><a href="index.html#licence"><i class="fa fa-check"></i><b>1.1.1</b> Licence</a></li>
<li class="chapter" data-level="1.1.2" data-path="index.html"><a href="index.html#création"><i class="fa fa-check"></i><b>1.1.2</b> Création</a></li>
</ul></li>
</ul></li>
<li class="chapter" data-level="2" data-path="logiciels-libres.html"><a href="logiciels-libres.html"><i class="fa fa-check"></i><b>2</b> Logiciels libres</a><ul>
<li class="chapter" data-level="2.1" data-path="logiciels-libres.html"><a href="logiciels-libres.html#logiciel-libre-et-free-software-foundation"><i class="fa fa-check"></i><b>2.1</b> Logiciel libre et Free Software Foundation</a></li>
<li class="chapter" data-level="2.2" data-path="logiciels-libres.html"><a href="logiciels-libres.html#open-source"><i class="fa fa-check"></i><b>2.2</b> Open Source</a></li>
<li class="chapter" data-level="2.3" data-path="logiciels-libres.html"><a href="logiciels-libres.html#bénéfices-des-logiciels-libres"><i class="fa fa-check"></i><b>2.3</b> Bénéfices des logiciels libres</a></li>
</ul></li>
<li class="chapter" data-level="3" data-path="licences.html"><a href="licences.html"><i class="fa fa-check"></i><b>3</b> Licences</a><ul>
<li class="chapter" data-level="3.1" data-path="licences.html"><a href="licences.html#quest-ce-quune-licence"><i class="fa fa-check"></i><b>3.1</b> Qu’est-ce qu’une licence</a></li>
<li class="chapter" data-level="3.2" data-path="licences.html"><a href="licences.html#licences-propriétaires"><i class="fa fa-check"></i><b>3.2</b> Licences propriétaires</a></li>
<li class="chapter" data-level="3.3" data-path="licences.html"><a href="licences.html#licences-libres"><i class="fa fa-check"></i><b>3.3</b> Licences libres</a></li>
</ul></li>
<li class="chapter" data-level="4" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html"><i class="fa fa-check"></i><b>4</b> Les logiciels libres en géomatique</a><ul>
<li class="chapter" data-level="4.1" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#sig-bureautiques"><i class="fa fa-check"></i><b>4.1</b> SIG bureautiques</a></li>
<li class="chapter" data-level="4.2" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#serveurs"><i class="fa fa-check"></i><b>4.2</b> Serveurs</a><ul>
<li class="chapter" data-level="4.2.1" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#services-web"><i class="fa fa-check"></i><b>4.2.1</b> Services web</a></li>
<li class="chapter" data-level="4.2.2" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#stockage"><i class="fa fa-check"></i><b>4.2.2</b> Stockage</a></li>
<li class="chapter" data-level="4.2.3" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#télédétection"><i class="fa fa-check"></i><b>4.2.3</b> Télédétection</a></li>
</ul></li>
<li class="chapter" data-level="4.3" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#traitement-de-données"><i class="fa fa-check"></i><b>4.3</b> Traitement de données</a><ul>
<li class="chapter" data-level="4.3.1" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#python"><i class="fa fa-check"></i><b>4.3.1</b> Python</a></li>
<li class="chapter" data-level="4.3.2" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#r"><i class="fa fa-check"></i><b>4.3.2</b> R</a></li>
</ul></li>
<li class="chapter" data-level="4.4" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#publication-géoportails"><i class="fa fa-check"></i><b>4.4</b> Publication / Géoportails</a></li>
<li class="chapter" data-level="4.5" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#cataloguage-gestion-de-contenu"><i class="fa fa-check"></i><b>4.5</b> Cataloguage / Gestion de contenu</a></li>
<li class="chapter" data-level="4.6" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#briques-logicielles-de-bas-niveau"><i class="fa fa-check"></i><b>4.6</b> Briques logicielles de bas niveau</a><ul>
<li class="chapter" data-level="4.6.1" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#prøj"><i class="fa fa-check"></i><b>4.6.1</b> PRØJ</a></li>
<li class="chapter" data-level="4.6.2" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#gdalogr"><i class="fa fa-check"></i><b>4.6.2</b> GDAL/OGR</a></li>
<li class="chapter" data-level="4.6.3" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#jts"><i class="fa fa-check"></i><b>4.6.3</b> JTS</a></li>
<li class="chapter" data-level="4.6.4" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#geos"><i class="fa fa-check"></i><b>4.6.4</b> GEOS</a></li>
</ul></li>
<li class="chapter" data-level="4.7" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#standards"><i class="fa fa-check"></i><b>4.7</b> Standards</a><ul>
<li class="chapter" data-level="4.7.1" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#fichiers"><i class="fa fa-check"></i><b>4.7.1</b> Fichiers</a></li>
<li class="chapter" data-level="4.7.2" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#standards-de-flux"><i class="fa fa-check"></i><b>4.7.2</b> Standards de flux</a></li>
<li class="chapter" data-level="4.7.3" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#standards-de-métadonnées"><i class="fa fa-check"></i><b>4.7.3</b> Standards de métadonnées</a></li>
</ul></li>
<li class="chapter" data-level="4.8" data-path="les-logiciels-libres-en-géomatique.html"><a href="les-logiciels-libres-en-géomatique.html#aller-plus-loin"><i class="fa fa-check"></i><b>4.8</b> Aller plus loin</a></li>
</ul></li>
<li class="chapter" data-level="5" data-path="la-communauté-osgeo.html"><a href="la-communauté-osgeo.html"><i class="fa fa-check"></i><b>5</b> La communauté OSGeo</a><ul>
<li class="chapter" data-level="5.1" data-path="la-communauté-osgeo.html"><a href="la-communauté-osgeo.html#la-fondation-osgeo"><i class="fa fa-check"></i><b>5.1</b> La fondation OSGeo</a></li>
<li class="chapter" data-level="5.2" data-path="la-communauté-osgeo.html"><a href="la-communauté-osgeo.html#actions"><i class="fa fa-check"></i><b>5.2</b> Actions</a></li>
<li class="chapter" data-level="5.3" data-path="la-communauté-osgeo.html"><a href="la-communauté-osgeo.html#organisation"><i class="fa fa-check"></i><b>5.3</b> Organisation</a></li>
<li class="chapter" data-level="5.4" data-path="la-communauté-osgeo.html"><a href="la-communauté-osgeo.html#osgeo-fr"><i class="fa fa-check"></i><b>5.4</b> OSGeo-fr</a><ul>
<li class="chapter" data-level="5.4.1" data-path="la-communauté-osgeo.html"><a href="la-communauté-osgeo.html#lassociation"><i class="fa fa-check"></i><b>5.4.1</b> L’association</a></li>
<li class="chapter" data-level="5.4.2" data-path="la-communauté-osgeo.html"><a href="la-communauté-osgeo.html#les-actions"><i class="fa fa-check"></i><b>5.4.2</b> Les actions</a></li>
</ul></li>
</ul></li>
<li class="chapter" data-level="" data-path="bibliographie.html"><a href="bibliographie.html"><i class="fa fa-check"></i>Bibliographie</a></li>
<li class="divider"></li>
<li><a href="https://github.com/rstudio/bookdown" target="blank">Published with bookdown</a></li>
</ul>
</nav>
</div>
<div class="book-body">
<div class="body-inner">
<div class="book-header" role="navigation">
<h1>
<i class="fa fa-circle-o-notch fa-spin"></i><a href="./">L’OSGeo et les logiciels libres en géomatique</a>
</h1>
</div>
<div class="page-wrapper" tabindex="-1" role="main">
<div class="page-inner">
<section class="normal" id="section-">
<div id="la-communauté-osgeo" class="section level1">
<h1><span class="header-section-number">5</span> La communauté OSGeo</h1>
<p>la communauté des utilisateurs et développeurs de logiciels libres en géomatique
s’est regroupée au sein de la <a href="https://www.osgeo.org/about/">fondation OSGeo</a>.
La fondation a un rôle fédérateur au niveau mondial et dispose de représentations
à des niveaux régionaux ou locaux sous forme de chapitres.</p>
<p>L’association OSGeo-fr notamment en est l’émanation en France et dans la francophonie.</p>
<div id="la-fondation-osgeo" class="section level2">
<h2><span class="header-section-number">5.1</span> La fondation OSGeo</h2>
<div class="figure">
<img src="images/OSGeo_logo.png" alt="Logo de la fondation OSGEO" />
<p class="caption">Logo de la fondation OSGEO</p>
</div>
</div>
<div id="actions" class="section level2">
<h2><span class="header-section-number">5.2</span> Actions</h2>
<ul>
<li>promouvoir les logiciels, les données, les standards et l’éducation libre dans
le domaine de l’information géographique.</li>
<li>animer la communauté et fournir des espaces d’échanges</li>
<li>aider les projets à se développer (infrastructure, conseils)</li>
</ul>
</div>
<div id="organisation" class="section level2">
<h2><span class="header-section-number">5.3</span> Organisation</h2>
<ul>
<li>Fondation internationale</li>
<li>Chapitres régionaux (Europe, Asie, Amérique Latine, etc.)</li>
<li>Chapitres locaux</li>
</ul>
</div>
<div id="osgeo-fr" class="section level2">
<h2><span class="header-section-number">5.4</span> OSGeo-fr</h2>
<div class="figure">
<img src="images/osgeo-fr-logo.png" alt="Logo de l’association OSGeo-fr" />
<p class="caption">Logo de l’association OSGeo-fr</p>
</div>
<div id="lassociation" class="section level3">
<h3><span class="header-section-number">5.4.1</span> L’association</h3>
<p>OSGeo-fr est une association loi 1901 créée pour animer la communauté géospatiale libre francophone.
Elle est constituée de bénévoles, souvent du domaine: développeurs, utilisateurs,</p>
</div>
<div id="les-actions" class="section level3">
<h3><span class="header-section-number">5.4.2</span> Les actions</h3>
<p>Ses actions sont surtout des actions d’animation telle que l’organisation d’événements ou la représentation.</p>
<div id="animation" class="section level4">
<h4><span class="header-section-number">5.4.2.1</span> Animation</h4>
<ul>
<li>FOSS4G-fr</li>
<li>Journées Utilisateurs QGIS</li>
<li>FOSS4G-EU 2017</li>
</ul>
</div>
<div id="représentation" class="section level4">
<h4><span class="header-section-number">5.4.2.2</span> Représentation</h4>
<ul>
<li>Capitole du Libre</li>
<li>Paris OpenSource Summit</li>
<li>GeoDataDays (Afigéo)</li>
<li>Festival International de Géographie</li>
<li>Interventions auprès d’étudiants</li>
</ul>
</div>
</div>
</div>
</div>
</section>
</div>
</div>
</div>
<a href="les-logiciels-libres-en-géomatique.html" class="navigation navigation-prev " aria-label="Previous page"><i class="fa fa-angle-left"></i></a>
<a href="bibliographie.html" class="navigation navigation-next " aria-label="Next page"><i class="fa fa-angle-right"></i></a>
</div>
</div>
<script src="libs/gitbook-2.6.7/js/app.min.js"></script>
<script src="libs/gitbook-2.6.7/js/lunr.js"></script>
<script src="libs/gitbook-2.6.7/js/clipboard.min.js"></script>
<script src="libs/gitbook-2.6.7/js/plugin-search.js"></script>
<script src="libs/gitbook-2.6.7/js/plugin-sharing.js"></script>
<script src="libs/gitbook-2.6.7/js/plugin-fontsettings.js"></script>
<script src="libs/gitbook-2.6.7/js/plugin-bookdown.js"></script>
<script src="libs/gitbook-2.6.7/js/jquery.highlight.js"></script>
<script src="libs/gitbook-2.6.7/js/plugin-clipboard.js"></script>
<script>
gitbook.require(["gitbook"], function(gitbook) {
gitbook.start({
"sharing": {
"github": false,
"facebook": true,
"twitter": true,
"linkedin": false,
"weibo": false,
"instapaper": false,
"vk": false,
"all": ["facebook", "twitter", "linkedin", "weibo", "instapaper"]
},
"fontsettings": {
"theme": "white",
"family": "sans",
"size": 2
},
"edit": {
"link": null,
"text": null
},
"history": {
"link": null,
"text": null
},
"view": {
"link": null,
"text": null
},
"download": ["FOSS4G.pdf", "FOSS4G.epub"],
"toc": {
"collapse": "subsection"
}
});
});
</script>
</body>
</html>
This diff is collapsed.
div.sourceCode {
position: relative;
}
.copy-to-clipboard-button {
position: absolute;
right: 0;
top: 0;
visibility: hidden;
}
.copy-to-clipboard-button:focus {
outline: 0;
}
div.sourceCode:hover > .copy-to-clipboard-button {
visibility: visible;
}
/*!
* clipboard.js v2.0.4
* https://zenorocha.github.io/clipboard.js
*
* Licensed MIT © Zeno Rocha
*/
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.ClipboardJS=e():t.ClipboardJS=e()}(this,function(){return function(n){var o={};function r(t){if(o[t])return o[t].exports;var e=o[t]={i:t,l:!1,exports:{}};return n[t].call(e.exports,e,e.exports,r),e.l=!0,e.exports}return r.m=n,r.c=o,r.d=function(t,e,n){r.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},r.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(n,o,function(t){return e[t]}.bind(null,o));return n},r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,"a",e),e},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.p="",r(r.s=0)}([function(t,e,n){"use strict";var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i=function(){function o(t,e){for(var n=0;n<e.length;n++){var o=e[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(t,o.key,o)}}return function(t,e,n){return e&&o(t.prototype,e),n&&o(t,n),t}}(),a=o(n(1)),c=o(n(3)),u=o(n(4));function o(t){return t&&t.__esModule?t:{default:t}}var l=function(t){function o(t,e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,o);var n=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(o.__proto__||Object.getPrototypeOf(o)).call(this));return n.resolveOptions(e),n.listenClick(t),n}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(o,c.default),i(o,[{key:"resolveOptions",value:function(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};this.action="function"==typeof t.action?t.action:this.defaultAction,this.target="function"==typeof t.target?t.target:this.defaultTarget,this.text="function"==typeof t.text?t.text:this.defaultText,this.container="object"===r(t.container)?t.container:document.body}},{key:"listenClick",value:function(t){var e=this;this.listener=(0,u.default)(t,"click",function(t){return e.onClick(t)})}},{key:"onClick",value:function(t){var e=t.delegateTarget||t.currentTarget;this.clipboardAction&&(this.clipboardAction=null),this.clipboardAction=new a.default({action:this.action(e),target:this.target(e),text:this.text(e),container:this.container,trigger:e,emitter:this})}},{key:"defaultAction",value:function(t){return s("action",t)}},{key:"defaultTarget",value:function(t){var e=s("target",t);if(e)return document.querySelector(e)}},{key:"defaultText",value:function(t){return s("text",t)}},{key:"destroy",value:function(){this.listener.destroy(),this.clipboardAction&&(this.clipboardAction.destroy(),this.clipboardAction=null)}}],[{key:"isSupported",value:function(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:["copy","cut"],e="string"==typeof t?[t]:t,n=!!document.queryCommandSupported;return e.forEach(function(t){n=n&&!!document.queryCommandSupported(t)}),n}}]),o}();function s(t,e){var n="data-clipboard-"+t;if(e.hasAttribute(n))return e.getAttribute(n)}t.exports=l},function(t,e,n){"use strict";var o,r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i=function(){function o(t,e){for(var n=0;n<e.length;n++){var o=e[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(t,o.key,o)}}return function(t,e,n){return e&&o(t.prototype,e),n&&o(t,n),t}}(),a=n(2),c=(o=a)&&o.__esModule?o:{default:o};var u=function(){function e(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),this.resolveOptions(t),this.initSelection()}return i(e,[{key:"resolveOptions",value:function(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};this.action=t.action,this.container=t.container,this.emitter=t.emitter,this.target=t.target,this.text=t.text,this.trigger=t.trigger,this.selectedText=""}},{key:"initSelection",value:function(){this.text?this.selectFake():this.target&&this.selectTarget()}},{key:"selectFake",value:function(){var t=this,e="rtl"==document.documentElement.getAttribute("dir");this.removeFake(),this.fakeHandlerCallback=function(){return t.removeFake()},this.fakeHandler=this.container.addEventListener("click",this.fakeHandlerCallback)||!0,this.fakeElem=document.createElement("textarea"),this.fakeElem.style.fontSize="12pt",this.fakeElem.style.border="0",this.fakeElem.style.padding="0",this.fakeElem.style.margin="0",this.fakeElem.style.position="absolute",this.fakeElem.style[e?"right":"left"]="-9999px";var n=window.pageYOffset||document.documentElement.scrollTop;this.fakeElem.style.top=n+"px",this.fakeElem.setAttribute("readonly",""),this.fakeElem.value=this.text,this.container.appendChild(this.fakeElem),this.selectedText=(0,c.default)(this.fakeElem),this.copyText()}},{key:"removeFake",value:function(){this.fakeHandler&&(this.container.removeEventListener("click",this.fakeHandlerCallback),this.fakeHandler=null,this.fakeHandlerCallback=null),this.fakeElem&&(this.container.removeChild(this.fakeElem),this.fakeElem=null)}},{key:"selectTarget",value:function(){this.selectedText=(0,c.default)(this.target),this.copyText()}},{key:"copyText",value:function(){var e=void 0;try{e=document.execCommand(this.action)}catch(t){e=!1}this.handleResult(e)}},{key:"handleResult",value:function(t){this.emitter.emit(t?"success":"error",{action:this.action,text:this.selectedText,trigger:this.trigger,clearSelection:this.clearSelection.bind(this)})}},{key:"clearSelection",value:function(){this.trigger&&this.trigger.focus(),window.getSelection().removeAllRanges()}},{key:"destroy",value:function(){this.removeFake()}},{key:"action",set:function(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:"copy";if(this._action=t,"copy"!==this._action&&"cut"!==this._action)throw new Error('Invalid "action" value, use either "copy" or "cut"')},get:function(){return this._action}},{key:"target",set:function(t){if(void 0!==t){if(!t||"object"!==(void 0===t?"undefined":r(t))||1!==t.nodeType)throw new Error('Invalid "target" value, use a valid Element');if("copy"===this.action&&t.hasAttribute("disabled"))throw new Error('Invalid "target" attribute. Please use "readonly" instead of "disabled" attribute');if("cut"===this.action&&(t.hasAttribute("readonly")||t.hasAttribute("disabled")))throw new Error('Invalid "target" attribute. You can\'t cut text from elements with "readonly" or "disabled" attributes');this._target=t}},get:function(){return this._target}}]),e}();t.exports=u},function(t,e){t.exports=function(t){var e;if("SELECT"===t.nodeName)t.focus(),e=t.value;else if("INPUT"===t.nodeName||"TEXTAREA"===t.nodeName){var n=t.hasAttribute("readonly");n||t.setAttribute("readonly",""),t.select(),t.setSelectionRange(0,t.value.length),n||t.removeAttribute("readonly"),e=t.value}else{t.hasAttribute("contenteditable")&&t.focus();var o=window.getSelection(),r=document.createRange();r.selectNodeContents(t),o.removeAllRanges(),o.addRange(r),e=o.toString()}return e}},function(t,e){function n(){}n.prototype={on:function(t,e,n){var o=this.e||(this.e={});return(o[t]||(o[t]=[])).push({fn:e,ctx:n}),this},once:function(t,e,n){var o=this;function r(){o.off(t,r),e.apply(n,arguments)}return r._=e,this.on(t,r,n)},emit:function(t){for(var e=[].slice.call(arguments,1),n=((this.e||(this.e={}))[t]||[]).slice(),o=0,r=n.length;o<r;o++)n[o].fn.apply(n[o].ctx,e);return this},off:function(t,e){var n=this.e||(this.e={}),o=n[t],r=[];if(o&&e)for(var i=0,a=o.length;i<a;i++)o[i].fn!==e&&o[i].fn._!==e&&r.push(o[i]);return r.length?n[t]=r:delete n[t],this}},t.exports=n},function(t,e,n){var d=n(5),h=n(6);t.exports=function(t,e,n){if(!t&&!e&&!n)throw new Error("Missing required arguments");if(!d.string(e))throw new TypeError("Second argument must be a String");if(!d.fn(n))throw new TypeError("Third argument must be a Function");if(d.node(t))return s=e,f=n,(l=t).addEventListener(s,f),{destroy:function(){l.removeEventListener(s,f)}};if(d.nodeList(t))return a=t,c=e,u=n,Array.prototype.forEach.call(a,function(t){t.addEventListener(c,u)}),{destroy:function(){Array.prototype.forEach.call(a,function(t){t.removeEventListener(c,u)})}};if(d.string(t))return o=t,r=e,i=n,h(document.body,o,r,i);throw new TypeError("First argument must be a String, HTMLElement, HTMLCollection, or NodeList");var o,r,i,a,c,u,l,s,f}},function(t,n){n.node=function(t){return void 0!==t&&t instanceof HTMLElement&&1===t.nodeType},n.nodeList=function(t){var e=Object.prototype.toString.call(t);return void 0!==t&&("[object NodeList]"===e||"[object HTMLCollection]"===e)&&"length"in t&&(0===t.length||n.node(t[0]))},n.string=function(t){return"string"==typeof t||t instanceof String},n.fn=function(t){return"[object Function]"===Object.prototype.toString.call(t)}},function(t,e,n){var a=n(7);function i(t,e,n,o,r){var i=function(e,n,t,o){return function(t){t.delegateTarget=a(t.target,n),t.delegateTarget&&o.call(e,t)}}.apply(this,arguments);return t.addEventListener(n,i,r),{destroy:function(){t.removeEventListener(n,i,r)}}}t.exports=function(t,e,n,o,r){return"function"==typeof t.addEventListener?i.apply(null,arguments):"function"==typeof n?i.bind(null,document).apply(null,arguments):("string"==typeof t&&(t=document.querySelectorAll(t)),Array.prototype.map.call(t,function(t){return i(t,e,n,o,r)}))}},function(t,e){if("undefined"!=typeof Element&&!Element.prototype.matches){var n=Element.prototype;n.matches=n.matchesSelector||n.mozMatchesSelector||n.msMatchesSelector||n.oMatchesSelector||n.webkitMatchesSelector}t.exports=function(t,e){for(;t&&9!==t.nodeType;){if("function"==typeof t.matches&&t.matches(e))return t;t=t.parentNode}}}])});
......@@ -28,6 +28,18 @@ gitbook.require(["gitbook", "lodash", "jQuery"], function(gitbook, _, $) {
}
});
// add the View button (file view on Github)
var view = config.view;
if (view && view.link) gitbook.toolbar.createButton({
icon: 'fa fa-eye',
label: view.text || 'View Source',
position: 'left',
onClick: function(e) {
e.preventDefault();
window.open(view.link);
}
});
// add the Download button
var down = config.download;
var normalizeDownload = function() {
......@@ -72,7 +84,7 @@ gitbook.require(["gitbook", "lodash", "jQuery"], function(gitbook, _, $) {
if (config.search !== false) info.push('f: Toggle search input ' +
'(use <up>/<down>/Enter in the search input to navigate through search matches; ' +
'press Esc to cancel search)');
gitbook.toolbar.createButton({
if (config.info !== false) gitbook.toolbar.createButton({
icon: 'fa fa-info',
label: 'Information about the toolbar',
position: 'left',
......@@ -85,6 +97,8 @@ gitbook.require(["gitbook", "lodash", "jQuery"], function(gitbook, _, $) {
// highlight the current section in TOC
var href = window.location.pathname;
href = href.substr(href.lastIndexOf('/') + 1);
// accentuated characters need to be decoded (#819)
href = decodeURIComponent(href);
if (href === '') href = 'index.html';
var li = $('a[href^="' + href + location.hash + '"]').parent('li.chapter').first();
var summary = $('ul.summary'), chaps = summary.find('li.chapter');
......
gitbook.require(["gitbook", "jQuery"], function(gitbook, $) {
var copyButton = '<button type="button" class="copy-to-clipboard-button" title="Copy to clipboard" aria-label="Copy to clipboard"><i class="fa fa-copy"></i></button>';
var clipboard;
gitbook.events.bind("page.change", function() {
if (!ClipboardJS.isSupported()) return;
// the page.change event is thrown twice: before and after the page changes
if (clipboard) {
// clipboard is already defined
// we can deduct that we are before page changes
clipboard.destroy(); // destroy the previous events listeners
clipboard = undefined; // reset the clipboard object
return;
}
$(copyButton).prependTo("div.sourceCode");
clipboard = new ClipboardJS(".copy-to-clipboard-button", {
text: function(trigger) {
return trigger.parentNode.textContent;
}
});
});
});
......@@ -96,7 +96,8 @@ gitbook.require(["gitbook", "lodash", "jQuery"], function(gitbook, _, $) {
gitbook.events.bind("start", function(e, config) {
var opts = config.fontsettings;
if (!opts) return;
// Create buttons in toolbar
gitbook.toolbar.createButton({
icon: 'fa fa-font',
......
......@@ -15,7 +15,7 @@ gitbook.require(["gitbook", "lodash", "jQuery"], function(gitbook, _, $) {
'icon': 'fa fa-facebook',
'onClick': function(e) {
e.preventDefault();
window.open("http://www.facebook.com/sharer/sharer.php?s=100&p[url]="+encodeURIComponent(location.href));
window.open("http://www.facebook.com/sharer/sharer.php?u="+encodeURIComponent(location.href));
}
},
'twitter': {
......@@ -23,15 +23,7 @@ gitbook.require(["gitbook", "lodash", "jQuery"], function(gitbook, _, $) {
'icon': 'fa fa-twitter',
'onClick': function(e) {
e.preventDefault();
window.open("http://twitter.com/home?status="+encodeURIComponent(document.title+" "+location.href));
}
},
'google': {
'label': 'Google+',
'icon': 'fa fa-google-plus',
'onClick': function(e) {
e.preventDefault();
window.open("https://plus.google.com/share?url="+encodeURIComponent(location.href));
window.open("http://twitter.com/intent/tweet?text="+document.title+"&url="+encodeURIComponent(location.href)+"&hashtags=rmarkdown,bookdown");
}
},
'linkedin': {
......@@ -52,7 +44,7 @@ gitbook.require(["gitbook", "lodash", "jQuery"], function(gitbook, _, $) {
},
'instapaper': {
'label': 'Instapaper',
'icon': 'fa fa-instapaper',
'icon': 'fa fa-italic',
'onClick': function(e) {
e.preventDefault();
window.open("http://www.instapaper.com/text?u="+encodeURIComponent(location.href));
......@@ -78,7 +70,7 @@ gitbook.require(["gitbook", "lodash", "jQuery"], function(gitbook, _, $) {
var menu = _.chain(opts.all)
.map(function(id) {
var site = SITES[id];
if (!site) return;
return {
text: site.label,
onClick: site.onClick
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment