Well, this is somewhat a hack...
The ordered appearance of \chapter in a ToC is 'messy' considered for the request, so I stored the contentslines in a Atoc, Btoc etc. file, where each author get's his own file, however only with 26 authors. If more is to be done, alphalph package will help ;-)
The \chapter macro does no longer write an entry to the ToC, but this can changed rather easily back to the defaults.
In the end (well, at the beginning actually), the \authortableofcontents collects all the individual Atoc etc. files and shows them a row.
The vertical spacing is wrong, most likely.
\documentclass[10pt,twoside]{memoir}
\usepackage[ngerman]{babel}
\usepackage[utf8]{inputenc}
\renewcommand{\thesection}{\arabic{section}}
\setcounter{secnumdepth}{3} % Subsection mit Zähler (1.1) versehen
%%
% Kolumnentitel
%%
\renewcommand{\chaptermark}[1]{ \markboth{#1}{} } % Stil der Kopfzeile zurücksetzen
\renewcommand{\sectionmark}[1]{ \markright{#1}{} } % Stil der Kopfzeile
% Page style
\makepagestyle{mystyle}
\makeevenhead{mystyle}{\thepage}{\small\chapterauthor}{}
\makeoddhead{mystyle}{}{\slshape\leftmark}{\thepage}
\pagestyle{mystyle}
%%
% Inhaltsverzeichnis
%%
\renewcommand*{\cftchapterdotsep}{\cftdotsep}
\settocdepth{chapter}
\renewcommand{\cftchapterfont}{\normalfont}
\renewcommand{\cftchapterpagefont}{\normalfont}
\usepackage{blindtext}
%%%%% My additions and changes
\usepackage{xpatch}
\usepackage{morewrites}
\usepackage{totcount}
\usepackage{etoolbox}
\listgadd{\authortoclist}{}
\newtotcounter{authorcounter}
\newcounter{dummycounter}
\newcounter{realposition}
\newcommand{\grabitem}[2]{%
\stepcounter{dummycounter}
\ifstrequal{#1}{#2}{%
\setcounter{realposition}{\number\value{dummycounter}}
\listbreak
}{%
}%
}
\makeatletter
\DeclareRobustCommand\authortoctext[1]{%
{\addvspace{10pt}\nopagebreak\leftskip0em\relax
\rightskip \@tocrmarg\relax
\noindent\itshape#1\par\addvspace{-7pt}}}
\newcommand\authortoc[1]{%
\xifinlistcs{#1}{authortoclist}{% Does have been there already?
\setcounter{dummycounter}{0}
\forlistloop{\grabitem{#1}}{\authortoclist}
\typeout{found at \number\value{realposition}}
}{%
\gdef\chapterauthor{#1}% Nope, new author name.
\refstepcounter{authorcounter}%
\setcounter{realposition}{\number\value{authorcounter}}
\listgadd{\authortoclist}{#1}
\addtocontents{\Alph{realposition}toc}{\authortoctext{#1}}
}%
}
%%% Kicking the chapter to the toc entry
\xpatchcmd{\@chapter}{%
\addcontentsline{toc}{chapter}{%
\protect\chapternumberline{\thechapter}\f@rtoc}%
}{%
\addcontentsline{\Alph{realposition}toc}{chapter}{%
\protect\chapternumberline{\thechapter}\f@rtoc}%
}{}{}
\usepackage{forloop}
\newcommand{\authortableofcontents}{%
\chapter*{\contentsname
\@mkboth{%
\MakeUppercase\contentsname}{\MakeUppercase\contentsname}}%
\forloop{dummycounter}{1}{\value{dummycounter} < \numexpr\totvalue{authorcounter}+1}{%
\@starttoc{\@Alph\c@dummycounter toc}%
}%
}
%%% End of my additions
\makeatother
\begin{document}
%\tableofcontents*
\authortableofcontents
\authortoc{Walter von der Vogelweide}
\chapter{Ich sass uf eynem Steine?}
\section{Und dachte Bein mit Beine}
\Blindtext\Blindtext\Blindtext\Blindtext
\authortoc{Hartmann von Aue}
\chapter[Was auch immer]{So gebt nur mehr und immer mehr}
\section{Moralische Quellen der Irrationalitat}
\Blindtext\Blindtext\Blindtext\Blindtext
\authortoc{Walter von der Vogelweide}
\chapter[Unter der Linden]{Unter der Linden an der Heide}
\section{Text}
\begin{quote}
Under der linden
an der heide,
dâ unser zweier bette was,
dâ muget ir vinden
schône beide
gebrochen bluomen unde gras.
Vor dem walde in einem tal,
tandaradei,
schône sanc diu nahtegal.
\end{quote}
\authortoc{Hartmann von Aue}
\chapter{Der arme Heinrich}
\section{Text}
\blindtext
\authortoc{Walter von der Vogelweide}
\chapter{Daz sluezzelin}
du bist mîn ich bin dîn
des solt dû gewis sîn
dû bist beslozzen
in mînem herzen
verlorn ist daz slüzzelîn
dû muost immer drinne sîn
\authortoc{Shakespeare}
\chapter{Hamlet}
\end{document}

Edit A better version
Changes compared to the 1st version:
- Added the
\authortocname which means the heading name of the author toc content --> change with \renewcommand{\authortocname}{...} so something more appropiate
- The
\sections etc. can appear in the author toc now too
- The number of authors isn't any longer limited to 26, since each author defines a number and the ending is
.1toc, .2toc, etc.
- It works with
hyperref as long that package is loaded after all patching to \chapter etc. have been made.
\documentclass[10pt,twoside]{book}
\usepackage[ngerman]{babel}
\usepackage[utf8]{inputenc}
\usepackage{blindtext}
%%%%% My additions and changes
\usepackage{xpatch}
\usepackage{morewrites}
\usepackage{totcount}
\usepackage{etoolbox}
\newtoggle{authortoconly}
\togglefalse{authortoconly} % Set \toggletrue{authortoconly} if the chapters etc. and sections should not appear in the toc as well
\makeatletter
\listcsgadd{authortoclist}{} % This holds a list of author names
\newcommand{\addauthortolist}[2][authortoclist]{% % wrapper command to add names to the author list
\listcsgadd{#1}{#2}% %
}
% A command to generate the toc ending
\newcommand{\authortoc@@tocname}[1]{%
\arabic{#1}toc%
}
\newtotcounter{authorcounter}
% Helper counters
\newcounter{authtoc@@dummycounter}
\newcounter{authtoc@@position}
% Get the position of an author in the list
\newcommand{\authtoc@@getauthornumber}[2]{%
\stepcounter{authtoc@@dummycounter}%
\ifstrequal{#1}{#2}{%
\setcounter{authtoc@@position}{\number\value{authtoc@@dummycounter}}
\listbreak
}{%
}%
}
% From the original O.P.
\DeclareRobustCommand\authortoctext[1]{%
{\addvspace{10pt}\nopagebreak\leftskip0em\relax
\rightskip \@tocrmarg\relax
\noindent\itshape#1\par\addvspace{-7pt}}}
\newcommand{\authortoc}[1]{%
\xifinlistcs{#1}{authortoclist}{% Is the author already known?
\setcounter{authtoc@@dummycounter}{0}%
\forlistcsloop{\authtoc@@getauthornumber{#1}}{authortoclist}% loop through the names
}{% Nope, the author has not been specified so far
\refstepcounter{authorcounter}%
\addauthortolist[authortoclist]{#1}% Store the author name
\setcounter{authtoc@@position}{\number\value{authorcounter}}% Set the toc file to the author number
\addtocontents{\authortoc@@tocname{authtoc@@position}}{\authortoctext{#1}}% Add the author name to the relevant author toc file
}%
}
%%% Enabling chapters making additional entries to other tocs
\xpatchcmd{\@chapter}{%
\addcontentsline{toc}{chapter}{%
\protect\numberline{\thechapter}#1}%
}{%
\nottoggle{authortoconly}{%
\addcontentsline{toc}{chapter}{%
\protect\numberline{\thechapter}#1}%
}{}%
\addcontentsline{\authortoc@@tocname{authtoc@@position}}{chapter}{%
\protect\numberline{\thechapter}#1}%
}{}{}
\xpatchcmd{\@sect}{%
\addcontentsline{toc}{#1}{%
\ifnum #2>\c@secnumdepth \else
\protect\numberline{\csname the#1\endcsname}%
\fi
#7}%
}{%
\nottoggle{authortoconly}{%
\addcontentsline{toc}{#1}{%
\ifnum #2>\c@secnumdepth \else
\protect\numberline{\csname the#1\endcsname}%
\fi
#7}%
}{}%
\addcontentsline{\authortoc@@tocname{authtoc@@position}}{#1}{%
\ifnum #2>\c@secnumdepth \else
\protect\numberline{\csname the#1\endcsname}%
\fi
#7}%
}{\typeout{Patched @sect}}{}
\newcommand{\authortocname}{Autoreninhaltsverzeichnis}
% This is the standard latex kernel \@starttoc, it's not necessary if `book.cls` is used, but for `memoir.cls` etc.
\def\latex@starttoc#1{%
\begingroup
\makeatletter
\@input{\jobname.#1}%
\if@filesw
\expandafter\newwrite\csname tf@#1\endcsname
\immediate\openout \csname tf@#1\endcsname \jobname.#1\relax
\fi
\@nobreakfalse
\endgroup
}
\newcommand{\authortableofcontents}{%
\chapter*{\authortocname
\@mkboth{%
\MakeUppercase\contentsname}{\MakeUppercase\contentsname}}%
\setcounter{authtoc@@dummycounter}{0}%
\loop
\ifnum\value{authtoc@@dummycounter} < \numexpr\totvalue{authorcounter}
\stepcounter{authtoc@@dummycounter}%
\latex@starttoc{\authortoc@@tocname{authtoc@@dummycounter}}%
\repeat%
}
\makeatother
\renewcommand{\thesection}{\arabic{section}}
\setcounter{secnumdepth}{3}
\setcounter{tocdepth}{2}
\usepackage[bookmarksopen=true,bookmarksnumbered=true]{hyperref}
\usepackage{bookmark}
%%% End of my additions
\begin{document}
\tableofcontents
\authortableofcontents
\authortoc{Walter von der Vogelweide}
\chapter{Ich sass uf eynem Steine?}
\section{Und dachte Bein mit Beine}
\Blindtext\Blindtext\Blindtext\Blindtext
\authortoc{Hartmann von Aue}
\chapter[Was auch immer]{So gebt nur mehr und immer mehr}
\section{Moralische Quellen der Irrationalitat}
\Blindtext\Blindtext\Blindtext\Blindtext
\authortoc{Walter von der Vogelweide}
\chapter[Unter der Linden]{Unter der Linden an der Heide}
\section{Text}
\begin{quote}
Under der linden
an der heide,
dâ unser zweier bette was,
dâ muget ir vinden
schône beide
gebrochen bluomen unde gras.
Vor dem walde in einem tal,
tandaradei,
schône sanc diu nahtegal.
\end{quote}
\authortoc{Hartmann von Aue}
\chapter{Der arme Heinrich}
\section{Text}
\blindtext
\authortoc{Walter von der Vogelweide}
\chapter{Daz sluezzelin}
du bist mîn ich bin dîn
des solt dû gewis sîn
dû bist beslozzen
in mînem herzen
verlorn ist daz slüzzelîn
dû muost immer drinne sîn
\authortoc{Shakespeare}
\chapter{Hamlet}
\section{The meaning of Brontosaurs to Shakespeare}
\subsection{Miss Ann Elk}
\end{document}
\addtocontentsis not difficult, grouping the chapters for the same author is a problem! Are you sticking to the code above? – Jul 26 '15 at 15:30memoiris a little bit tricky ;-) – Jul 26 '15 at 16:34