File: Constants.hs

package info (click to toggle)
threadscope 0.2.3-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 536 kB
  • ctags: 1
  • sloc: haskell: 5,337; makefile: 7
file content (63 lines) | stat: -rw-r--r-- 1,415 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
module GUI.Timeline.Render.Constants (
    ox, firstTraceY, tracePad,
    hecTraceHeight, hecInstantHeight, hecSparksHeight,
    hecBarOff, hecBarHeight, hecLabelExtra,
    activityGraphHeight, stdHistogramHeight, histXScaleHeight,
    ticksHeight, ticksPad
  ) where

-------------------------------------------------------------------------------

-- The standard gap in various graphs

ox :: Int
ox = 10

-- Origin for traces

firstTraceY :: Int
firstTraceY = 13

-- Gap betweem traces in the timeline view

tracePad :: Int
tracePad = 20

-- HEC bar height

hecTraceHeight, hecInstantHeight, hecBarHeight, hecBarOff, hecLabelExtra :: Int

hecTraceHeight   = 40
hecInstantHeight = 25
hecBarHeight     = 20
hecBarOff        = 10

-- extra space to allow between HECs when labels are on.
-- ToDo: should be calculated somehow
hecLabelExtra  = 80

-- Activity graph

activityGraphHeight :: Int
activityGraphHeight = 100

-- Height of the spark graphs.
hecSparksHeight :: Int
hecSparksHeight = activityGraphHeight

-- Histogram graph height when displayed with other traces (e.g., in PNG/PDF).
stdHistogramHeight :: Int
stdHistogramHeight = hecSparksHeight

-- The X scale of histogram has this constant height, as opposed
-- to the timeline X scale, which takes its height from the .ui file.
histXScaleHeight :: Int
histXScaleHeight = 30

-- Ticks

ticksHeight :: Int
ticksHeight = 20

ticksPad :: Int
ticksPad = 20