calculate width of line numbers, add filter to search variables