Line width of empty buffer should be 0. Also bits refactoring.