使用 来显示优美的用户简介,主页装饰新时尚。
完美适配氩洛谷/exlg/Luogu Search Anywhere,丝毫不影响显示效果(除非使用阴间壁纸)
这是洛谷本站原汁原味的东西,不需要使用其他的网站,所以加载速度快得多。
本 blog 目前只发布在洛谷上,不接受任何形式的转载/抄袭(代码可以随便用,这里只是声明是我写的),除非得到原作者 @159号程序员 的许可。
个人中心效果图:
\qquad\raisebox{20pt}\color{94d66d}\Large\textrm{159号程序员}
[](https://www.luogu.com.cn/user/334586)[$\qquad\raisebox{20pt}\color{94d66d}\Large\textrm{159号程序员}$](https://www.luogu.com.cn/user/334586)$\kern{-8.5em}\normalsize\color{gray}\texttt{\#334586}\quad\footnotesize\color{e74c3c}\cancel{\boxed{\textrm{学}}}\;\color{94d66d}{\boxed{\textrm{言}}}\;\color{94d66d}{\boxed{\textrm{私}}}% LaTeX by 159号程序员$
$\kern{1em}\footnotesize\text{「衣带渐宽终不悔,为伊消得人憔悴」}$
$\text{CCF\,评级:\color{gray}0}$
$\text{注册时间:\color{gray}
2020-03-31}$
[$\text{关注:133}$](https://www.luogu.com.cn/user/334586#following.following)[$\text{\quad粉丝:544}$](https://www.luogu.com.cn/user/334586#following.follower)
[$\text{提交:1.63k}$](https://www.luogu.com.cn/user/334586#practice)[$\text{\quad通过:458}$](https://www.luogu.com.cn/user/334586#practice)
[$\text{通过率:28\%}$](https://www.luogu.com.cn/record/list?user=334586)
$\text{代表作:}$[$\footnotesize\color{ffc116}{\boxed{\textrm{荐}}}\;\color{5e72e4}\normalsize\text{OI 词典}$](https://www.luogu.com.cn/blog/334586/luogu-dictionary)
[$\kern{4em}\footnotesize\color{ffc116}{\boxed{\textrm{荐}}}\;\color{5e72e4}\normalsize\text{CSP初赛知识点梳理}$](https://www.luogu.com.cn/blog/334586/csp-pre-knowledge)
[$\color{5e72e4}\normalsize\kern{4em}\text{洛谷新手指南}$](https://www.luogu.com.cn/blog/334586/luo-gu-xin-shou-zhi-na-mu-lu)
$\text{最后更新:\color{gray}2022-4-23}$blog 中的显示有些小问题,头像旁边的用户名没有居中,不过在个人主页/云剪贴板中(其他的没有实验)是完全正常的。
众所周知, 代码是给人用的,所以本文自动放弃版权,各位可以随意使用,不过使用产生的后果我不承担任何责任。
[](https://www.luogu.com.cn/user/UID)[$\qquad\raisebox{20pt}\color{94d66d}\Large\textrm{用户名}$](https://www.luogu.com.cn/user/UID)$\kern{-8.5em}\normalsize\color{gray}\texttt{\#UID}% LaTeX by 159号程序员$把所有的 UID 修改为自己的 uid。
把所有的「用户名」修改为自己的用户名。
调整 \kern{-8.5em} 以让 uid 和状态显示居中,应该是一个负数。
修改 \color{} 中的内容来修改名字颜色。
表如下:
-
紫名:8E44AD
-
红名:E74C3C
-
橙名:E67E22
-
绿名:5EB95E
-
蓝名:0E90D2
-
灰名:BFBFBF
-
棕名:996600
如果您有 tag,在 \textrm{用户名} 后面加上:
\;\color{ffffff}\colorbox{上面 color 中填的内容}{\textbf{tag 内容}}字面意思修改即可。
接下来,集中介绍状态标签的代码:(追加在刚刚的后面)
$\quad\footnotesize\color{94d66d}{\boxed{\textrm{学}}}\;\color{94d66d}{\boxed{\textrm{言}}}\;\color{94d66d}{\boxed{\textrm{私}}}$这三项分别代表了学术/发言/私信。
如果想取消任意一项,在对应项 {\boxed 的前面加上 \cancel(在左括号的左边加),再把 \color{} 大括号中的内容由 94d66d 改为 e7433c。
$\kern{1em}\footnotesize\text{个性签名}$将「个性签名」替换为你的个性签名即可。
注:方便快捷地打出直角括号:「」。
调整 \kern{(a)em} 中 (a) 的大小来调整文本距离左边框的间距,输入可以是实数。
$\text{CCF\,评级:\color{gray}评级}$
$\text{注册时间:\color{gray}注册时间}$修改「评级」为你的 CCF 评级,注册时间同。
评级前 \color{} 中所填写的颜色如下:
:gray,:52c41a,:3498db,:ffce63。
如果您有勾,在评级右侧的大括号后加上:
无勾不需要做任何处理。
[$\text{关注:关注数}$](https://www.luogu.com.cn/user/UID#following.following)[$\text{\quad粉丝:粉丝数}$](https://www.luogu.com.cn/user/UID#following.follower)
[$\text{提交:提交数}$](https://www.luogu.com.cn/user/UID#practice)[$\text{\quad通过:通过数}$](https://www.luogu.com.cn/user/UID#practice)
[$\text{通过率:通过率(百分比)\%}$](https://www.luogu.com.cn/record/list?user=UID)字面意思修改。
UID 替换为你的 uid。
即使开了完隐也没有关系,提交记录显示不出来的。
$\text{代表作:}$[$\color{5e72e4}\normalsize\text{作品题目}$](链接)
[$\color{5e72e4}\normalsize\kern{4em}\text{作品题目}$](链接)字面意思修改。
如果还要追加的话,直接复制例子的第二行,照葫芦画瓢即可。
可以添加的标签:(添加到 \color{5e72e4} 指令的前面)
-
推荐:
\footnotesize\color{ffc116}{\boxed{\textrm{荐}}}\; -
困难:
\footnotesize\color{e74c3c}{\boxed{\textrm{难}}}\; -
容易:
\footnotesize\color{94d66d}{\boxed{\textrm{易}}}\;
更多标签正在创作中,有需求在本 blog 中投稿!
$\text{最后更新:\color{gray}最后更新时间}$字面意思。
$$
\mathrlap
{
\begin{matrix}
\\\\
\kern{14em}\boxed{\color{gray}\rule{200pt}{100pt}\raisebox{100pt}{}\color{White}\raisebox{50pt}{\kern{-20em}\text{\Large159号程序员}}\raisebox{25pt}{\kern{-20em}\text{Pr.159}}}
\end{matrix}
}
{
\begin{gathered}
{\color{ForestGreen}{\textrm{159号程序员}}\atop \text{\small02-10 11:35:47}}\kern{5em}{\colorbox{Green}{\color{White}{Accepted}}\atop \color{ForestGreen}{\textrm{100}\qquad\quad\;}}\kern{4em}\kern{15mu}\color{red}{\text{P1001}\;\color{CornflowerBlue}{\text{A+B Problem}}}\kern{6em}\color{lightgray}{\text{\small3ms/804.00KB/1.25KB\,C++98}}\\\\
{\color{ForestGreen}{\textrm{159号程序员}}\atop \text{\small02-10 11:32:24}}\kern{5em}{\colorbox{Crimson}{\color{White}{Unaccepted}}\atop \color{ForestGreen}{\textrm{80}\qquad\qquad\;\;\;}}\kern{4em}\color{red}{\text{P1001}\;\color{CornflowerBlue}{\text{A+B Problem}}}\kern{6em}\color{lightgray}{\text{\small5ms/804.00KB/1.63KB\,C++98}}\\\\
{\color{ForestGreen}{\textrm{159号程序员}}\atop \text{\small02-10 11:25:15}}\kern{5em}{\colorbox{Crimson}{\color{White}{Unaccepted}}\atop \color{Crimson}{\textrm{40}\qquad\qquad\;\;\;}}\kern{4em}\color{red}{\text{P1001}\;\color{CornflowerBlue}{\text{A+B Problem}}}\kern{6em}\color{lightgray}{\text{\small7.9s/804.00KB/1.43KB\,C++98}}\\\\
{\color{ForestGreen}{\textrm{159号程序员}}\atop \text{\small02-10 11:23:56}}\kern{5em}{\colorbox{Crimson}{\color{White}{Unaccepted}}\atop \color{Crimson}{\textrm{20}\qquad\qquad\;\;\;}}\kern{4em}\color{red}{\text{P1001}\;\color{CornflowerBlue}{\text{A+B Problem}}}\kern{6em}\color{lightgray}{\text{\small3ms/804.00KB/1.60KB\,C++98}}\\\\
{\color{ForestGreen}{\textrm{159号程序员}}\atop \text{\small02-10 11:20:38}}\kern{5em}{\colorbox{Crimson}{\color{White}{Unaccepted}}\atop \color{Crimson}{\textrm{0}\qquad\qquad\;\;\;\;}}\kern{4em}\color{red}{\text{P1001}\;\color{CornflowerBlue}{\text{A+B Problem}}}\kern{6em}\color{lightgray}{\text{\small4ms/804.00KB/1.35KB\,C++98}}\\\\
{\color{ForestGreen}{\textrm{159号程序员}}\atop \text{\small02-10 11:18:09}}\kern{5em}\colorbox{MidnightBlue}{\color{White}{Waiting}}\kern{5em}\kern{16mu}\color{red}{\text{P1001}\;\color{CornflowerBlue}{\text{A+B Problem}}}\kern{5.90em}\color{lightgray}{\text{\small3ms/804.00KB/1.37KB\,C++98}}\\
\end{gathered}\\
}
$$替换用户名/提交时间即可。
如果不想要那个灰色的文本框,删掉 \mathrlap 大括号中的全部内容即可。
目前打算写写其他的提交情况,如 WA/CE 等等,先搁(鸽)着吧。



