From 3bea8585455b46090d73ddaacf6defe025bb8e05 Mon Sep 17 00:00:00 2001 From: Jaro Date: Mon, 1 May 2023 22:32:05 +0200 Subject: [PATCH] Qualify Plain pagination. --- src/Data/Text/ParagraphLayout/Internal/Paginable.hs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Data/Text/ParagraphLayout/Internal/Paginable.hs b/src/Data/Text/ParagraphLayout/Internal/Paginable.hs index addb412..7131a9d 100644 --- a/src/Data/Text/ParagraphLayout/Internal/Paginable.hs +++ b/src/Data/Text/ParagraphLayout/Internal/Paginable.hs @@ -10,7 +10,8 @@ import Data.Int (Int32) import Data.Text.ParagraphLayout.Internal.LinePagination import Data.Text.ParagraphLayout.Internal.ParagraphLine -import Data.Text.ParagraphLayout.Internal.Plain.ParagraphLayout +import qualified Data.Text.ParagraphLayout.Internal.Plain.ParagraphLayout + as Plain -- | Defines options for breaking a layout into pages. data PageOptions = PageOptions @@ -75,7 +76,7 @@ instance Line a => Paginable [a] where -- | Implementation of paginating a plain text paragraph layout. -- Breaks the layout on page boundaries and automatically adjusts coordinates. -instance Paginable (ParagraphLayout d) where +instance Paginable (Plain.ParagraphLayout d) where paginate opts pl = case paginate opts (cutLines pl) of (c, p, Nothing) -> (c, mergeLines p, Nothing) (c, p, Just rest) -> (c, mergeLines p, Just (mergeLines rest)) -- 2.30.2