Sorting icons are provided if you use the built-in sorting of the EDT. if you use custom sorting, you will have to provide your own sorting icons.
I am using datatable and not EDT. Can you provide an example of how to use custom Icons. I could not find any example.
That's correct, by EDT I mean the ExtendedDataTable. If you want sort icons with custom sorting (for either the dataTable or the extendedDataTable, you will have to place them yourself using a conditionally rendered image tag. You can use the h:graphicImage tag to pull the image the richfaces library uses in the built-in sorting:
<h:graphicImage library="org.richfaces" name="sort_asc.gif" />
Another option is to create a span and give it the .rf-edt-srt-asc styleClass.
s/asc/des/ above to get the descending icon that we use.