Commit 5513e48a authored by liukaiwen's avatar liukaiwen

add modify inline equation y axis

add false displayed equation to inline equation
parent f9f36c10
...@@ -178,6 +178,7 @@ def modify_y_axis(spans: list): ...@@ -178,6 +178,7 @@ def modify_y_axis(spans: list):
if (span_y0 < y0 and span_y > y0 or span_y0 < y1 and span_y > y1 or span_y0 < y0 and span_y > y1) and __is_overlaps_y_exceeds_threshold(span['bbox'], (0, y0, 0, y1)): if (span_y0 < y0 and span_y > y0 or span_y0 < y1 and span_y > y1 or span_y0 < y0 and span_y > y1) and __is_overlaps_y_exceeds_threshold(span['bbox'], (0, y0, 0, y1)):
span["bbox"][1] = y0 span["bbox"][1] = y0
# span["bbox"][3] = y1 # span["bbox"][3] = y1
#调整公式类型
if span["type"] == "displayed_equation": if span["type"] == "displayed_equation":
span["type"] = "inline_equation" span["type"] = "inline_equation"
break break
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment