\alph 计数器表示法对词汇表包有奇怪的影响

\alph 计数器表示法对词汇表包有奇怪的影响

这是一个后续问题

词汇表的数字标签如何使用手动定义的章节数(或其他章节单位)?

一个可疑的 BUG。该参数\alph在我的 MAC OSX 上无法正常工作,当计数器大于 6 时,在部分中它是 2f、2g、2h,就会出现问题。所以我必须手动使用\newcommand{\alphstring}和定义\GlsAddXdyAlphabet{alph}从 a 到 z,就像 greekstring 和 greek 一样。

mininal.tex:

我只是复制 \sectionalph{Linux}您的解决方案代码然后粘贴一段时间。

\documentclass{book}
\renewcommand\thesection{\arabic{section}}
\usepackage[counter=section,xindy]{glossaries}

\newcounter{sectionalph}
\newcounter{sectiongreek}

\renewcommand{\thesectionalph}{\thesection\alph{sectionalph}}
\renewcommand{\thesectiongreek}{\thesection\greekstring{sectiongreek}}

\newcommand{\greekstring}[1]{%
  \ifcase\value{#1}\relax
  \or
   alpha%
  \or
   beta%
  \or
   gamma%
  \or
   delta%
  \or
   epsilon%
  \or
   zeta%
  \or
   eta%
  \or
   theta%
  \or
   iota%
  \or
   kappa%
  \or
   lambda%
  \or
   mu%
  \or
   nu%
  \or
   omicron%
  \or
   pi%
  \or
   rho%
  \or
   sigma%
  \or
   tau%
  \or
   upsilon%
  \or
   phi%
  \or
   chi%
  \or
   xi%
  \or
   psi%
  \or
   omega%
  \fi
}

\GlsAddXdyCounters{sectionalph}
\GlsAddXdyCounters{sectiongreek}

\GlsAddXdyAlphabet{greek}{"alpha" "beta" "gamma" "delta"
"epsilon" "zeta" "eta" "theta" "iota" "kappa" "lambda" "mu"
"nu" "omicron" "pi" "rho" "sigma" "tau" "upsilon" "phi"
"chi" "xi" "psi" "omega"}

\GlsAddXdyLocation{sectiongreek}{
  "arabic-numbers" "greek"}

\makeglossaries

\newcommand{\sectionalph}[1]{%
  \refstepcounter{sectionalph}%
  \section*{\thesectionalph\quad #1}%
}

\newcommand{\sectiongreek}[1]{%
  \refstepcounter{sectiongreek}%
  \section*{\thesectiongreek\quad #1}%
}

\newglossaryentry{Unix}{
name={Unix},
description={a multitasking, multi-user computer operating system}
}
\newglossaryentry{Unix-like}{
name={Unix-like},
description={operating system is one that behaves in a manner
similar to a Unix system}
}
\newglossaryentry{Linux}{
name={Linux},
description={Linux was originally developed as a free operating
system}
}
\newglossaryentry{FreeBSD}{
name={FreeBSD},
description={a free Unix-like operating system, an operating system}
}
\newglossaryentry{Windows}{
name={Windows},
description={a series of graphical interface operating systems}
}
\newglossaryentry{Mobile Operating System}{
name={Mobile Operating System},
description={the operating system that operates a smartphone...}
}


\begin{document}
\section{Unix}
Unix \glsadd{Unix} (officially trademarked as UNIX, sometimes also
written as Unix) is a multitasking, multi-user computer operating
system originally developed in 1969 by a group of AT\&T employees at
Bell Labs.

\section{Unix-like}
A Unix-like \glsadd{Unix-like}(sometimes referred to as UN*X or
*nix) operating system is one that behaves in a manner similar to a
Unix system, while not necessarily conforming to or being certified
to any version of the Single UNIX Specification.

\sectionalph{Linux}
Linux \glsadd[counter=sectionalph]{Linux}was originally developed as a free operating
system for Intel x86-based personal computers. It has since been
ported to more computer hardware platforms than any other operating
system.
\sectionalph{Linux}
Linux \glsadd[counter=sectionalph]{Linux}was originally developed as a free operating
system for Intel x86-based personal computers. It has since been
ported to more computer hardware platforms than any other operating
system.
\sectionalph{Linux}
Linux \glsadd[counter=sectionalph]{Linux}was originally developed as a free operating
system for Intel x86-based personal computers. It has since been
ported to more computer hardware platforms than any other operating
system.
\sectionalph{Linux}
Linux \glsadd[counter=sectionalph]{Linux}was originally developed as a free operating
system for Intel x86-based personal computers. It has since been
ported to more computer hardware platforms than any other operating
system.
\sectionalph{Linux}
Linux \glsadd[counter=sectionalph]{Linux}was originally developed as a free operating
system for Intel x86-based personal computers. It has since been
ported to more computer hardware platforms than any other operating
system.
\sectionalph{Linux}
Linux \glsadd[counter=sectionalph]{Linux}was originally developed as a free operating
system for Intel x86-based personal computers. It has since been
ported to more computer hardware platforms than any other operating
system.
\sectionalph{Linux}
Linux \glsadd[counter=sectionalph]{Linux}was originally developed as a free operating
system for Intel x86-based personal computers. It has since been
ported to more computer hardware platforms than any other operating
system.
\sectionalph{Linux}
Linux \glsadd[counter=sectionalph]{Linux}was originally developed as a free operating
system for Intel x86-based personal computers. It has since been
ported to more computer hardware platforms than any other operating
system.
\sectionalph{Linux}
Linux \glsadd[counter=sectionalph]{Linux}was originally developed as a free operating
system for Intel x86-based personal computers. It has since been
ported to more computer hardware platforms than any other operating
system.

\sectiongreek{FreeBSD}
FreeBSD \glsadd[counter=sectiongreek]{FreeBSD} is a free Unix-like operating system
descended from AT\&T UNIX via BSD UNIX.  Although for legal reasons
FreeBSD cannot be called "UNIX".

\section{Windows}
Microsoft Windows \glsadd{Windows}is a series of graphical interface
operating systems developed, marketed, and sold by Microsoft.

\sectiongreek{Mobile Operating System}
A mobile operating system \glsadd[counter=sectiongreek]{Mobile Operating System}, also
referred to as mobile OS, is the operating system that operates a
smartphone, tablet, PDA, or other digital mobile devices.

\printglossary
\end{document}

有图片:

在此处输入图片描述 在此处输入图片描述

答案1

我认为对于您的特定文档,您必须有一个自定义的 xindy 模块。以下是一个名为的示例 xdy 文件test.xdy

;; xindy style file 'test.xdy'

; required styles

(require "tex.xdy")

; list of allowed attributes (number formats)

(define-attributes (("default"
 "glsnumberformat" 
 "sectionglsnumberformat"
 "sectionalphglsnumberformat"
 "sectiongreekglsnumberformat"
 "textrm" 
 "sectiontextrm"
 "sectionalphtextrm"
 "sectiongreektextrm"
 "textsf" 
 "sectiontextsf"
 "sectionalphtextsf"
 "sectiongreektextsf"
 "texttt" 
 "sectiontexttt"
 "sectionalphtexttt"
 "sectiongreektexttt"
 "textbf" 
 "sectiontextbf"
 "sectionalphtextbf"
 "sectiongreektextbf"
 "textmd" 
 "sectiontextmd"
 "sectionalphtextmd"
 "sectiongreektextmd"
 "textit" 
 "sectiontextit"
 "sectionalphtextit"
 "sectiongreektextit"
 "textup" 
 "sectiontextup"
 "sectionalphtextup"
 "sectiongreektextup"
 "textsl" 
 "sectiontextsl"
 "sectionalphtextsl"
 "sectiongreektextsl"
 "textsc" 
 "sectiontextsc"
 "sectionalphtextsc"
 "sectiongreektextsc"
 "emph" 
 "sectionemph"
 "sectionalphemph"
 "sectiongreekemph"
 "glshypernumber" 
 "sectionglshypernumber"
 "sectionalphglshypernumber"
 "sectiongreekglshypernumber"
 "hyperrm" 
 "sectionhyperrm"
 "sectionalphhyperrm"
 "sectiongreekhyperrm"
 "hypersf" 
 "sectionhypersf"
 "sectionalphhypersf"
 "sectiongreekhypersf"
 "hypertt" 
 "sectionhypertt"
 "sectionalphhypertt"
 "sectiongreekhypertt"
 "hyperbf" 
 "sectionhyperbf"
 "sectionalphhyperbf"
 "sectiongreekhyperbf"
 "hypermd" 
 "sectionhypermd"
 "sectionalphhypermd"
 "sectiongreekhypermd"
 "hyperit" 
 "sectionhyperit"
 "sectionalphhyperit"
 "sectiongreekhyperit"
 "hyperup" 
 "sectionhyperup"
 "sectionalphhyperup"
 "sectiongreekhyperup"
 "hypersl" 
 "sectionhypersl"
 "sectionalphhypersl"
 "sectiongreekhypersl"
 "hypersc" 
 "sectionhypersc"
 "sectionalphhypersc"
 "sectiongreekhypersc"
 "hyperemph" 
 "sectionhyperemph"
 "sectionalphhyperemph"
 "sectiongreekhyperemph")))

; user defined alphabets


 (define-alphabet "greek" ("alpha" "beta" "gamma" "delta" "epsilon" "zeta" "eta" "theta" "iota" "kappa" "lambda" "mu" "nu" "omicron" "pi" "rho" "sigma" "tau" "upsilon" "phi" "chi" "xi" "psi" "omega"))

; location class definitions

(define-location-class "section-numbers"
   ( :sep "{}{" "arabic-numbers" :sep "}" ) 
   :min-range-length 2
) 


(define-location-class "sectionalpha"
   (:sep "{}{"  "arabic-numbers" "alpha" :sep "}")) 

(define-location-class "sectiongreek"
   (:sep "{}{"  "arabic-numbers" "greek" :sep "}")) 

; define cross-reference class

(define-crossref-class "see" :unverified )
(markup-crossref-list :class "see"
   :open "\glsseeformat" :close "{}")

; define the order of the location classes
(define-location-class-order (
   "section-numbers"
   "sectionalpha"
   "sectiongreek"
   "see" ))

; define the glossary markup

(markup-index
   :open "\glossarysection[\glossarytoctitle]{\glossarytitle}\glossarypreamble
\providecommand*\glsXsectionXglsnumberformat[2]{\setentrycounter[#1]{section}\glsnumberformat{#2}}
\providecommand*\glsXsectionXtextrm[2]{\setentrycounter[#1]{section}\textrm{#2}}
\providecommand*\glsXsectionXtextsf[2]{\setentrycounter[#1]{section}\textsf{#2}}
\providecommand*\glsXsectionXtexttt[2]{\setentrycounter[#1]{section}\texttt{#2}}
\providecommand*\glsXsectionXtextbf[2]{\setentrycounter[#1]{section}\textbf{#2}}
\providecommand*\glsXsectionXtextmd[2]{\setentrycounter[#1]{section}\textmd{#2}}
\providecommand*\glsXsectionXtextit[2]{\setentrycounter[#1]{section}\textit{#2}}
\providecommand*\glsXsectionXtextup[2]{\setentrycounter[#1]{section}\textup{#2}}
\providecommand*\glsXsectionXtextsl[2]{\setentrycounter[#1]{section}\textsl{#2}}
\providecommand*\glsXsectionXtextsc[2]{\setentrycounter[#1]{section}\textsc{#2}}
\providecommand*\glsXsectionXemph[2]{\setentrycounter[#1]{section}\emph{#2}}
\providecommand*\glsXsectionXglshypernumber[2]{\setentrycounter[#1]{section}\glshypernumber{#2}}
\providecommand*\glsXsectionXhyperrm[2]{\setentrycounter[#1]{section}\hyperrm{#2}}
\providecommand*\glsXsectionXhypersf[2]{\setentrycounter[#1]{section}\hypersf{#2}}
\providecommand*\glsXsectionXhypertt[2]{\setentrycounter[#1]{section}\hypertt{#2}}
\providecommand*\glsXsectionXhyperbf[2]{\setentrycounter[#1]{section}\hyperbf{#2}}
\providecommand*\glsXsectionXhypermd[2]{\setentrycounter[#1]{section}\hypermd{#2}}
\providecommand*\glsXsectionXhyperit[2]{\setentrycounter[#1]{section}\hyperit{#2}}
\providecommand*\glsXsectionXhyperup[2]{\setentrycounter[#1]{section}\hyperup{#2}}
\providecommand*\glsXsectionXhypersl[2]{\setentrycounter[#1]{section}\hypersl{#2}}
\providecommand*\glsXsectionXhypersc[2]{\setentrycounter[#1]{section}\hypersc{#2}}
\providecommand*\glsXsectionXhyperemph[2]{\setentrycounter[#1]{section}\hyperemph{#2}}
\providecommand*\glsXsectionalphXglsnumberformat[2]{\setentrycounter[#1]{sectionalph}\glsnumberformat{#2}}
\providecommand*\glsXsectionalphXtextrm[2]{\setentrycounter[#1]{sectionalph}\textrm{#2}}
\providecommand*\glsXsectionalphXtextsf[2]{\setentrycounter[#1]{sectionalph}\textsf{#2}}
\providecommand*\glsXsectionalphXtexttt[2]{\setentrycounter[#1]{sectionalph}\texttt{#2}}
\providecommand*\glsXsectionalphXtextbf[2]{\setentrycounter[#1]{sectionalph}\textbf{#2}}
\providecommand*\glsXsectionalphXtextmd[2]{\setentrycounter[#1]{sectionalph}\textmd{#2}}
\providecommand*\glsXsectionalphXtextit[2]{\setentrycounter[#1]{sectionalph}\textit{#2}}
\providecommand*\glsXsectionalphXtextup[2]{\setentrycounter[#1]{sectionalph}\textup{#2}}
\providecommand*\glsXsectionalphXtextsl[2]{\setentrycounter[#1]{sectionalph}\textsl{#2}}
\providecommand*\glsXsectionalphXtextsc[2]{\setentrycounter[#1]{sectionalph}\textsc{#2}}
\providecommand*\glsXsectionalphXemph[2]{\setentrycounter[#1]{sectionalph}\emph{#2}}
\providecommand*\glsXsectionalphXglshypernumber[2]{\setentrycounter[#1]{sectionalph}\glshypernumber{#2}}
\providecommand*\glsXsectionalphXhyperrm[2]{\setentrycounter[#1]{sectionalph}\hyperrm{#2}}
\providecommand*\glsXsectionalphXhypersf[2]{\setentrycounter[#1]{sectionalph}\hypersf{#2}}
\providecommand*\glsXsectionalphXhypertt[2]{\setentrycounter[#1]{sectionalph}\hypertt{#2}}
\providecommand*\glsXsectionalphXhyperbf[2]{\setentrycounter[#1]{sectionalph}\hyperbf{#2}}
\providecommand*\glsXsectionalphXhypermd[2]{\setentrycounter[#1]{sectionalph}\hypermd{#2}}
\providecommand*\glsXsectionalphXhyperit[2]{\setentrycounter[#1]{sectionalph}\hyperit{#2}}
\providecommand*\glsXsectionalphXhyperup[2]{\setentrycounter[#1]{sectionalph}\hyperup{#2}}
\providecommand*\glsXsectionalphXhypersl[2]{\setentrycounter[#1]{sectionalph}\hypersl{#2}}
\providecommand*\glsXsectionalphXhypersc[2]{\setentrycounter[#1]{sectionalph}\hypersc{#2}}
\providecommand*\glsXsectionalphXhyperemph[2]{\setentrycounter[#1]{sectionalph}\hyperemph{#2}}
\providecommand*\glsXsectiongreekXglsnumberformat[2]{\setentrycounter[#1]{sectiongreek}\glsnumberformat{#2}}
\providecommand*\glsXsectiongreekXtextrm[2]{\setentrycounter[#1]{sectiongreek}\textrm{#2}}
\providecommand*\glsXsectiongreekXtextsf[2]{\setentrycounter[#1]{sectiongreek}\textsf{#2}}
\providecommand*\glsXsectiongreekXtexttt[2]{\setentrycounter[#1]{sectiongreek}\texttt{#2}}
\providecommand*\glsXsectiongreekXtextbf[2]{\setentrycounter[#1]{sectiongreek}\textbf{#2}}
\providecommand*\glsXsectiongreekXtextmd[2]{\setentrycounter[#1]{sectiongreek}\textmd{#2}}
\providecommand*\glsXsectiongreekXtextit[2]{\setentrycounter[#1]{sectiongreek}\textit{#2}}
\providecommand*\glsXsectiongreekXtextup[2]{\setentrycounter[#1]{sectiongreek}\textup{#2}}
\providecommand*\glsXsectiongreekXtextsl[2]{\setentrycounter[#1]{sectiongreek}\textsl{#2}}
\providecommand*\glsXsectiongreekXtextsc[2]{\setentrycounter[#1]{sectiongreek}\textsc{#2}}
\providecommand*\glsXsectiongreekXemph[2]{\setentrycounter[#1]{sectiongreek}\emph{#2}}
\providecommand*\glsXsectiongreekXglshypernumber[2]{\setentrycounter[#1]{sectiongreek}\glshypernumber{#2}}
\providecommand*\glsXsectiongreekXhyperrm[2]{\setentrycounter[#1]{sectiongreek}\hyperrm{#2}}
\providecommand*\glsXsectiongreekXhypersf[2]{\setentrycounter[#1]{sectiongreek}\hypersf{#2}}
\providecommand*\glsXsectiongreekXhypertt[2]{\setentrycounter[#1]{sectiongreek}\hypertt{#2}}
\providecommand*\glsXsectiongreekXhyperbf[2]{\setentrycounter[#1]{sectiongreek}\hyperbf{#2}}
\providecommand*\glsXsectiongreekXhypermd[2]{\setentrycounter[#1]{sectiongreek}\hypermd{#2}}
\providecommand*\glsXsectiongreekXhyperit[2]{\setentrycounter[#1]{sectiongreek}\hyperit{#2}}
\providecommand*\glsXsectiongreekXhyperup[2]{\setentrycounter[#1]{sectiongreek}\hyperup{#2}}
\providecommand*\glsXsectiongreekXhypersl[2]{\setentrycounter[#1]{sectiongreek}\hypersl{#2}}
\providecommand*\glsXsectiongreekXhypersc[2]{\setentrycounter[#1]{sectiongreek}\hypersc{#2}}
\providecommand*\glsXsectiongreekXhyperemph[2]{\setentrycounter[#1]{sectiongreek}\hyperemph{#2}}
\begin{theglossary}\glossaryheader~n" 
   :close "%~n\end{theglossary}\glossarypostamble~n" 
   :tree)
(markup-letter-group-list :sep "\glsgroupskip~n")
(markup-indexentry :open "\relax\glsresetentrylist~n")
(markup-locclass-list :open "{\glossaryentrynumbers{\relax "
   :sep ", " :close "}}")
(markup-locref-list :sep "\delimN ")
(markup-range :sep "\delimR ")

; define format to use for locations


(markup-locref :open "~n\glsXsectionXglsnumberformat" 
 :close "" 
 :attr "sectionglsnumberformat")
(markup-locref :open "~n\glsXsectionalphXglsnumberformat" 
 :close "" 
 :attr "sectionalphglsnumberformat")
(markup-locref :open "~n\glsXsectiongreekXglsnumberformat" 
 :close "" 
 :attr "sectiongreekglsnumberformat")
(markup-locref :open "~n\glsXsectionXtextrm" 
 :close "" 
 :attr "sectiontextrm")
(markup-locref :open "~n\glsXsectionalphXtextrm" 
 :close "" 
 :attr "sectionalphtextrm")
(markup-locref :open "~n\glsXsectiongreekXtextrm" 
 :close "" 
 :attr "sectiongreektextrm")
(markup-locref :open "~n\glsXsectionXtextsf" 
 :close "" 
 :attr "sectiontextsf")
(markup-locref :open "~n\glsXsectionalphXtextsf" 
 :close "" 
 :attr "sectionalphtextsf")
(markup-locref :open "~n\glsXsectiongreekXtextsf" 
 :close "" 
 :attr "sectiongreektextsf")
(markup-locref :open "~n\glsXsectionXtexttt" 
 :close "" 
 :attr "sectiontexttt")
(markup-locref :open "~n\glsXsectionalphXtexttt" 
 :close "" 
 :attr "sectionalphtexttt")
(markup-locref :open "~n\glsXsectiongreekXtexttt" 
 :close "" 
 :attr "sectiongreektexttt")
(markup-locref :open "~n\glsXsectionXtextbf" 
 :close "" 
 :attr "sectiontextbf")
(markup-locref :open "~n\glsXsectionalphXtextbf" 
 :close "" 
 :attr "sectionalphtextbf")
(markup-locref :open "~n\glsXsectiongreekXtextbf" 
 :close "" 
 :attr "sectiongreektextbf")
(markup-locref :open "~n\glsXsectionXtextmd" 
 :close "" 
 :attr "sectiontextmd")
(markup-locref :open "~n\glsXsectionalphXtextmd" 
 :close "" 
 :attr "sectionalphtextmd")
(markup-locref :open "~n\glsXsectiongreekXtextmd" 
 :close "" 
 :attr "sectiongreektextmd")
(markup-locref :open "~n\glsXsectionXtextit" 
 :close "" 
 :attr "sectiontextit")
(markup-locref :open "~n\glsXsectionalphXtextit" 
 :close "" 
 :attr "sectionalphtextit")
(markup-locref :open "~n\glsXsectiongreekXtextit" 
 :close "" 
 :attr "sectiongreektextit")
(markup-locref :open "~n\glsXsectionXtextup" 
 :close "" 
 :attr "sectiontextup")
(markup-locref :open "~n\glsXsectionalphXtextup" 
 :close "" 
 :attr "sectionalphtextup")
(markup-locref :open "~n\glsXsectiongreekXtextup" 
 :close "" 
 :attr "sectiongreektextup")
(markup-locref :open "~n\glsXsectionXtextsl" 
 :close "" 
 :attr "sectiontextsl")
(markup-locref :open "~n\glsXsectionalphXtextsl" 
 :close "" 
 :attr "sectionalphtextsl")
(markup-locref :open "~n\glsXsectiongreekXtextsl" 
 :close "" 
 :attr "sectiongreektextsl")
(markup-locref :open "~n\glsXsectionXtextsc" 
 :close "" 
 :attr "sectiontextsc")
(markup-locref :open "~n\glsXsectionalphXtextsc" 
 :close "" 
 :attr "sectionalphtextsc")
(markup-locref :open "~n\glsXsectiongreekXtextsc" 
 :close "" 
 :attr "sectiongreektextsc")
(markup-locref :open "~n\glsXsectionXemph" 
 :close "" 
 :attr "sectionemph")
(markup-locref :open "~n\glsXsectionalphXemph" 
 :close "" 
 :attr "sectionalphemph")
(markup-locref :open "~n\glsXsectiongreekXemph" 
 :close "" 
 :attr "sectiongreekemph")
(markup-locref :open "~n\glsXsectionXglshypernumber" 
 :close "" 
 :attr "sectionglshypernumber")
(markup-locref :open "~n\glsXsectionalphXglshypernumber" 
 :close "" 
 :attr "sectionalphglshypernumber")
(markup-locref :open "~n\glsXsectiongreekXglshypernumber" 
 :close "" 
 :attr "sectiongreekglshypernumber")
(markup-locref :open "~n\glsXsectionXhyperrm" 
 :close "" 
 :attr "sectionhyperrm")
(markup-locref :open "~n\glsXsectionalphXhyperrm" 
 :close "" 
 :attr "sectionalphhyperrm")
(markup-locref :open "~n\glsXsectiongreekXhyperrm" 
 :close "" 
 :attr "sectiongreekhyperrm")
(markup-locref :open "~n\glsXsectionXhypersf" 
 :close "" 
 :attr "sectionhypersf")
(markup-locref :open "~n\glsXsectionalphXhypersf" 
 :close "" 
 :attr "sectionalphhypersf")
(markup-locref :open "~n\glsXsectiongreekXhypersf" 
 :close "" 
 :attr "sectiongreekhypersf")
(markup-locref :open "~n\glsXsectionXhypertt" 
 :close "" 
 :attr "sectionhypertt")
(markup-locref :open "~n\glsXsectionalphXhypertt" 
 :close "" 
 :attr "sectionalphhypertt")
(markup-locref :open "~n\glsXsectiongreekXhypertt" 
 :close "" 
 :attr "sectiongreekhypertt")
(markup-locref :open "~n\glsXsectionXhyperbf" 
 :close "" 
 :attr "sectionhyperbf")
(markup-locref :open "~n\glsXsectionalphXhyperbf" 
 :close "" 
 :attr "sectionalphhyperbf")
(markup-locref :open "~n\glsXsectiongreekXhyperbf" 
 :close "" 
 :attr "sectiongreekhyperbf")
(markup-locref :open "~n\glsXsectionXhypermd" 
 :close "" 
 :attr "sectionhypermd")
(markup-locref :open "~n\glsXsectionalphXhypermd" 
 :close "" 
 :attr "sectionalphhypermd")
(markup-locref :open "~n\glsXsectiongreekXhypermd" 
 :close "" 
 :attr "sectiongreekhypermd")
(markup-locref :open "~n\glsXsectionXhyperit" 
 :close "" 
 :attr "sectionhyperit")
(markup-locref :open "~n\glsXsectionalphXhyperit" 
 :close "" 
 :attr "sectionalphhyperit")
(markup-locref :open "~n\glsXsectiongreekXhyperit" 
 :close "" 
 :attr "sectiongreekhyperit")
(markup-locref :open "~n\glsXsectionXhyperup" 
 :close "" 
 :attr "sectionhyperup")
(markup-locref :open "~n\glsXsectionalphXhyperup" 
 :close "" 
 :attr "sectionalphhyperup")
(markup-locref :open "~n\glsXsectiongreekXhyperup" 
 :close "" 
 :attr "sectiongreekhyperup")
(markup-locref :open "~n\glsXsectionXhypersl" 
 :close "" 
 :attr "sectionhypersl")
(markup-locref :open "~n\glsXsectionalphXhypersl" 
 :close "" 
 :attr "sectionalphhypersl")
(markup-locref :open "~n\glsXsectiongreekXhypersl" 
 :close "" 
 :attr "sectiongreekhypersl")
(markup-locref :open "~n\glsXsectionXhypersc" 
 :close "" 
 :attr "sectionhypersc")
(markup-locref :open "~n\glsXsectionalphXhypersc" 
 :close "" 
 :attr "sectionalphhypersc")
(markup-locref :open "~n\glsXsectiongreekXhypersc" 
 :close "" 
 :attr "sectiongreekhypersc")
(markup-locref :open "~n\glsXsectionXhyperemph" 
 :close "" 
 :attr "sectionhyperemph")
(markup-locref :open "~n\glsXsectionalphXhyperemph" 
 :close "" 
 :attr "sectionalphhyperemph")
(markup-locref :open "~n\glsXsectiongreekXhyperemph" 
 :close "" 
 :attr "sectiongreekhyperemph")

; define letter group list format

(markup-letter-group-list :sep "\glsgroupskip~n")

; letter group headings

(markup-letter-group :open-head "\glsgroupheading{"
   :close-head "}")

; additional letter groups

(define-letter-group "glsnumbers"
   :prefixes ("0" "1" "2" "3" "4" "5" "6" "7" "8" "9")
   :before "A")

; additional sort rules

现在您的文档需要进行修改,以便它不会生成自定义模块:

\documentclass{book}
\renewcommand\thesection{\arabic{section}}
\usepackage[counter=section,xindy]{glossaries}

\newcounter{sectionalph}
\newcounter{sectiongreek}

\renewcommand{\thesectionalph}{\thesection\alph{sectionalph}}
\renewcommand{\thesectiongreek}{\thesection\greekstring{sectiongreek}}

\newcommand{\greekstring}[1]{%
  \ifcase\value{#1}\relax
  \or
   alpha%
  \or
   beta%
  \or
   gamma%
  \or
   delta%
  \or
   epsilon%
  \or
   zeta%
  \or
   eta%
  \or
   theta%
  \or
   iota%
  \or
   kappa%
  \or
   lambda%
  \or
   mu%
  \or
   nu%
  \or
   omicron%
  \or
   pi%
  \or
   rho%
  \or
   sigma%
  \or
   tau%
  \or
   upsilon%
  \or
   phi%
  \or
   chi%
  \or
   xi%
  \or
   psi%
  \or
   omega%
  \fi
}

\setStyleFile{test}
\noist
\makeglossaries

\newcommand{\sectionalph}[1]{%
  \refstepcounter{sectionalph}%
  \section*{\thesectionalph\quad #1}%
}

\newcommand{\sectiongreek}[1]{%
  \refstepcounter{sectiongreek}%
  \section*{\thesectiongreek\quad #1}%
}

\newglossaryentry{Unix}{
name={Unix},
description={a multitasking, multi-user computer operating system}
}
\newglossaryentry{Unix-like}{
name={Unix-like},
description={operating system is one that behaves in a manner
similar to a Unix system}
}
\newglossaryentry{Linux}{
name={Linux},
description={Linux was originally developed as a free operating
system}
}
\newglossaryentry{FreeBSD}{
name={FreeBSD},
description={a free Unix-like operating system, an operating system}
}
\newglossaryentry{Windows}{
name={Windows},
description={a series of graphical interface operating systems}
}
\newglossaryentry{Mobile Operating System}{
name={Mobile Operating System},
description={the operating system that operates a smartphone...}
}


\begin{document}
\section{Unix}
Unix \glsadd{Unix} (officially trademarked as UNIX, sometimes also
written as Unix) is a multitasking, multi-user computer operating
system originally developed in 1969 by a group of AT\&T employees at
Bell Labs.

\section{Unix-like}
A Unix-like \glsadd{Unix-like}(sometimes referred to as UN*X or
*nix) operating system is one that behaves in a manner similar to a
Unix system, while not necessarily conforming to or being certified
to any version of the Single UNIX Specification.

\sectionalph{Linux}
Linux \glsadd[counter=sectionalph]{Linux}was originally developed as
a free operating
system for Intel x86-based personal computers. It has since been
ported to more computer hardware platforms than any other operating
system.
\sectionalph{Linux}
Linux \glsadd[counter=sectionalph]{Linux}was originally developed as
a free operating
system for Intel x86-based personal computers. It has since been
ported to more computer hardware platforms than any other operating
system.
\sectionalph{Linux}
Linux \glsadd[counter=sectionalph]{Linux}was originally developed as
a free operating
system for Intel x86-based personal computers. It has since been
ported to more computer hardware platforms than any other operating
system.
\sectionalph{Linux}
Linux \glsadd[counter=sectionalph]{Linux}was originally developed as
a free operating
system for Intel x86-based personal computers. It has since been
ported to more computer hardware platforms than any other operating
system.
\sectionalph{Linux}
Linux \glsadd[counter=sectionalph]{Linux}was originally developed as
a free operating
system for Intel x86-based personal computers. It has since been
ported to more computer hardware platforms than any other operating
system.
\sectionalph{Linux}
Linux \glsadd[counter=sectionalph]{Linux}was originally developed as
a free operating
system for Intel x86-based personal computers. It has since been
ported to more computer hardware platforms than any other operating
system.
\sectionalph{Linux}
Linux \glsadd[counter=sectionalph]{Linux}was originally developed as
a free operating
system for Intel x86-based personal computers. It has since been
ported to more computer hardware platforms than any other operating
system.
\sectionalph{Linux}
Linux \glsadd[counter=sectionalph]{Linux}was originally developed as
a free operating
system for Intel x86-based personal computers. It has since been
ported to more computer hardware platforms than any other operating
system.
\sectionalph{Linux}
Linux \glsadd[counter=sectionalph]{Linux}was originally developed as
a free operating
system for Intel x86-based personal computers. It has since been
ported to more computer hardware platforms than any other operating
system.

\sectiongreek{FreeBSD}
FreeBSD \glsadd[counter=sectiongreek]{FreeBSD} is a free Unix-like
operating system
descended from AT\&T UNIX via BSD UNIX.  Although for legal reasons
FreeBSD cannot be called "UNIX".

\section{Windows}
Microsoft Windows \glsadd{Windows}is a series of graphical interface
operating systems developed, marketed, and sold by Microsoft.

\sectiongreek{Mobile Operating System}
A mobile operating system \glsadd[counter=sectiongreek]{Mobile
Operating System}, also
referred to as mobile OS, is the operating system that operates a
smartphone, tablet, PDA, or other digital mobile devices.

\printglossary
\end{document}

您会收到一些多个位置引用警告,但您可以忽略它们。

相关内容