Why is the president presiding over a judicial proceeding?
Where?
In the beginning of ST4, there is no judicial proceeding - there's a diplomatic meeting of some sort, with both UFP and Klingon top representatives present.
In the end of ST4, there is no judicial proceeding - the President of the UFP has come to cancel it, as he has used his powers (perhaps direct judicial, but more probably practical political ones) to get all charges dropped.
Timo Saloniemi