I would like to create 2 commands
\newcommand\deffeat[1]...
\newcommand\reffeat[1] ...
The deffeat command would print out as something like \textbf{F001},
and the reffeat command would reference the deffeat with the same feature name plus have the exact same text.
My current experiment is using the following:
\newcounter{thefeatures}
\setcounter{thefeatures}{1}
\newcommand{\deffeat}[1]{
\phantomsection[a]
%XXX: \tag{F~\{cifeatures}}
\label{#1}
\textbf{F~\arabic{thefeatures}}
\addtocounter{thefeatures}{1}
}
It's still missing the spell the same text feature (currently I'm using \ref).
edit current state:
using cleveref
\newcounter{thefeatures}
\setcounter{thefeatures}{0}
\crefname{thefeatures}{feature}{features}
\newcommand{\deffeat}[1]{
\phantomsection
\refstepcounter{thefeatures}
\label{#1}
\textbf{F\arabic{thefeatures}}
}
\crefformat{thefeatures}{#2F#1#3}
