The reason for this is because the call to TCPDF_COLORS::convertHTMLColorToDec only allows these values.