(6)The costs of and incidental to all proceedings before [a Judicial Magistrate of the first class or Metropolitan Magistrate] [ Substituted by Act 12 of 1983, Section 17 and Schedule, for " the Magistrate" (w.e.f. 18.5.1983).] or the High Court under this section shall be in the discretion of [such Magistrate] [ Substituted by Act 12 of 1983, Section 17 and Schedule, for " a Magistrate" (w.e.f. 18.5.1983).] or the High Court, and [such Magistrate] [Substituted by Act 12 of 1983, Section 17 and Schedule, for " the Magistrate" (w.e.f. 18.5.1983).] or the High Court shall have full power to determine by whom or out of what property and to what extent such costs are to be paid and to give all necessary directions for the purpose aforesaid.