Skip to content

Commit

Permalink
init my repo
Browse files Browse the repository at this point in the history
  • Loading branch information
MondayCha committed Jan 21, 2021
0 parents commit bcc34a8
Show file tree
Hide file tree
Showing 14 changed files with 423 additions and 0 deletions.
24 changes: 24 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Typora 中文学术风格主题

## 关于主题

基于Typora官方的Academic以及[zh-academic](https://github.com/ZJUGuoShuai/zh-academic)主题,正文字体采用华文中宋,等宽字体采用CamingoCode。

和Academic的区别主要在代码块上,我更偏爱带有外边框的代码样式,示例可参看`README.pdf`

```python
# This is a useless sample code
import taichi as ti
ti.init(debug=False, arch=ti.cuda)
```

## 安装方式

直接下载本仓库为 ZIP,将内容(`academic-zh/``academic-zh.css`)解压缩至 Typora 主题文件夹内(Typora主题文件夹打开方式:菜单→主题→打开主题文件夹)。

## 其他说明:

- 可使用`<div style='text-align:right'></div>`的方式右对齐
- 可使用`<center></center>`的方式居中对齐
- 可使用`<div style="page-break-after:always;"></div>`在输出PDF时分页

Binary file added README.pdf
Binary file not shown.
310 changes: 310 additions & 0 deletions academic-zh.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,310 @@
@import './academic-zh/fonts.css';

:root {
--side-bar-bg-color: white;
--window-border: none;
--search-select-bg-color: #575c61;
--active-file-bg-color: #f1f4f5;
--item-hover-bg-color: #f1f4f5;
--item-hover-text-color: black;
--control-text-color: #555;
}

html {
font-size: 12pt;
}

/* Frame */
body {
-webkit-font-smoothing: antialiased;
line-height: 1.8rem;
letter-spacing: 0;
margin: 0;
overflow-x: hidden;
}

#write {
font-family: "STIX2Text", "Times New Roman", "华文中宋", "serif";
line-height: 1.5em;
padding: 10%;
padding-top: 5%;
}

.file-list-item-summary {
height: 36px;
}

.file-list-item {
padding-top: 18px !important;
padding-bottom: 18px;
}

#sidebar-loading-template.file-list-item {
padding-top: 0 !important;
}

a, a:visited {
color: #a00;
}

h1, h2, h3, h4, h5, h6 {
font-family: inherit;
line-height: 1.5em;
margin-bottom: 1em;
margin-top: 1em;
}

h1 {
font-size: 2.4em;
}

#write h1 {
text-align: center;
}

h2 {
font-size: 1.8em;
}

h3 {
font-size: 1.4em;
}

h4 {
font-size: 1.2em;
}

h5 {
font-size: 1em;
}

h6 {
font-size: 1em;
color: #777;
}

p {
margin-top: 1em;
margin-bottom: 1em;
text-align: justify;
}

pre, code {
font-family: "CamingoCodeRegular", "Times New Roman", "华文中宋", "serif", monospace !important;
}

.cm-s-inner .CodeMirror-cursor {
border-left: solid rgba(128, 128, 255, 0.8) !important;
}

/* 代码框 */

#write .md-fences {
border: 1px solid #7a7a7a;
-webkit-font-smoothing: initial;
margin: 1rem 0 !important;
padding: 3px 3px;
line-height: 1.55rem;
border-radius: 2px;
font-size: 0.9rem;
word-wrap: normal;
}

#write [mdtype="math_block"] {
font-size: 1.2rem;
}

#write .CodeMirror-wrap .CodeMirror-code pre {
padding-left: 12px;
line-height: 1.55rem;
}

.cm-s-inner .CodeMirror-linenumber {
width: 2ch !important;
color: rgba(128, 128, 255, 0.8);
}

#write .CodeMirror-cursors .CodeMirror-cursor {
border-left: 2px solid var(--main-4);
}

#write code,
tt {
padding: 2px 4px;
border-radius: 2px;
font-size: 0.92rem;
color: #6b6b6b;
/* color: #c7254e;
background-color: #f9f2f4; */
}

tt {
margin: 0 2px;
}

#write .md-footnote {
background-color: #ffffff;
color: #a00 !important;
}


.footnotes {
display: list-item;
margin-left: 1em;
}

.md-fences {
border: 1px solid;
}

.md-fences.md-fences-with-lineno {
border: none;
}

.CodeMirror-linenumber {
color: #333;
}

*.in-text-selection,
::selection,
.CodeMirror-selected {
background: var(--search-select-bg-color);
color: var(--search-select-text-color) !important;
text-shadow: none;
}

