Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Q
question2answer
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
outils
question2answer
Commits
a8d607d1
Commit
a8d607d1
authored
Mar 28, 2017
by
Scott
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
SnowFlat: update Google Fonts URL, inline local font CSS
parent
e0a2b452
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
27 additions
and
25 deletions
+27
-25
ubuntu.css
qa-theme/SnowFlat/fonts/ubuntu.css
+0
-20
qa-theme.php
qa-theme/SnowFlat/qa-theme.php
+27
-5
No files found.
qa-theme/SnowFlat/fonts/ubuntu.css
deleted
100644 → 0
View file @
e0a2b452
@font-face
{
font-family
:
'Ubuntu'
;
font-weight
:
400
;
font-style
:
normal
;
src
:
local
(
'Ubuntu'
),
local
(
'Ubuntu-regular'
),
url('Ubuntu-regular.woff')
format
(
'woff'
);
}
@font-face
{
font-family
:
'Ubuntu'
;
font-weight
:
700
;
font-style
:
normal
;
src
:
local
(
'Ubuntu Bold'
),
local
(
'Ubuntu-700'
),
url('Ubuntu-700.woff')
format
(
'woff'
);
}
@font-face
{
font-family
:
'Ubuntu'
;
font-weight
:
400
;
font-style
:
italic
;
src
:
local
(
'Ubuntu Italic'
),
local
(
'Ubuntu-italic'
),
url('Ubuntu-italic.woff')
format
(
'woff'
);
}
@font-face
{
font-family
:
'Ubuntu'
;
font-weight
:
700
;
font-style
:
italic
;
src
:
local
(
'Ubuntu Bold Italic'
),
local
(
'Ubuntu-700italic'
),
url('Ubuntu-700italic.woff')
format
(
'woff'
);
}
qa-theme/SnowFlat/qa-theme.php
View file @
a8d607d1
...
...
@@ -74,11 +74,33 @@ class qa_html_theme extends qa_html_theme_base
if
(
$this
->
isRTL
)
$this
->
content
[
'css_src'
][]
=
$this
->
rooturl
.
'qa-styles-rtl.css?'
.
QA_VERSION
;
// add Ubuntu font CSS file from Google Fonts
if
(
$this
->
localfonts
)
$this
->
content
[
'css_src'
][]
=
$this
->
rooturl
.
'fonts/ubuntu.css?'
.
QA_VERSION
;
else
$this
->
content
[
'css_src'
][]
=
'//fonts.googleapis.com/css?family=Ubuntu:400,700,400italic,700italic'
;
if
(
$this
->
localfonts
)
{
// add Ubuntu font locally (inlined for speed)
$this
->
output_array
(
array
(
'<style>'
,
'@font-face {'
,
' font-family: "Ubuntu"; font-style: normal; font-weight: 400;'
,
' src: local("Ubuntu"), url("'
.
$this
->
rooturl
.
'fonts/Ubuntu-regular.woff") format("woff");'
,
'}'
,
'@font-face {'
,
' font-family: "Ubuntu"; font-style: normal; font-weight: 700;'
,
' src: local("Ubuntu Bold"), local("Ubuntu-Bold"), url("'
.
$this
->
rooturl
.
'fonts/Ubuntu-700.woff") format("woff");'
,
'}'
,
'@font-face {'
,
' font-family: "Ubuntu"; font-style: italic; font-weight: 400;'
,
' src: local("Ubuntu Italic"), local("Ubuntu-Italic"), url("'
.
$this
->
rooturl
.
'fonts/Ubuntu-italic.woff") format("woff");'
,
'}'
,
'@font-face {'
,
' font-family: "Ubuntu"; font-style: italic; font-weight: 700;'
,
' src: local("Ubuntu Bold Italic"), local("Ubuntu-BoldItalic"), url("'
.
$this
->
rooturl
.
'fonts/Ubuntu-700italic.woff") format("woff");'
,
'}'
,
'</style>'
,
));
}
else
{
// add Ubuntu font CSS file from Google Fonts
$this
->
content
[
'css_src'
][]
=
'https://fonts.googleapis.com/css?family=Ubuntu:400,400i,700,700i'
;
}
parent
::
head_css
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment