add some type annotations io/formats/format.py
typing not added to all function signatures in io/formats/format.py in this pass to reduce the diff

~~this PR also contains a refactor to simplify the addition of type annotations; `truncate_h` and `tr_col_num` are dependant variables. `truncate_h` can be `True` or `False`. if `True`, `tr_col_num` is an `int` else if `truncate_h` is `False`, `tr_col_num` is `None`~~

~~same applies for `truncate_v` and `tr_row_num`~~
