aboutsummaryrefslogtreecommitdiff
path: root/lib/headlines.ml
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--lib/headlines.ml11
1 files changed, 9 insertions, 2 deletions
diff --git a/lib/headlines.ml b/lib/headlines.ml
index 38ff42d..d8d6c9b 100644
--- a/lib/headlines.ml
+++ b/lib/headlines.ml
@@ -42,7 +42,11 @@ let init ~goto_done_view ~goto_todos_view ~regexp =
})
-let title = I.strf ~attr:A.(st bold) "%s" "Notes" |> I.pad ~l:0 ~t:0
+let title ~tag =
+ match tag with
+ | "" -> I.strf ~attr:A.(st bold) "%s" "Notes" |> I.pad ~l:0 ~t:0
+ | a -> I.strf ~attr:A.(st bold) "%s - %s" "Notes" a |> I.pad ~l:0 ~t:0
+
let rec render
t
@@ -82,7 +86,10 @@ let rec render
(Basic.array_drop scroll content_pretty)
in
let open I in
- Array.fold_left (fun sum el -> sum </> el) (title </> dot </> output_info) elements
+ Array.fold_left
+ (fun sum el -> sum </> el)
+ (title ~tag </> dot </> output_info)
+ elements
in
Common.Term.image t img;
let content_end = Array.length content_pretty + (content_start - 1) in