Framextopmargin이 작동하지 않습니다.lists.sty

Framextopmargin이 작동하지 않습니다.lists.sty

시도

\documentclass{article}
\usepackage{xcolor,listings}

\usepackage{showframe}
\begin{document}

\lstset{%
    frame=leftline,%
    framerule=3pt,%
framextopmargin=20pt,
    rulecolor=\color{black!60},%
        extendedchars=true,%
    columns=fixed,%
    basicstyle=\tt\footnotesize,%
    keywordstyle=\tt\bfseries,%
        showstringspaces=false,%
        showspaces=false,%
        tabsize=2,%
    breaklines,
breakatwhitespace,%
        showtabs=false,%
        captionpos=b,
    backgroundcolor=\color{black!10},%
}

\noindent
\begin{lstlisting}[framextopmargin=120pt,language=python,caption={Example of a textual specification for a traditional software function as common in software projects, describing what the function does and how to compute the results (pointing to another document for details in this case). A developer can implement this function according to the specification, without needing to understand the rest of the system. Another developer working on another part of the system can rely on this function without having access to its implementation.}]
def compute_deductions(agi, expenses):
    """
    Compute deductions based on provided adjusted gross income
    and expenses in customer data.

    See tax code 26 U.S. Code A.1.B, PART VI.

    Adjusted gross income must be a positive value.
    Returns computed deduction value.
    """
\end{lstlisting}

\end{document}

이 예에서는 framextopmargin=20pt,제대로 작동하지 않습니다.

관련 정보