將項目符號點指派給逐項列出的表格中的第一個儲存格

將項目符號點指派給逐項列出的表格中的第一個儲存格

我有以下 LaTeX 程式碼,用於產生簡歷的教育部分

\documentclass[a4paper,20pt]{article}

\usepackage{latexsym}
\usepackage[empty]{fullpage}
\usepackage{titlesec}
\usepackage{marvosym}
\usepackage[usenames,dvipsnames]{color}
\usepackage{verbatim}
\usepackage{enumitem}
\usepackage[pdftex]{hyperref}
\usepackage{fancyhdr}

\pagestyle{fancy}
\fancyhf{} % clear all header and footer fields
\fancyfoot{}
\renewcommand{\headrulewidth}{0pt}
\renewcommand{\footrulewidth}{0pt}

% Adjust margins
\addtolength{\oddsidemargin}{-0.530in}
\addtolength{\evensidemargin}{-0.375in}
\addtolength{\textwidth}{1in}
\addtolength{\topmargin}{-.45in}
\addtolength{\textheight}{1in}

\urlstyle{rm}

\raggedbottom
\raggedright
\setlength{\tabcolsep}{0in}

% Sections formatting
\titleformat{\section}{
  \vspace{-10pt}\scshape\raggedright\large
}{}{0em}{}[\color{black}\titlerule \vspace{-6pt}]

%-------------------------
% Custom commands
\newcommand{\resumeItem}[1]{
  \item\small{
    #1 \vspace{-2pt}
  }
}

\newcommand{\resumeItemWithoutTitle}[1]{
  \item\small{
    {\vspace{-2pt}}
  }
}

\newcommand{\resumeSubheading}[4]{
  \vspace{-1pt}\item
    \begin{tabular*}{0.97\textwidth}{l@{\extracolsep{\fill}}r}
      \textbf{#1} & #2 \\
      \textit{#3} & \textit{#4} \\
    \end{tabular*}\vspace{-5pt}
}


\newcommand{\resumeSubItem}[2]{\resumeItem{#1}{#2}\vspace{-3pt}}

\renewcommand{\labelitemii}{$\circ$}

\newcommand{\resumeSubHeadingListStart}{\begin{itemize}[leftmargin=*]}
\newcommand{\resumeSubHeadingListEnd}{\end{itemize}}
\newcommand{\resumeItemListStart}{\begin{itemize}}
\newcommand{\resumeItemListEnd}{\end{itemize}\vspace{-5pt}}

%-----------------------------
%%%%%%  RESUME STARTS HERE  %%%%%%

\begin{document}

%----------HEADING-----------------
\begin{tabular*}{\textwidth}{l@{\extracolsep{\fill}}r}
  \textbf{{\LARGE Shrey Joshi}} & Email: \href{mailto:[email protected]}{[email protected]}\\
  \href{https://shreyjoshi.com}{Website: shreyjoshi.com} & LinkedIn: \href{https://www.linkedin.com/in/sjoshi1729/}{in/sjoshi1729} | 
  \href{https://github.com/xprilion}{GitHub: ~~@shreyj1729} \\
\end{tabular*}

%-----------EDUCATION-----------------
\section{~~Education}
  \resumeSubHeadingListStart
    \resumeSubheading
      {University of Texas at Dallas}{Dallas, Texas}
      {B.S. Computer Science, AES + National Merit Full-ride Scholarship}{2022 - 2025 (Expected)}
    \resumeSubHeadingListEnd

\end{document}

但這會產生以下輸出,其中項目符號點位於兩行文字之間的中心。我怎樣才能使項目符號點僅位於第一條粗體線上?

在此輸入影像描述

答案1

[t]要重複我在評論中所寫的內容,您可以透過添加作為第二個可選參數到 tabular * 環境,將 tabular* 環境的頂部與周圍的文字對齊:

\newcommand{\resumeSubheading}[4]{
  \vspace{-1pt}\item
    \begin{tabular*}{0.97\textwidth}[t]{l@{\extracolsep{\fill}}r}
      \textbf{#1} & #2 \\
      \textit{#3} & \textit{#4} \\
    \end{tabular*}\vspace{-5pt}
}

相關內容