some nice posts
set font color
Use the <font> tag:
这是红色字体:<font color=red>我是红色的字体</font>
The display effect is as follows:
This is the red font: I am the red font
Style it with CSS:
这是蓝色字体:<span style="color:blue">我是蓝色的字体</span>
The display effect is as follows (it seems useless?)
This is the blue font: I am the blue font
[Color query] Getting started with font colors in CSDN format
set font size
(It seems that only the <font> command is valid in CSDN)
The optional size is 1-7, and the default size should be 3.
这是5号字体:<font size=5>我是5号字体</font>
The display effect is as follows:
This is font size 5: I am font size 5
The following code is indeed valid on other Markdown editors, but I don’t know why it can’t be used in CSDN, and it does not display the span code
这是20号字体:<span style="font-size:20px">我是20号字体</span>
<span style="color: red; font-size: 16px;">这是一段红色、16号字体的文本。</span>
这是24px的字体:<span style="font-size: 24px;">我是24px的字体</span>
Later, I found some introductions on the experience of writing CSDN blogs on the Internet, and found that everyone basically used <font>, but did not use <span>, maybe it is not supported.
The following is a summary of some blogs, which can be viewed later if necessary
- CSDN blog text color, font and font size settings
- Blog writing tips [1]: How to set font size, color and font type!
- Markdown editor sets the common functions of csdn blog: font color, background color, etc. (attached: color card)
Set a different font
<font face="楷体" color="red" size="6">
face用于设置字体;
color用于设置颜色;
size用于设置大小
</font>
The display effect is
face is used to set the font;
color is used to set the color;
size is used to set the size
set background color
It seems that there is no way to set the background color of a few words in a line individually, once set it is the entire line. for example
<table><tr><td bgcolor="orange"> 背景色是 1 orange</td></tr></table>
The display effect is
The background color is 1 orange |
If you want to emphasize certain words in a line, you can use
这是==标记文本==
The display effect
is thismarkup text
Or display as a keyboard format is also easier to use. for example
使用 <kbd>Ctrl</kbd>+<kbd>Alt</kbd>+<kbd>Del</kbd> 重启电脑
The display effect is to
use Ctrl+ Alt+ Delto restart the computer
Other display effects
Underscores, subscripts, etc.
<u>下划线</u>
文本^上标^
文本~下标~
<small>小号字体</small>
<big>大号字体</big>
H~2~O is是液体
2^10^ 运算结果是 1024
The display effect is:
underline
text superscript
text subscript
small font
large font
H 2 O is liquid
2 10 operation result is 1024
Indent the first line, set the size of the inserted picture, space, black point
Refer to the common techniques of linking CSDN (font, color, size, type, etc.)
Blank lines
Use block tags to open a line, such as p, div, br
<p></p>
<div></div>
内容1<br/><br/>内容2