Mercurial > projects > doodle
annotate doodle/main/prog/doodler.d @ 44:2b9329ed0f0e
Added backtrace support
author | "David Bryant <bagnose@gmail.com>" |
---|---|
date | Sun, 01 Aug 2010 02:06:14 +0930 |
parents | 1f97022e5c6d |
children | 01bbf3f6f966 |
rev | line source |
---|---|
28
1754cb773d41
Part-way through getting to compile with configure/builder.
Graham St Jack <graham.stjack@internode.on.net>
parents:
27
diff
changeset
|
1 private { |
44 | 2 import doodle.core.backtrace; |
38
452915ecd1f4
Basic logging functionality
David Bryant <bagnose@gmail.com>
parents:
35
diff
changeset
|
3 import doodle.core.logging; |
452915ecd1f4
Basic logging functionality
David Bryant <bagnose@gmail.com>
parents:
35
diff
changeset
|
4 |
28
1754cb773d41
Part-way through getting to compile with configure/builder.
Graham St Jack <graham.stjack@internode.on.net>
parents:
27
diff
changeset
|
5 import doodle.dia.tool_layer; |
1754cb773d41
Part-way through getting to compile with configure/builder.
Graham St Jack <graham.stjack@internode.on.net>
parents:
27
diff
changeset
|
6 import doodle.dia.standard_tools; |
35 | 7 import doodle.dia.grid_layer; |
28
1754cb773d41
Part-way through getting to compile with configure/builder.
Graham St Jack <graham.stjack@internode.on.net>
parents:
27
diff
changeset
|
8 import doodle.dia.page_layer; |
20 | 9 |
28
1754cb773d41
Part-way through getting to compile with configure/builder.
Graham St Jack <graham.stjack@internode.on.net>
parents:
27
diff
changeset
|
10 import doodle.gtk.canvas; |
1754cb773d41
Part-way through getting to compile with configure/builder.
Graham St Jack <graham.stjack@internode.on.net>
parents:
27
diff
changeset
|
11 import doodle.gtk.toolbar; |
27 | 12 |
20 | 13 import gtk.Main; |
14 import gtk.MainWindow; | |
27 | 15 import gtk.VBox; |
20 | 16 |
17 import std.stdio; | |
18 } | |
19 | |
20 void main(string[] args) { | |
40 | 21 trace("Test trace"); |
38
452915ecd1f4
Basic logging functionality
David Bryant <bagnose@gmail.com>
parents:
35
diff
changeset
|
22 /+ |
452915ecd1f4
Basic logging functionality
David Bryant <bagnose@gmail.com>
parents:
35
diff
changeset
|
23 trace("Test trace"); |
452915ecd1f4
Basic logging functionality
David Bryant <bagnose@gmail.com>
parents:
35
diff
changeset
|
24 info("Test trace"); |
452915ecd1f4
Basic logging functionality
David Bryant <bagnose@gmail.com>
parents:
35
diff
changeset
|
25 message("Test trace"); |
452915ecd1f4
Basic logging functionality
David Bryant <bagnose@gmail.com>
parents:
35
diff
changeset
|
26 warning("Test trace"); |
452915ecd1f4
Basic logging functionality
David Bryant <bagnose@gmail.com>
parents:
35
diff
changeset
|
27 error("Test trace"); |
452915ecd1f4
Basic logging functionality
David Bryant <bagnose@gmail.com>
parents:
35
diff
changeset
|
28 fatal("Test trace"); |
452915ecd1f4
Basic logging functionality
David Bryant <bagnose@gmail.com>
parents:
35
diff
changeset
|
29 +/ |
452915ecd1f4
Basic logging functionality
David Bryant <bagnose@gmail.com>
parents:
35
diff
changeset
|
30 |
40 | 31 trace("Test trace1"); |
20 | 32 Main.init(args); |
40 | 33 trace("Test trace2"); |
20 | 34 auto window = new MainWindow("Doodle"); |
40 | 35 trace("Test trace3"); |
27 | 36 auto vbox = new VBox(false, 0); |
40 | 37 trace("Test trace4"); |
27 | 38 auto tool_bar = new ToolBar; |
40 | 39 trace("Test trace5"); |
27 | 40 vbox.packStart(tool_bar, false, false, 0); |
20 | 41 Tool[] tools; |
42 tools ~= new PanTool; | |
43 tools ~= new ZoomTool; | |
44 tools ~= new LassoTool; | |
40 | 45 trace("Test trace4"); |
20 | 46 auto tool_layer = new ToolLayer(tools, "Tools"); |
35 | 47 auto grid_layer = new GridLayer("Grid"); |
20 | 48 Layer[] layers; |
40 | 49 trace("Test trace5"); |
20 | 50 layers ~= new PageLayer("Page"); |
35 | 51 layers ~= grid_layer; |
20 | 52 layers ~= tool_layer; |
40 | 53 trace("Test trace6"); |
35 | 54 auto canvas = new Canvas(layers, tool_layer, grid_layer, 120.0); |
40 | 55 trace("Test trace7"); |
27 | 56 vbox.packStart(canvas, true, true, 0); |
40 | 57 trace("Test trace8"); |
27 | 58 window.add(vbox); |
40 | 59 trace("Test trace9"); |
20 | 60 window.setDefaultSize(380, 380); |
61 window.showAll(); | |
40 | 62 trace("Test trace8"); |
20 | 63 Main.run(); |
64 } |