关于Markdown的一些学习笔记
Markdown制作ppt
平时制作PPT都是找到一个PPT模板,然后进行修改;往往找一个模板要考虑他的背景和动画效果;但如果时间很紧的话,这样显得不是特别的解决之道。如果熟悉Markdown的话,可以利用Marp这个编辑器,选择自己喜欢的ppt背景并生成pdf;在制作ppt上感觉速度还是较快的。Marp源代码在这里;而具体的release版本在这里。
这里放出marp的一个模板
Marp
===
# 
##### Markdown presentation writer, powered by [Electron](http://electron.atom.io/)
###### Created by Yuki Hattori ( [@yhatt](https://github.com/yhatt) )
---
# Features
- **Slides are written in Markdown.**
- Cross-platform. Supports Windows, Mac, and Linux
- Live Preview with 3 modes
- Slide themes (`default`, `gaia`) and custom background images
- Supports emoji :heart:
- Render maths in your slides
- Export your slides to PDF
---
# How to write slides?
Split slides by horizontal ruler `---`. It's very simple.
```md
# Slide 1
foobar
---
# Slide 2
foobar
Notice: Ruler (
<hr>) is not displayed in Marp.
Directives
Marp's Markdown has extended directives to affect slides.
Insert HTML comment as below:
<!-- {directive_name}: {value} -->
<!--
{first_directive_name}: {value}
{second_directive_name}: {value}
...
-->
Global Directives
$theme
Changes the theme of all the slides in the deck. You can also change from View -> Theme menu.
<!-- $theme: gaia -->
| Theme name | Value | Directive |
|---|---|---|
| Default | default | <!-- $theme: default --> |
| Gaia | gaia | <!-- $theme: gaia --> |
$width / $height
Changes width and height of all the slides.
You can use units: px (default), cm, mm, in, pt, and pc.
<!-- $width: 12in -->
$size
Changes slide size by presets.
Presets: 4:3, 16:9, A0-A8, B0-B8 and suffix of -portrait.
<!-- $size: 16:9 -->
Page Directives
The page directive would apply to the current page and the following pages.
You should insert it at the top to apply it to all slides.
page_number
Set true to show page number on slides. See lower right!
<!-- page_number: true -->
template
Set to use template of theme.
The template directive just enables that using theme supports templates.
<!--
$theme: gaia
template: invert
-->
Example: Set "invert" template of Gaia theme.
footer
Add a footer to the current slide and all of the following slides
<!-- footer: This is a footer -->
Example: Adds "This is a footer" in the bottom of each slide
prerender
Pre-renders a slide, which can prevent issues with very large background images.
<!-- prerender: true -->
Pro Tips
Apply page directive to current slide only
Page directive can be selectively applied to the current slide by prefixing the page directive with *.
<!-- *page_number: false -->
<!-- *template: invert -->
Slide background Images
You can set an image as a slide background.

Options can be provided after bg, for example .
Options include:
originalto include the image without any effectsx%to include the image atxpercent of the slide size
Include multiple tags to stack background images horizontally.

Maths Typesetting
Mathematics is typeset using the KaTeX package. Use $ for inline maths, such as \(ax^2+bc+c\), and $$ for block maths:
This is inline: $ax^2+bx+c$, and this is block:
$$I_{xx}=\int\int_Ry^2f(x,y)\cdot{}dydx$$
Enjoy writing slides! 👍
https://github.com/yhatt/marp
Copyright © 2016 Yuki Hattori
This software released under the MIT License.
## Markdown自定义样式
Markdown自带了html代码,但是并不支持CSS代码;能做的只能是修改编辑器里的.CSS渲染文件才能对文件的具体样式进行修改。
-------------------------------------------
个性签名:一名会音乐、爱健身的不合格程序员
可以Follow博主的Github哦(っ•̀ω•́)っ✎⁾⁾

浙公网安备 33010602011771号