a.md-toc-inner {
color: var(--text-color);
}

.cm-s-typora-default .cm-link {
color: #a00;
text-decoration: underline;
}

.cm-s-typora-default .cm-header, .cm-s-typora-default .cm-property {
color: black;
}

#typora-source .CodeMirror-lines {
-webkit-font-smoothing: auto;
max-width: 1000px;
}

.md-def-name:before,
.md-def-name:after {
color: #2d2d2d;
}

sup.md-footnote {
background-color: initial;
color: inherit;
}

mark {
background: #fff387;
}

td, th {
border: 1px solid;
padding-left: 1ch;
padding-right: 1ch;
}

/*table tr[cid]:first-child > td {
border-top: 3px double;
}*/

th {
border-bottom: 0;
padding-top: 2px;
background: #575c61;
border-color: #333;
color: #f3f3f3;
}

pre.md-meta-block {
border: 1px solid #a2a9b1;
background-color: #f8f9fa;
padding: 5px;
margin-bottom: 1em;
}

.task-list-item input:before {
content: '\221A';
display: inline-block;
width: 1.25rem;
height: 1.6rem;
vertical-align: middle;
text-align: center;
color: #bbb;
background-color: inherit;
}

.task-list-item input:checked:before,
.task-list-item input[checked]:before{
color: inherit;
}

.md-task-list-item > input {
top: auto;
margin-left: -1.1em;
font-size: 1.3em;
margin-top: 0px;
-webkit-appearance: none;
}

.md-task-list-item input:before {
content: '\2610';
display: inline-block;
width: 1.25rem;
height: 1.6rem;
vertical-align: middle;
text-align: center;
color: #bbb;
background-color: inherit;
}

.md-task-list-item input:checked:before,
.md-task-list-item input[checked]:before{
color: inherit;
content: '\2611';
}

.task-list-item {
padding-left: 1.5em;
}

blockquote {
font-style: italic;
padding: 0.25em 24px;
position: relative;
color: #383838;
border-left: 2px solid;

}


#write > blockquote {
padding: 0.25em 30px;
margin-left: -32px;
width: calc(100% + 32px);
}

#write > .md-fences-with-lineno {
margin-left: -33px;
color: black;
}
/*
img {
max-height: 20em;
}*/

.CodeMirror-linenumber {
min-width: 25px;
}

.md-header {
font-size: inherit !important;
}

Binary file added academic-zh/CamingoCode-Regular-1.woff
Binary file not shown.
29 changes: 29 additions & 0 deletions academic-zh/GUST e-foundry License.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
This is a preliminary version (2006-09-30), barring acceptance from
the LaTeX Project Team and other feedback, of the GUST Font License.
(GUST is the Polish TeX Users Group, http://www.gust.org.pl)

For the most recent version of this license see
http://www.gust.org.pl/fonts/licenses/GUST-FONT-LICENSE.txt
or
http://tug.org/fonts/licenses/GUST-FONT-LICENSE.txt

This work may be distributed and/or modified under the conditions
of the LaTeX Project Public License, either version 1.3c of this
license or (at your option) any later version.

Please also observe the following clause:
1) it is requested, but not legally required, that derived works be
distributed only after changing the names of the fonts comprising this
work and given in an accompanying "manifest", and that the
files comprising the Work, as listed in the manifest, also be given
new names. Any exceptions to this request are also given in the
manifest.

We recommend the manifest be given in a separate file named
MANIFEST-<fontid>.txt, where <fontid> is some unique identification
of the font family. If a separate "readme" file accompanies the Work,
we recommend a name of the form README-<fontid>.txt.

The latest version of the LaTeX Project Public License is in
http://www.latex-project.org/lppl.txt and version 1.3c or later
is part of all distributions of LaTeX version 2006/05/20 or later.
Binary file added academic-zh/STIX2Math.woff
Binary file not shown.
Binary file added academic-zh/STIX2Text-Bold.woff
Binary file not shown.
Binary file added academic-zh/STIX2Text-BoldItalic.woff
Binary file not shown.
Binary file added academic-zh/STIX2Text-Italic.woff
Binary file not shown.
Binary file added academic-zh/STIX2Text-Regular.woff
Binary file not shown.
Binary file added academic-zh/STIX_2.0.0_license.pdf
Binary file not shown.
Binary file added academic-zh/STZHONGS.woff
Binary file not shown.
Binary file added academic-zh/STZHONGS_Bold.woff
Binary file not shown.
Loading

0 comments on commit bcc34a8

Please sign in to comment.