mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-01-19 14:13:34 +01:00
* Added support for the Montserrat Font as discussed in #3201 I chose a thin version of the Font (namely Montserrat Light) as the regular font and Montserrat Regular as the bold version. The thin fonts just look better in my opinion.
This commit is contained in:
parent
8c57c8d0d6
commit
8bd8be97b9
7 changed files with 30 additions and 8 deletions
|
@ -40,6 +40,7 @@
|
|||
"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",
|
||||
|
|
|
@ -1272,6 +1272,21 @@ input[type=checkbox] {
|
|||
}
|
||||
/* End of gritter stuff */
|
||||
|
||||
/* Montserrat Font */
|
||||
@font-face {
|
||||
font-family: "Montserrat";
|
||||
src: url("../../static/font/Montserrat-Light.otf") format("opentype");
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
}
|
||||
@font-face {
|
||||
font-family: "Montserrat";
|
||||
src: url("../../static/font/Montserrat-Regular.otf") format("opentype");
|
||||
font-weight: bold;
|
||||
font-style: normal;
|
||||
}
|
||||
/* End of Monterrat Font */
|
||||
|
||||
@font-face {
|
||||
font-family: opendyslexic;
|
||||
src: url("../../static/font/opendyslexic.otf") format("opentype");
|
||||
|
|
BIN
src/static/font/Montserrat-Light.otf
Executable file
BIN
src/static/font/Montserrat-Light.otf
Executable file
Binary file not shown.
BIN
src/static/font/Montserrat-Regular.otf
Executable file
BIN
src/static/font/Montserrat-Regular.otf
Executable file
Binary file not shown.
|
@ -554,10 +554,12 @@ var pad = {
|
|||
pad.changeViewOption('rtlIsTrue', true);
|
||||
}
|
||||
|
||||
var fonts = ['useMonospaceFont', 'useOpenDyslexicFont', 'useComicSansFont', 'useCourierNewFont', 'useGeorgiaFont', 'useImpactFont',
|
||||
'useLucidaFont', 'useLucidaSansFont', 'usePalatinoFont', 'useRobotoMonoFont', 'useTahomaFont', 'useTimesNewRomanFont',
|
||||
'useTrebuchetFont', 'useVerdanaFont', 'useSymbolFont', 'useWebdingsFont', 'useWingDingsFont', 'useSansSerifFont',
|
||||
'useSerifFont'];
|
||||
|
||||
var fonts = ['useMonospaceFont', 'useMontserratFont', 'useOpenDyslexicFont', 'useComicSansFont', 'useCourierNewFont',
|
||||
'useGeorgiaFont', 'useImpactFont', 'useLucidaFont', 'useLucidaSansFont', 'usePalatinoFont', 'useRobotoMonoFont',
|
||||
'useTahomaFont', 'useTimesNewRomanFont', 'useTrebuchetFont', 'useVerdanaFont', 'useSymbolFont', 'useWebdingsFont',
|
||||
'useWingDingsFont', 'useSansSerifFont', 'useSerifFont'];
|
||||
|
||||
|
||||
$.each(fonts, function(i, font){
|
||||
if(padcookie.getPref(font) == true){
|
||||
|
|
|
@ -30,10 +30,12 @@ var padeditor = (function()
|
|||
var settings = undefined;
|
||||
|
||||
// Array of available fonts
|
||||
var fonts = ['useMonospaceFont', 'useOpenDyslexicFont', 'useComicSansFont', 'useCourierNewFont', 'useGeorgiaFont', 'useImpactFont',
|
||||
'useLucidaFont', 'useLucidaSansFont', 'usePalatinoFont', 'useRobotoMonoFont', 'useTahomaFont', 'useTimesNewRomanFont',
|
||||
'useTrebuchetFont', 'useVerdanaFont', 'useSymbolFont', 'useWebdingsFont', 'useWingDingsFont', 'useSansSerifFont',
|
||||
'useSerifFont'];
|
||||
|
||||
var fonts = ['useMonospaceFont', 'useMontserratFont', 'useOpenDyslexicFont', 'useComicSansFont', 'useCourierNewFont',
|
||||
'useGeorgiaFont', 'useImpactFont', 'useLucidaFont', 'useLucidaSansFont', 'usePalatinoFont', 'useRobotoMonoFont',
|
||||
'useTahomaFont', 'useTimesNewRomanFont', 'useTrebuchetFont', 'useVerdanaFont', 'useSymbolFont', 'useWebdingsFont',
|
||||
'useWingDingsFont', 'useSansSerifFont', 'useSerifFont'];
|
||||
|
||||
|
||||
var self = {
|
||||
ace: null,
|
||||
|
@ -161,6 +163,7 @@ var padeditor = (function()
|
|||
font = font.replace("Font","");
|
||||
font = font.toLowerCase();
|
||||
if(font === "monospace") self.ace.setProperty("textface", "monospace");
|
||||
if(font === "montserrat") self.ace.setProperty("textface", "Montserrat");
|
||||
if(font === "opendyslexic") self.ace.setProperty("textface", "OpenDyslexic");
|
||||
if(font === "comicsans") self.ace.setProperty("textface", "'Comic Sans MS','Comic Sans',cursive");
|
||||
if(font === "georgia") self.ace.setProperty("textface", "Georgia,'Bitstream Charter',serif");
|
||||
|
|
|
@ -161,6 +161,7 @@
|
|||
<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>
|
||||
|
|
Loading…
Reference in a new issue