감동, 마음이 움직이는 것

[latex] table에 dashed line추가하기 (vertical and horizontal lines) 본문

Tips (Utility, Computer Language, and etc.)

[latex] table에 dashed line추가하기 (vertical and horizontal lines)

Struggler J. 2020. 7. 16. 17:47

먼저 horizontal은 \usepackage{arydshln} package를 사용하면 쉽게 사용할 수 있다. 

https://tex.stackexchange.com/questions/20140/can-a-table-include-a-horizontal-dashed-line

 

Can a table include a horizontal dashed line?

In a normal table, you can use the \hline command to draw a horizontal line. I am trying to make this line a dashed horizontal line. I have found the package dashrule via this answer, but this only

tex.stackexchange.com

 

\usepackage{arydshln} 


\begin{tabular}{c:c} <= colon을 이용하면 전체적으로 한 줄 vertical dashed line을 넣을 수 있다.
 a & a\\ \hdashline 	<=이건 dashedline을 한 줄 넣는거임
 a & a\\ \cdashline{1-2} <= 이건 정해진 col에만 넣는거임
\end{tabular}

 

만약 특정 영역에만 vertical dashedline을 넣고 싶다면 \multicolumn{1}{c:}을 사용하면 된다. 

\usepackage{arydshln} 


\begin{tabular}{cc} 
\multicolumn{1}{:c}{a} & a\\ \hdashline <=첫 성분앞에만 dashedline이 생긴다. 뒤에 넣고 싶으면 뒤에 :를 c뒤에 넣으면 된다. 
 a & a\\ \cdashline{1-2} 
\end{tabular}

 

https://tex.stackexchange.com/questions/291667/dash-line-between-rows-in-a-table

 

dash line between rows in a table

Why there is no dash-line between the rows s12 and s1n like between the columns s22 and s2m? Normally there should be one. What I did wrong? Thank you!! \documentclass[a4paper, fontsize=11pt]{scra...

tex.stackexchange.com