Skip to content
This repository has been archived by the owner on Jun 4, 2019. It is now read-only.

Commit

Permalink
visual: when in layer mode in we know we gonna draw stuff in microlev…
Browse files Browse the repository at this point in the history
…el then redraw a white rectangle that will erase the macrolevel one
  • Loading branch information
pad committed Nov 11, 2010
1 parent 150f469 commit a5b6c20
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion visual/draw_microlevel.ml
Expand Up @@ -232,6 +232,13 @@ let draw_content2 ~cr ~layout ~context ~file rect =

if font_size_real > Style.threshold_draw_dark_background_font_size_real
then begin

(* erase what was done at the macrolevel *)
if Hashtbl.length context.layers_microlevel > 0 then begin
Draw_macrolevel.draw_treemap_rectangle ~cr ~color:(Some "white")
~alpha:1.0 rect;
end;

let alpha =
match context.nb_rects_on_screen with
| n when n <= 2 -> 0.8
Expand All @@ -246,7 +253,7 @@ let draw_content2 ~cr ~layout ~context ~file rect =
(* draw a thin rectangle with aspect color *)
CairoH.draw_rectangle_bis ~cr ~color:(rect.T.tr_color)
~line_width:(font_size / 2.) rect.T.tr_rect;
end;
end
end;

(* highlighting layers (and grep-like queries) *)
Expand Down

0 comments on commit a5b6c20

Please sign in to comment.