Ok so i wrote this simple code (shown below) to create an alternate colour table using \rowcolors, yet instead of just colouring the rows of the table it colours the whole row (even more than textwidth). Any help how to fix this?
begin[ht] \scriptsize \begin \rowcolors \caption \begin | p> Filename & Contents \\ \hline \hline A & B \\ C & F \\ \end \end \end
While 0.45\textwidth + 0.55\textwidth would seem to fit within \textwidth , each of your p -columns have an extra column separation. on both sides. To that end, you should remove them in order to make it fit within the text block boundary:
\documentclass \usepackage[table] \usepackage \begin \begin[ht] \scriptsize\centering \rowcolors \caption \begin < p| p> Filename & Contents \\ \hline \hline A & B \\ C & F \end \end \lipsum[1] \end