ReadingOrderSettings
Settings for ReadingOrder. Values fall back through three levels: document → SDK → built-in default. Writes target the document only when set on a document’s settings, otherwise the SDK globally when set on SdkSettings.
Tags: Advanced, Vision
from nutrient_sdk import ReadingOrderSettingsConstruction
ReadingOrderSettings is accessed through a Document instance for per-document overrides, or via SdkSettings for SDK-wide defaults.
# Per-document overridewith Document.open("input.pdf") as doc: settings = doc.settings.reading_order_settings settings.some_field = new_value # mutate fields directly
# SDK-wide default (applies to all documents)SdkSettings.reading_order_settings.some_field = new_valueSettings are configured by writing to fields on the returned object. The settings property itself cannot be reassigned — doc.settings.reading_order_settings = other_settings is rejected.
Properties
horizontal_dilation_threshold
@propertydef horizontal_dilation_threshold(self) -> float
@horizontal_dilation_threshold.setterdef horizontal_dilation_threshold(self, value: float) -> NoneHorizontal dilation threshold for column detection (normalized by page width). Default is 0.15 (15% of page width). Increase for wider column detection tolerance, decrease for stricter column boundaries.
Type: float
Default: 0.15f
text_direction
@propertydef text_direction(self) -> TextDirection
@text_direction.setterdef text_direction(self, value: TextDirection) -> NoneText direction for reading order computation. Determines how elements are sorted and ordered on the page.
Type: TextDirection
Default: TextDirection.LeftToRightTopToBottom