summaryrefslogtreecommitdiff
path: root/plugins/modernb/docs/skinpp.txt
blob: 0620926043451dc518395329602b1a3959ca2277 (plain)
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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
//////////////////////////////////////////////////////////////////////////
//        This is brief description of skin engine xml format           //
//////////////////////////////////////////////////////////////////////////


/************************************************************************\
				Common object description format:
--------------------------------------------------------------------------

...
	<object.name type='glyph'>
		<fonts>
			<main effort='255' color='0x000000' alpha='255' effect='none' effect.color='0x000000' effect.alpha='255' />
			<second effort='255' color='0x000000' alpha='255' effect='none' effect.color='0x000000' effect.alpha='255' />
			<third effort='255' color='0x000000' alpha='255' effect='none' effect.color='0x000000' effect.alpha='255' />
		</fonts>
		<....>
	</object.name>
...

Attributes:

 type - the type of object: possible values are 'glyph', 'solid', 'gradient', 'none'
		default is 'none'


 The 'fonts' section describes modifiers of user font. if specific attribute is not 
specified - means do not change user setted one. E.g if only 'color' attribute is 
specified - this color will be used instead of user requested.

 If several painting are occurs before text rendering - the settings will be accumulated. 
 If several same settings are will be accumulated - the last one will be used as result.
But 'effort' attribute is show the '255'-based effort of specified value (for color only) 
to be combined the old color and new one like: 
    result_color=(old_color*(255-effort)+newcolor*(effort))/255;
the resultet color will be same like this opacity effect.

Subsections:

	main - info regarding main font: Nick for contacts or groupname for groups.
	second - info about second font: Second row line for contacts or group counter
	third - info about third font:	Third row line for contacts, top color of group divider
	fourth - info about fourth font: Time for contacts or bottom color of group divider

Attributes:
 




/************************************************************************\
				Glyph object description format:
--------------------------------------------------------------------------

...
	<object.name type='glyph' opacity='255'>
		<image file="filename.png" x='0' y='0' width='0' height='0' />
		<resize top='0' left='0' bottom='0' right='0' mode='tile' />
		<....>
	</object.name>
...

The Glyph Object is described within <object.name> node. 
 Attributes: 

	opacity - object opacity, numeric, [0..255], default is 255.

The image is described in <image> subnode. 
 Attributes:

	file -	image file name relative to skin root folder, 
			default is empty - mean internal clist modern skin image.
	x, y -	top left corner of fragment on image map - default are (0,0)
	width, height - width and height of fragment image, default
			are image size minus top-left corner coordinate.

The second subnode is <resize> - describe how to fill requested area 
if glyph image is too small:
 Attributes:
	
	top, bottom, left, right- the constant margins on sides, default are 0
	mode -	the how to fill mode, 
			possible values: tile, vtile, htile, stretch - (tile both 
			directions, tile vertical, tile horizontal, stretch 
			both directions), default is 'stretch'


	
	
********** Example of skin ***************

<skin>
<!-- Skin Info (about, author, etc.) -->
		.....
		
<!-- Properties (margins, db settings) -->
	<skin.properties>
	....
	</skin.properties>
	
	<? include="./xml_file_to_be_included.xml" ?>
	
<!-- Objects (objects to be drawn) -->
	<skin.objects>		
		<object.name type='glyph' opacity='255'>
			<image file="filename.png" x='0' y='0' width='0' height='0' />
			<resize top='0' left='0' bottom='0' right='0' mode='tile' />		
			<fonts>
				<main effort='255' color='0x000000' alpha='255' effect='none' effect.color='0x000000' effect.alpha='255' />
				<second effort='255' color='0x000000' alpha='255' effect='none' effect.color='0x000000' effect.alpha='255' />
				<third effort='255' color='0x000000' alpha='255' effect='none' effect.color='0x000000' effect.alpha='255' />
			</fonts>
		</object.name>
		.....
		
	</skin.objects>	

<!-- Selectors (selector what need to be drawn) -->
	<skin.selectors>
	....
	</skin.selectors>

<!-- Buttons -->
	<skin.buttons>
	....
	</skin.buttons>
	
<!-- Row Layout (layout of row) -->
	<skin.rowlayout>
		<tr>	
			<tc valign='vcenter'>
		    		<tr valign='vcenter' halign='hcenter'>
	      				<tc valign='vcenter' halign='hcenter' draw='avatar' /> 
	      				<tc mode='layer' valign='bottom' halign='right' draw='icon' />
	      			</tr>  
		      	</rc> 
		      	<tc valign='vcenter'>
		      		<tr draw='text' />
	      			<tr draw='text2' />
      				<tr draw='text3' />
	      		</tc> 
	      		<tc mode='layer' valign='top' halign='right' draw='extra' />
		</tr>
	</skin.rowlayout>	
...
</skin>

\************************************************************************/