PDF/XPS: fix content size miscalculation