Odilitime 11 months ago
parent
commit
4718a0620d
2 changed files with 64 additions and 0 deletions
  1. 10
    0
      doc/framework.txt
  2. 54
    0
      doc/ntrml.txt

+ 10
- 0
doc/framework.txt View File

@@ -0,0 +1,10 @@
1
+The Netrunner framework can be used to build cross-platform applications besides a browser. The framework provides:
2
+- renders (glfw/opengl, framebuffer, textual)
3
+- UI widgets
4
+- parsers (images, markup, scripting)
5
+- networking protocols (http, https, etc)
6
+
7
+The app class loads an interface defined in NTRML, our UI mark-up language that defines an interface.
8
+
9
+An app is a collection of windows. Each window has a collection of UI components and a set of callbacks. Browser extends the app class to configure the app class into a web browser.
10
+

+ 54
- 0
doc/ntrml.txt View File

@@ -0,0 +1,54 @@
1
+The NTRML (NeTRunner Markup Language) is a way to define a User Interface built with the NeTRunner framework. NTRML mimics HTML to provide some familiarity to those already familiar with HTML.
2
+
3
+Colors are defined with an 8 hexadecimal digits. First 2 are Red, next 2 are Green, next 2 are Blue and the final 2 are Alpha. An Red of FF is bright red. An alpha of FF is opaque.
4
+
5
+If a tag is marked positional below, then it supports the following attributes:
6
+
7
+You only can use 2 of the following 3 to position and size your component:
8
+height (optional) - height in pixels or percentage
9
+top (optional) - top in pixels or percentage
10
+bottom (optional) - bottom in pixels or percentage
11
+
12
+You only can use 2 of the following 3 to position and size your component:
13
+width (optional) - width in pixels or percentage
14
+left (optional) - left in pixels or percentage
15
+right (optional) - right in pixels or percentage
16
+
17
+TAGS
18
+
19
+body - wraps around everything to provide some default values
20
+body.color - set default text color
21
+body.bgcolor - set default background color
22
+
23
+layer - we draw back to front. This gives you a way to order your controls.
24
+
25
+img - renders an image
26
+img.name - label for debugging
27
+img.src - filename to load (currently only pnm/pam supported)
28
+img is positional
29
+
30
+tabSelector - where to place the tab selector
31
+tabSelector.color - set text color
32
+tabSelector.hover - set hover color
33
+tabSelector is positional
34
+
35
+box - renders a box shape
36
+box.color - shape color
37
+box.hover - hover color
38
+box.onclick - functionality if clicked
39
+box is positional
40
+
41
+input - an input box control
42
+input.color - text color
43
+input.bgcolor - background color
44
+input.onclick - functionality if clicked
45
+input.fontSize - font size in pixels
46
+input is positional
47
+
48
+font - renders text
49
+font.src - font to use (ttf supported)
50
+font.family - will eventually support web-safe fonts
51
+font.size - text size in pixels
52
+font.color - set default text color
53
+font.bgcolor - set default background color
54
+font is positional