fonts: improve default fonts & font picker
- change default font for colibris and for no-skin - add roboto and quicksand font files - simplify font picker: directly use the name of the font, and reduce their number
This commit is contained in:
parent
fb5a65c5fc
commit
a5164dad43
13 changed files with 56 additions and 135 deletions
|
@ -38,27 +38,6 @@
|
|||
"pad.settings.rtlcheck": "Read content from right to left?",
|
||||
"pad.settings.fontType": "Font type:",
|
||||
"pad.settings.fontType.normal": "Normal",
|
||||
"pad.settings.fontType.opendyslexic": "Open Dyslexic",
|
||||
"pad.settings.fontType.monospaced": "Monospace",
|
||||
"pad.settings.fontType.montserrat": "Montserrat",
|
||||
"pad.settings.fontType.comicsans": "Comic Sans",
|
||||
"pad.settings.fontType.couriernew": "Courier New",
|
||||
"pad.settings.fontType.georgia": "Georgia",
|
||||
"pad.settings.fontType.impact": "Impact",
|
||||
"pad.settings.fontType.lucida": "Lucida",
|
||||
"pad.settings.fontType.lucidasans": "Lucida Sans",
|
||||
"pad.settings.fontType.palatino": "Palatino",
|
||||
"pad.settings.fontType.robotomono": "RobotoMono",
|
||||
"pad.settings.fontType.tahoma": "Tahoma",
|
||||
"pad.settings.fontType.timesnewroman": "Times New Roman",
|
||||
"pad.settings.fontType.trebuchet": "Trebuchet",
|
||||
"pad.settings.fontType.verdana": "Verdana",
|
||||
"pad.settings.fontType.symbol": "Symbol",
|
||||
"pad.settings.fontType.webdings": "Webdings",
|
||||
"pad.settings.fontType.wingdings": "Wingdings",
|
||||
"pad.settings.fontType.sansserif": "Sans Serif",
|
||||
"pad.settings.fontType.serif": "Serif",
|
||||
"pad.settings.globalView": "Global View",
|
||||
"pad.settings.language": "Language:",
|
||||
|
||||
"pad.importExport.import_export": "Import/Export",
|
||||
|
|
|
@ -13,9 +13,9 @@
|
|||
@import url("pad/loadingbox.css");
|
||||
|
||||
html {
|
||||
font-size: 13px;
|
||||
font-family: Arial, sans-serif;
|
||||
line-height: 16px;
|
||||
font-size: 14px;
|
||||
font-family: Cantarell, Roboto, "Open Sans", "Helvetica Neue", Arial, sans-serif;
|
||||
line-height: 20px;
|
||||
color: #3e3e3e;
|
||||
}
|
||||
.clear {
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
font-family: opendyslexic;
|
||||
src: url("../../../static/font/opendyslexic.otf") format("opentype");
|
||||
}
|
||||
|
||||
/* Roboto Mono */
|
||||
@font-face {
|
||||
font-family: "RobotoMono";
|
||||
src: url("../../../static/font/RobotoMono-Regular.ttf") format("truetype");
|
||||
|
@ -31,4 +29,33 @@
|
|||
font-weight: bold;
|
||||
font-style: normal;
|
||||
}
|
||||
/* End of Roboto Mono */
|
||||
@font-face {
|
||||
font-family: "Quicksand";
|
||||
src: url("../../../static/font/Quicksand-Regular.ttf") format("truetype");
|
||||
font-weight: 300;
|
||||
font-style: normal;
|
||||
}
|
||||
@font-face {
|
||||
font-family: "Quicksand";
|
||||
src: url("../../../static/font/Quicksand-Medium.ttf") format("truetype");
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
}
|
||||
@font-face {
|
||||
font-family: "Quicksand";
|
||||
src: url("../../../static/font/Quicksand-Bold.ttf") format("truetype");
|
||||
font-weight: bold;
|
||||
font-style: normal;
|
||||
}
|
||||
@font-face {
|
||||
font-family: "Roboto";
|
||||
src: url("../../../static/font/Roboto-Regular.ttf") format("truetype");
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
}
|
||||
@font-face {
|
||||
font-family: "Roboto";
|
||||
src: url("../../../static/font/Roboto-Bold.ttf") format("truetype");
|
||||
font-weight: bold;
|
||||
font-style: normal;
|
||||
}
|
BIN
src/static/font/Quicksand-Bold.ttf
Normal file
BIN
src/static/font/Quicksand-Bold.ttf
Normal file
Binary file not shown.
BIN
src/static/font/Quicksand-Medium.ttf
Normal file
BIN
src/static/font/Quicksand-Medium.ttf
Normal file
Binary file not shown.
BIN
src/static/font/Quicksand-Regular.ttf
Normal file
BIN
src/static/font/Quicksand-Regular.ttf
Normal file
Binary file not shown.
BIN
src/static/font/Roboto-Bold.ttf
Normal file
BIN
src/static/font/Roboto-Bold.ttf
Normal file
Binary file not shown.
BIN
src/static/font/Roboto-Regular.ttf
Normal file
BIN
src/static/font/Roboto-Regular.ttf
Normal file
Binary file not shown.
|
@ -141,29 +141,7 @@ var padeditor = (function()
|
|||
self.ace.setProperty("showsauthorcolors", !settings.noColors);
|
||||
}
|
||||
|
||||
var fontFamily = newOptions['padFontFamily'];
|
||||
switch (fontFamily) {
|
||||
case "monospace": self.ace.setProperty("textface", "monospace"); break;
|
||||
case "montserrat": self.ace.setProperty("textface", "Montserrat"); break;
|
||||
case "opendyslexic": self.ace.setProperty("textface", "OpenDyslexic"); break;
|
||||
case "comicsans": self.ace.setProperty("textface", "'Comic Sans MS','Comic Sans',cursive"); break;
|
||||
case "georgia": self.ace.setProperty("textface", "Georgia,'Bitstream Charter',serif"); break;
|
||||
case "impact": self.ace.setProperty("textface", "Impact,Haettenschweiler,'Arial Black',sans-serif"); break;
|
||||
case "lucida": self.ace.setProperty("textface", "Lucida,'Lucida Serif','Lucida Bright',serif"); break;
|
||||
case "lucidasans": self.ace.setProperty("textface", "'Lucida Sans','Lucida Grande','Lucida Sans Unicode','Luxi Sans',sans-serif"); break;
|
||||
case "palatino": self.ace.setProperty("textface", "Palatino,'Palatino Linotype','URW Palladio L',Georgia,serif"); break;
|
||||
case "robotomono": self.ace.setProperty("textface", "RobotoMono"); break;
|
||||
case "tahoma": self.ace.setProperty("textface", "Tahoma,sans-serif"); break;
|
||||
case "timesnewroman": self.ace.setProperty("textface", "'Times New Roman',Times,serif"); break;
|
||||
case "trebuchet": self.ace.setProperty("textface", "'Trebuchet MS',sans-serif"); break;
|
||||
case "verdana": self.ace.setProperty("textface", "Verdana,'DejaVu Sans',sans-serif"); break;
|
||||
case "symbol": self.ace.setProperty("textface", "Symbol"); break;
|
||||
case "webdings": self.ace.setProperty("textface", "Webdings"); break;
|
||||
case "wingdings": self.ace.setProperty("textface", "Wingdings"); break;
|
||||
case "sansserif": self.ace.setProperty("textface", "sans-serif"); break;
|
||||
case "serif": self.ace.setProperty("textface", "serif"); break;
|
||||
default: self.ace.setProperty("textface", ""); break;
|
||||
}
|
||||
self.ace.setProperty("textface", newOptions['padFontFamily'] || "");
|
||||
},
|
||||
dispose: function()
|
||||
{
|
||||
|
|
|
@ -165,33 +165,9 @@ function handleClientVars(message)
|
|||
|
||||
// font family change
|
||||
$("#viewfontmenu").change(function(){
|
||||
var font = $("#viewfontmenu").val();
|
||||
switch (font) {
|
||||
case "monospace": setFont("Courier new");break;
|
||||
case "opendyslexic": setFont("OpenDyslexic");break;
|
||||
case "comicsans": setFont("Comic Sans MS");break;
|
||||
case "georgia": setFont("Georgia");break;
|
||||
case "impact": setFont("Impact");break;
|
||||
case "lucida": setFont("Lucida");break;
|
||||
case "lucidasans": setFont("Lucida Sans Unicode");break;
|
||||
case "palatino": setFont("Palatino Linotype");break;
|
||||
case "tahoma": setFont("Tahoma");break;
|
||||
case "timesnewroman": setFont("Times New Roman");break;
|
||||
case "trebuchet": setFont("Trebuchet MS");break;
|
||||
case "verdana": setFont("Verdana");break;
|
||||
case "symbol": setFont("Symbol");break;
|
||||
case "webdings": setFont("Webdings");break;
|
||||
case "wingdings": setFont("Wingdings");break;
|
||||
case "sansserif": setFont("MS Sans Serif");break;
|
||||
case "serif": setFont("MS Serif");break;
|
||||
default: setFont("");break;
|
||||
}
|
||||
$('#innerdocbody').css("font-family", $(this).val() || "");
|
||||
});
|
||||
}
|
||||
|
||||
function setFont(font){
|
||||
$('#innerdocbody').css("font-family", font);
|
||||
}
|
||||
|
||||
exports.baseURL = '';
|
||||
exports.init = init;
|
||||
|
|
|
@ -95,21 +95,5 @@ p[data-l10n-id="ep_comments_page.comment"],
|
|||
background-color: #f9f9f9 !important;
|
||||
}
|
||||
|
||||
|
||||
/* NEUTRAL FONT */
|
||||
body
|
||||
{ font-family: Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif; }
|
||||
|
||||
/* PRIMARY FONT */
|
||||
h1,
|
||||
#titlelabel,
|
||||
#chatlabel,
|
||||
.btn,
|
||||
.yui-skin-sam .yui-panel .hd,
|
||||
.reply-suggestion p:not(.reply-comment-suggest-from-p),
|
||||
p[data-l10n-id="ep_comments_page.comment"],
|
||||
#newComment.sidebar-comment input[type=submit],
|
||||
.comment-changeTo-approve input[type=submit],
|
||||
#sidedivinner>div:before
|
||||
{ font-family: Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif !important; }
|
||||
|
||||
/* FONT */
|
||||
body { font-family: Quicksand, Cantarell, "Open Sans", "Helvetica Neue", sans-serif; }
|
||||
|
|
|
@ -146,26 +146,14 @@
|
|||
<% e.begin_block("mySettings.dropdowns"); %>
|
||||
<label for="viewfontmenu" data-l10n-id="pad.settings.fontType">Font type:</label>
|
||||
<select id="viewfontmenu">
|
||||
<option value="normal" data-l10n-id="pad.settings.fontType.normal"></option>
|
||||
<option value="monospace" data-l10n-id="pad.settings.fontType.monospaced"></option>
|
||||
<option value="montserrat" data-l10n-id="pad.settings.fontType.montserrat"></option>
|
||||
<option value="opendyslexic" data-l10n-id="pad.settings.fontType.opendyslexic"></option>
|
||||
<option value="comicsans" data-l10n-id="pad.settings.fontType.comicsans"></option>
|
||||
<option value="georgia" data-l10n-id="pad.settings.fontType.georgia"></option>
|
||||
<option value="impact" data-l10n-id="pad.settings.fontType.impact"></option>
|
||||
<option value="lucida" data-l10n-id="pad.settings.fontType.lucida"></option>
|
||||
<option value="lucidasans" data-l10n-id="pad.settings.fontType.lucidasans"></option>
|
||||
<option value="palatino" data-l10n-id="pad.settings.fontType.palatino"></option>
|
||||
<option value="robotomono" data-l10n-id="pad.settings.fontType.robotomono"></option>
|
||||
<option value="tahoma" data-l10n-id="pad.settings.fontType.tahoma"></option>
|
||||
<option value="timesnewroman" data-l10n-id="pad.settings.fontType.timesnewroman"></option>
|
||||
<option value="trebuchet" data-l10n-id="pad.settings.fontType.trebuchet"></option>
|
||||
<option value="verdana" data-l10n-id="pad.settings.fontType.verdana"></option>
|
||||
<option value="symbol" data-l10n-id="pad.settings.fontType.symbol"></option>
|
||||
<option value="webdings" data-l10n-id="pad.settings.fontType.webdings"></option>
|
||||
<option value="wingdings" data-l10n-id="pad.settings.fontType.wingdings"></option>
|
||||
<option value="sansserif" data-l10n-id="pad.settings.fontType.sansserif"></option>
|
||||
<option value="serif" data-l10n-id="pad.settings.fontType.serif"></option>
|
||||
<option value="" data-l10n-id="pad.settings.fontType.normal">Normal</option>
|
||||
<%= fonts = [
|
||||
"Quicksand", "Roboto", "Montserrat", "OpenDyslexic", "monospace", "RobotoMono",
|
||||
"Arial", "Georgia", "Times New Roman", "Verdana", "Courrier New",
|
||||
"Open Sans", "Lato", "Helvetica" ] %>
|
||||
<% for(var i=0; i < fonts.length; i++) { %>
|
||||
<option value="<%=fonts[i]%>"><%=fonts[i]%></option>
|
||||
<% } %>
|
||||
</select>
|
||||
|
||||
<label for="languagemenu" data-l10n-id="pad.settings.language">Language:</label>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
, langs = require("ep_etherpad-lite/node/hooks/i18n").availableLangs
|
||||
%>
|
||||
<!doctype html>
|
||||
<html>
|
||||
<html class="<%=settings.skinVariants%>">
|
||||
<title data-l10n-id="timeslider.pageTitle" data-l10n-args='{ "appTitle": "<%=settings.title%>" }'><%=settings.title%> Timeslider</title>
|
||||
<script>
|
||||
/*
|
||||
|
@ -123,7 +123,7 @@
|
|||
|
||||
<div id="import_export" class="popup" ><div class="popup-content">
|
||||
<div id="export">
|
||||
<h2 data-l10n-id="timeslider.exportCurrent"></h2>
|
||||
<h1 data-l10n-id="timeslider.exportCurrent"></h1>
|
||||
<% e.begin_block("exportColumn"); %>
|
||||
<a id="exportetherpada" target="_blank" class="exportlink">
|
||||
<span class="exporttype buttonicon buttonicon-file-powerpoint" id="exportetherpad" data-l10n-id="pad.importExport.exportetherpad"></span>
|
||||
|
@ -225,28 +225,17 @@
|
|||
<!---------------------------------->
|
||||
|
||||
<div id="settings" class="popup"><div class="popup-content">
|
||||
<h1 data-l10n-id="pad.settings.padSettings"></h1>
|
||||
<label for="viewfontmenu" data-l10n-id="pad.settings.fontType">Font type:</label>
|
||||
<select id="viewfontmenu">
|
||||
<option value="normal" data-l10n-id="pad.settings.fontType.normal"></option>
|
||||
<option value="monospace" data-l10n-id="pad.settings.fontType.monospaced"></option>
|
||||
<option value="montserrat" data-l10n-id="pad.settings.fontType.montserrat"></option>
|
||||
<option value="opendyslexic" data-l10n-id="pad.settings.fontType.opendyslexic"></option>
|
||||
<option value="comicsans" data-l10n-id="pad.settings.fontType.comicsans"></option>
|
||||
<option value="georgia" data-l10n-id="pad.settings.fontType.georgia"></option>
|
||||
<option value="impact" data-l10n-id="pad.settings.fontType.impact"></option>
|
||||
<option value="lucida" data-l10n-id="pad.settings.fontType.lucida"></option>
|
||||
<option value="lucidasans" data-l10n-id="pad.settings.fontType.lucidasans"></option>
|
||||
<option value="palatino" data-l10n-id="pad.settings.fontType.palatino"></option>
|
||||
<option value="robotomono" data-l10n-id="pad.settings.fontType.robotomono"></option>
|
||||
<option value="tahoma" data-l10n-id="pad.settings.fontType.tahoma"></option>
|
||||
<option value="timesnewroman" data-l10n-id="pad.settings.fontType.timesnewroman"></option>
|
||||
<option value="trebuchet" data-l10n-id="pad.settings.fontType.trebuchet"></option>
|
||||
<option value="verdana" data-l10n-id="pad.settings.fontType.verdana"></option>
|
||||
<option value="symbol" data-l10n-id="pad.settings.fontType.symbol"></option>
|
||||
<option value="webdings" data-l10n-id="pad.settings.fontType.webdings"></option>
|
||||
<option value="wingdings" data-l10n-id="pad.settings.fontType.wingdings"></option>
|
||||
<option value="sansserif" data-l10n-id="pad.settings.fontType.sansserif"></option>
|
||||
<option value="serif" data-l10n-id="pad.settings.fontType.serif"></option>
|
||||
<option value="" data-l10n-id="pad.settings.fontType.normal">Normal</option>
|
||||
<%= fonts = [
|
||||
"Quicksand", "Roboto", "Montserrat", "OpenDyslexic", "monospace", "RobotoMono",
|
||||
"Arial", "Georgia", "Times New Roman", "Verdana", "Courrier New",
|
||||
"Open Sans", "Lato", "Helvetica" ] %>
|
||||
<% for(var i=0; i < fonts.length; i++) { %>
|
||||
<option value="<%=fonts[i]%>"><%=fonts[i]%></option>
|
||||
<% } %>
|
||||
</select>
|
||||
</div></div>
|
||||
</div>
|
||||
|
|
Loading…
Reference in a new issue