uidesigner/com.nokia.sdt.test.componentlibrary/components/testing/render_visual.js
author tzelaw
Tue, 14 Apr 2009 15:03:19 -0500
changeset 94 d74b720418db
parent 2 d760517a8095
permissions -rw-r--r--
Test framework support: Ask debugger to remember DebugTarget so test framework can use it to setup test framework related utility. With this we can use the DebugUI way of launching while keeping test framework functionality
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
2
cawthron
parents:
diff changeset
     1
/*
cawthron
parents:
diff changeset
     2
* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
cawthron
parents:
diff changeset
     3
* All rights reserved.
cawthron
parents:
diff changeset
     4
* This component and the accompanying materials are made available
cawthron
parents:
diff changeset
     5
* under the terms of the License "Eclipse Public License v1.0"
cawthron
parents:
diff changeset
     6
* which accompanies this distribution, and is available
cawthron
parents:
diff changeset
     7
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
cawthron
parents:
diff changeset
     8
*
cawthron
parents:
diff changeset
     9
* Initial Contributors:
cawthron
parents:
diff changeset
    10
* Nokia Corporation - initial contribution.
cawthron
parents:
diff changeset
    11
*
cawthron
parents:
diff changeset
    12
* Contributors:
cawthron
parents:
diff changeset
    13
*
cawthron
parents:
diff changeset
    14
* Description: 
cawthron
parents:
diff changeset
    15
*
cawthron
parents:
diff changeset
    16
*/
cawthron
parents:
diff changeset
    17
cawthron
parents:
diff changeset
    18
/*
cawthron
parents:
diff changeset
    19
 * Render test
cawthron
parents:
diff changeset
    20
 *
cawthron
parents:
diff changeset
    21
 * globals available are:
cawthron
parents:
diff changeset
    22
 *
cawthron
parents:
diff changeset
    23
 *		instance (WrappedInstance)
cawthron
parents:
diff changeset
    24
 *		parent (WrappedInstance)
cawthron
parents:
diff changeset
    25
 *		children (WrappedInstance[])
cawthron
parents:
diff changeset
    26
 *		
cawthron
parents:
diff changeset
    27
 * rendering globals:
cawthron
parents:
diff changeset
    28
 *		graphics (wrapped SWT GC)
cawthron
parents:
diff changeset
    29
 *		Colors (object from which getColor(r,g,b) is available)
cawthron
parents:
diff changeset
    30
 *		Fonts (object from which getFont("path") is available)
cawthron
parents:
diff changeset
    31
 *		Images (object from which newImage(device,w,h) is available)
cawthron
parents:
diff changeset
    32
 */
cawthron
parents:
diff changeset
    33
cawthron
parents:
diff changeset
    34
include("library.js")
cawthron
parents:
diff changeset
    35
cawthron
parents:
diff changeset
    36
function Visual() {
cawthron
parents:
diff changeset
    37
}
cawthron
parents:
diff changeset
    38
cawthron
parents:
diff changeset
    39
function detailedDraw(string, x, y) {
cawthron
parents:
diff changeset
    40
	var extent = graphics.stringExtent(string)
cawthron
parents:
diff changeset
    41
	var metrics = graphics.getFontMetrics()
cawthron
parents:
diff changeset
    42
	var orig = graphics.getForeground()
cawthron
parents:
diff changeset
    43
	
cawthron
parents:
diff changeset
    44
	var hy = y + metrics.getHeight() 
cawthron
parents:
diff changeset
    45
cawthron
parents:
diff changeset
    46
	var origbk = graphics.getBackground()
cawthron
parents:
diff changeset
    47
	graphics.setBackground(Colors.getColor(192,192,192))
cawthron
parents:
diff changeset
    48
	graphics.fillRectangle(x, hy-metrics.getAscent(), extent.x, metrics.getAscent()+metrics.getDescent()+metrics.getLeading())
cawthron
parents:
diff changeset
    49
	graphics.setBackground(origbk)
cawthron
parents:
diff changeset
    50
	
cawthron
parents:
diff changeset
    51
		
cawthron
parents:
diff changeset
    52
	java.lang.System.out.println("height="+metrics.getHeight()+
cawthron
parents:
diff changeset
    53
		" descent="+metrics.getDescent()+
cawthron
parents:
diff changeset
    54
		" ascent="+metrics.getAscent())
cawthron
parents:
diff changeset
    55
	graphics.setLineDash(new Array(1,1))
cawthron
parents:
diff changeset
    56
	
cawthron
parents:
diff changeset
    57
	// baseline (green)
cawthron
parents:
diff changeset
    58
	graphics.setForeground(Colors.getColor(0, 255, 0))
cawthron
parents:
diff changeset
    59
	graphics.drawLine(x, hy, x+extent.x, hy)
cawthron
parents:
diff changeset
    60
cawthron
parents:
diff changeset
    61
	// descent (cyan)
cawthron
parents:
diff changeset
    62
	graphics.setForeground(Colors.getColor(0, 255, 255))
cawthron
parents:
diff changeset
    63
	graphics.drawLine(x+1, hy+metrics.getDescent(), x+extent.x, hy+metrics.getDescent())
cawthron
parents:
diff changeset
    64
cawthron
parents:
diff changeset
    65
	// ascent (yellow)
cawthron
parents:
diff changeset
    66
	graphics.setForeground(Colors.getColor(255, 255, 0))
cawthron
parents:
diff changeset
    67
	graphics.drawLine(x, hy-metrics.getAscent(), x+extent.x, hy-metrics.getAscent())
cawthron
parents:
diff changeset
    68
cawthron
parents:
diff changeset
    69
	// height (red)
cawthron
parents:
diff changeset
    70
	graphics.setForeground(Colors.getColor(255, 0, 0))
cawthron
parents:
diff changeset
    71
	graphics.drawLine(x+1, y, x+extent.x, y)
cawthron
parents:
diff changeset
    72
cawthron
parents:
diff changeset
    73
	graphics.setLineDash(null)
cawthron
parents:
diff changeset
    74
cawthron
parents:
diff changeset
    75
	graphics.setForeground(orig)
cawthron
parents:
diff changeset
    76
	graphics.drawString(string, x, y)	
cawthron
parents:
diff changeset
    77
	
cawthron
parents:
diff changeset
    78
	
cawthron
parents:
diff changeset
    79
	return extent.y
cawthron
parents:
diff changeset
    80
}
cawthron
parents:
diff changeset
    81
cawthron
parents:
diff changeset
    82
Visual.prototype.getPattern = function(type) {
cawthron
parents:
diff changeset
    83
	if (this.image3 == null) {
cawthron
parents:
diff changeset
    84
		this.image3 = Images.newImage(graphics.getDevice(), 3, 3)
cawthron
parents:
diff changeset
    85
	}
cawthron
parents:
diff changeset
    86
	if (this.image4 == null) {
cawthron
parents:
diff changeset
    87
		this.image4 = Images.newImage(graphics.getDevice(), 4, 4)
cawthron
parents:
diff changeset
    88
	}
cawthron
parents:
diff changeset
    89
	
cawthron
parents:
diff changeset
    90
	type = Math.floor(type)
cawthron
parents:
diff changeset
    91
	var img;
cawthron
parents:
diff changeset
    92
	if (type != 8.0 && type != 3.0 && type != 5.0)
cawthron
parents:
diff changeset
    93
		img = this.image3
cawthron
parents:
diff changeset
    94
	else
cawthron
parents:
diff changeset
    95
		img = this.image4
cawthron
parents:
diff changeset
    96
		
cawthron
parents:
diff changeset
    97
	var gc = new GC(graphics.getDevice(), img)
cawthron
parents:
diff changeset
    98
cawthron
parents:
diff changeset
    99
	gc.setBackground(Colors.getColor(255, 255, 255))
cawthron
parents:
diff changeset
   100
	gc.fillRectangle(0, 0, 4, 4);
cawthron
parents:
diff changeset
   101
	gc.setBackground(Colors.getColor(255, 255,255))
cawthron
parents:
diff changeset
   102
	gc.setForeground(Colors.getColor(0, 0, 0))
cawthron
parents:
diff changeset
   103
	
cawthron
parents:
diff changeset
   104
	switch (type) {
cawthron
parents:
diff changeset
   105
	case 1: // solid
cawthron
parents:
diff changeset
   106
	default:
cawthron
parents:
diff changeset
   107
		gc.setBackground(Colors.getColor(0, 0, 0))
cawthron
parents:
diff changeset
   108
		gc.fillRectangle(0, 0, 5, 5); 
cawthron
parents:
diff changeset
   109
		break;
cawthron
parents:
diff changeset
   110
	case 3: // vertical hatch
cawthron
parents:
diff changeset
   111
		gc.drawLine(1, 0, 1, 3); 
cawthron
parents:
diff changeset
   112
		gc.drawLine(3, 0, 3, 3); 
cawthron
parents:
diff changeset
   113
		break;
cawthron
parents:
diff changeset
   114
	case 4: // forward diagonal hatch
cawthron
parents:
diff changeset
   115
		gc.drawLine(0, 2, 2, 0); 
cawthron
parents:
diff changeset
   116
		break;
cawthron
parents:
diff changeset
   117
	case 5: // horizontal hatch
cawthron
parents:
diff changeset
   118
		gc.drawLine(0, 1, 3, 1);
cawthron
parents:
diff changeset
   119
		gc.drawLine(0, 3, 3, 3);
cawthron
parents:
diff changeset
   120
		break;
cawthron
parents:
diff changeset
   121
	case 6: // rearward diagonal hatch
cawthron
parents:
diff changeset
   122
		gc.drawLine(0, 0, 2, 2);
cawthron
parents:
diff changeset
   123
		break;
cawthron
parents:
diff changeset
   124
	case 7: // square cross hatch
cawthron
parents:
diff changeset
   125
		gc.drawLine(1, 0, 1, 3);
cawthron
parents:
diff changeset
   126
		gc.drawLine(0, 1, 3, 1);
cawthron
parents:
diff changeset
   127
		break;
cawthron
parents:
diff changeset
   128
	case 8: // diamond cross hatch
cawthron
parents:
diff changeset
   129
		gc.drawLine(0, 0, 3, 3); 
cawthron
parents:
diff changeset
   130
		gc.drawLine(2, 0, 0, 2);
cawthron
parents:
diff changeset
   131
		break;
cawthron
parents:
diff changeset
   132
	}
cawthron
parents:
diff changeset
   133
	
cawthron
parents:
diff changeset
   134
	gc.dispose()
cawthron
parents:
diff changeset
   135
	
cawthron
parents:
diff changeset
   136
	return new Pattern(graphics.getDevice(), img)
cawthron
parents:
diff changeset
   137
}
cawthron
parents:
diff changeset
   138
cawthron
parents:
diff changeset
   139
Visual.prototype.draw = function(instance, laf, graphics) {
cawthron
parents:
diff changeset
   140
	var properties = instance.properties
cawthron
parents:
diff changeset
   141
	var width = properties["size"].width;
cawthron
parents:
diff changeset
   142
	var height = properties.size["height"]
cawthron
parents:
diff changeset
   143
cawthron
parents:
diff changeset
   144
	var base = "data/s60"
cawthron
parents:
diff changeset
   145
	//var base = "c:/downloads"
cawthron
parents:
diff changeset
   146
	var thickness;
cawthron
parents:
diff changeset
   147
	
cawthron
parents:
diff changeset
   148
	var r,p,x,y,size,border;
cawthron
parents:
diff changeset
   149
	
cawthron
parents:
diff changeset
   150
	switch (properties.appearance) {
cawthron
parents:
diff changeset
   151
	case 0:
cawthron
parents:
diff changeset
   152
	default:
cawthron
parents:
diff changeset
   153
		thickness = 1;
cawthron
parents:
diff changeset
   154
		graphics.setLineWidth(thickness)
cawthron
parents:
diff changeset
   155
		graphics.setForeground(getBlue())
cawthron
parents:
diff changeset
   156
		graphics.setBackground(Colors.getColor(255, 255, 255))
cawthron
parents:
diff changeset
   157
		
cawthron
parents:
diff changeset
   158
		graphics.fillGradientRectangle(0, 0, properties.size.width, properties.size.height, true)
cawthron
parents:
diff changeset
   159
		break;
cawthron
parents:
diff changeset
   160
	case 1:
cawthron
parents:
diff changeset
   161
		thickness = 2;
cawthron
parents:
diff changeset
   162
		graphics.setLineWidth(thickness)
cawthron
parents:
diff changeset
   163
	
cawthron
parents:
diff changeset
   164
		r = new Rectangle(width/2, height/2, width/2-4, height/2-4)
cawthron
parents:
diff changeset
   165
		
cawthron
parents:
diff changeset
   166
		graphics.setForeground(Colors.getColor(48, 64, 64))
cawthron
parents:
diff changeset
   167
		graphics.setLineWidth(2)
cawthron
parents:
diff changeset
   168
		graphics.drawRectangle(r)			
cawthron
parents:
diff changeset
   169
		break;
cawthron
parents:
diff changeset
   170
	case 2:
cawthron
parents:
diff changeset
   171
		r = new Rectangle(0, 0, width, height)
cawthron
parents:
diff changeset
   172
		
cawthron
parents:
diff changeset
   173
		graphics.setForeground(Colors.getColor(0, 0, 64))
cawthron
parents:
diff changeset
   174
		graphics.setLineWidth(2)
cawthron
parents:
diff changeset
   175
		graphics.drawRectangle(r)			
cawthron
parents:
diff changeset
   176
		break;
cawthron
parents:
diff changeset
   177
	case 3:
cawthron
parents:
diff changeset
   178
		// ensure Path is available
cawthron
parents:
diff changeset
   179
		p = new Path(graphics.getDevice())
cawthron
parents:
diff changeset
   180
		p.moveTo(width/2, 0)
cawthron
parents:
diff changeset
   181
		p.lineTo(0, height)
cawthron
parents:
diff changeset
   182
		p.lineTo(width, height/2)
cawthron
parents:
diff changeset
   183
		graphics.setClipping(p);
cawthron
parents:
diff changeset
   184
	
cawthron
parents:
diff changeset
   185
		graphics.setForeground(Colors.getColor(128, 128, 0))
cawthron
parents:
diff changeset
   186
		graphics.setBackground(Colors.getColor(128, 128, 0))
cawthron
parents:
diff changeset
   187
		graphics.setAlpha(64)	// note: no effect yet
cawthron
parents:
diff changeset
   188
		graphics.setLineWidth(1)
cawthron
parents:
diff changeset
   189
		
cawthron
parents:
diff changeset
   190
		size = properties.value
cawthron
parents:
diff changeset
   191
		if (size <= 0)
cawthron
parents:
diff changeset
   192
			size = 1
cawthron
parents:
diff changeset
   193
		
cawthron
parents:
diff changeset
   194
		for (y=0; y<height; y+=size)
cawthron
parents:
diff changeset
   195
			for (x=size*(((y/size)&1)^1); x<width; x+=size*2)
cawthron
parents:
diff changeset
   196
				graphics.fillRectangle(x, y, size, size)
cawthron
parents:
diff changeset
   197
				
cawthron
parents:
diff changeset
   198
		graphics.setForeground(Colors.getColor(0, 128, 128))
cawthron
parents:
diff changeset
   199
		graphics.setBackground(Colors.getColor(0, 128, 128))
cawthron
parents:
diff changeset
   200
		graphics.setAlpha(128)	// note: no effect yet
cawthron
parents:
diff changeset
   201
		for (y=0; y<height; y+=size)
cawthron
parents:
diff changeset
   202
			for (x=size*((y/size)&1); x<width; x+=size*2)
cawthron
parents:
diff changeset
   203
				graphics.fillRectangle(x, y, size, size)	
cawthron
parents:
diff changeset
   204
		break;
cawthron
parents:
diff changeset
   205
		
cawthron
parents:
diff changeset
   206
	case 4:
cawthron
parents:
diff changeset
   207
		r = new Rectangle(0, 0, width, height)
cawthron
parents:
diff changeset
   208
		graphics.setLineWidth(1)
cawthron
parents:
diff changeset
   209
		graphics.drawRectangle(r)
cawthron
parents:
diff changeset
   210
		
cawthron
parents:
diff changeset
   211
		r = new Rectangle(4, height/2, width-8, height/2-4)
cawthron
parents:
diff changeset
   212
	
cawthron
parents:
diff changeset
   213
		graphics.drawRectangle(r)
cawthron
parents:
diff changeset
   214
		graphics.setFont(Fonts.getGlobalFont(base+"/fonts/Alp17.14.ttf", 14))
cawthron
parents:
diff changeset
   215
		
cawthron
parents:
diff changeset
   216
		graphics.setForeground(Colors.getColor(0, 0, 0))
cawthron
parents:
diff changeset
   217
		//detailedDraw("Hello", r.x, r.y)
cawthron
parents:
diff changeset
   218
		graphics.drawFormattedString("\"Hello Sedona!\" says a wrapped box.\nFoo,\nbar.",
cawthron
parents:
diff changeset
   219
			r,
cawthron
parents:
diff changeset
   220
			Font.WRAPPING_ENABLED+Font.DRAW_TRANSPARENT+Font.ALIGN_CENTER);	
cawthron
parents:
diff changeset
   221
		break;
cawthron
parents:
diff changeset
   222
		
cawthron
parents:
diff changeset
   223
	case 5:
cawthron
parents:
diff changeset
   224
		graphics.setFont(Fonts.getGlobalFont(base+"/fonts/Alb13.10.ttf", 10))
cawthron
parents:
diff changeset
   225
		h = graphics.getFontMetrics().getHeight()
cawthron
parents:
diff changeset
   226
		r = new Rectangle(4, height/4, width-8, height/4*3-8)
cawthron
parents:
diff changeset
   227
		graphics.drawFormattedString("First", r, 0)
cawthron
parents:
diff changeset
   228
		r.y += h
cawthron
parents:
diff changeset
   229
		graphics.drawFormattedString("Second", r, Font.OPTIONS_STRIKETHROUGH)
cawthron
parents:
diff changeset
   230
		r.y += h
cawthron
parents:
diff changeset
   231
		graphics.drawFormattedString("Third", r, Font.OPTIONS_UNDERLINE)
cawthron
parents:
diff changeset
   232
		break;
cawthron
parents:
diff changeset
   233
		
cawthron
parents:
diff changeset
   234
	case 6:
cawthron
parents:
diff changeset
   235
		r = 32
cawthron
parents:
diff changeset
   236
		str="!xpEdant \u011E \u52a3\u554f\u6C55"
cawthron
parents:
diff changeset
   237
		graphics.setFont(Fonts.getGlobalFont(base+"/fonts/Alb19.15.ttf", 15))
cawthron
parents:
diff changeset
   238
		r += detailedDraw(str, 4, r)
cawthron
parents:
diff changeset
   239
		graphics.setFont(Fonts.getGlobalFont(base+"/fonts/Alp17.14.ttf", 14))
cawthron
parents:
diff changeset
   240
		r += detailedDraw(str, 4, r)
cawthron
parents:
diff changeset
   241
		graphics.setFont(Fonts.getGlobalFont(base+"/fonts/Alpi17.14.ttf", 14))
cawthron
parents:
diff changeset
   242
		r += detailedDraw(str, 4, r)
cawthron
parents:
diff changeset
   243
		graphics.setFont(Fonts.getGlobalFont(base+"/fonts/Albi17b.14.ttf", 14))
cawthron
parents:
diff changeset
   244
		r += detailedDraw(str, 4, r)
cawthron
parents:
diff changeset
   245
		graphics.setFont(Fonts.getGlobalFont(base+"/fonts/Alb12.9.ttf", 9))
cawthron
parents:
diff changeset
   246
		r += detailedDraw(str, 4, r)
cawthron
parents:
diff changeset
   247
		graphics.setFont(Fonts.getGlobalFont(base+"/fonts/Alb17.14.ttf", 14))
cawthron
parents:
diff changeset
   248
		r += detailedDraw(str, 4, r)
cawthron
parents:
diff changeset
   249
		graphics.setFont(Fonts.getGlobalFont(base+"/fonts/Aco21.16.ttf", 16))
cawthron
parents:
diff changeset
   250
		r += detailedDraw("|=+-\u00d7\u00f7", 4, r)
cawthron
parents:
diff changeset
   251
		graphics.setFont(Fonts.getGlobalFont(base+"/fonts/JapanPlain12.12.ttf", 12))
cawthron
parents:
diff changeset
   252
		r += detailedDraw(str, 4, r)
cawthron
parents:
diff changeset
   253
		graphics.setFont(Fonts.getGlobalFont(base+"/fonts/JapanPlain16.17.ttf", 17))
cawthron
parents:
diff changeset
   254
		r += detailedDraw(str, 4, r)
cawthron
parents:
diff changeset
   255
		//graphics.setFont(Fonts.getGlobalFont("c:/winnt/fonts/Arial.ttf", 12))
cawthron
parents:
diff changeset
   256
		//r += detailedDraw(str, 4, r)
cawthron
parents:
diff changeset
   257
		//graphics.setFont(Fonts.getGlobalFont("c:/winnt/fonts/ArialUni.ttf", 12))
cawthron
parents:
diff changeset
   258
		//r += detailedDraw(str, 4, r)
cawthron
parents:
diff changeset
   259
		break;
cawthron
parents:
diff changeset
   260
cawthron
parents:
diff changeset
   261
	case 7:
cawthron
parents:
diff changeset
   262
		graphics.setBackground(Colors.getColor(64,160,160))
cawthron
parents:
diff changeset
   263
		graphics.fillRectangle(0, 0, width, height)
cawthron
parents:
diff changeset
   264
cawthron
parents:
diff changeset
   265
		border = width/8
cawthron
parents:
diff changeset
   266
		// ensure Pattern works
cawthron
parents:
diff changeset
   267
		p = new Path(graphics.getDevice())
cawthron
parents:
diff changeset
   268
		p.moveTo(border, height/2)
cawthron
parents:
diff changeset
   269
		p.quadTo(border, border, width/2-border, border*2)
cawthron
parents:
diff changeset
   270
		p.quadTo(width-border, border, width-border, height/2-border)
cawthron
parents:
diff changeset
   271
		p.quadTo(width-border, height-border, width/2-border, height-border)
cawthron
parents:
diff changeset
   272
		p.quadTo(border, height-border, border, height/2-border)
cawthron
parents:
diff changeset
   273
		graphics.setClipping(p);
cawthron
parents:
diff changeset
   274
	
cawthron
parents:
diff changeset
   275
		pattern = this.getPattern(properties.value)
cawthron
parents:
diff changeset
   276
		graphics.setBackgroundPattern(pattern)
cawthron
parents:
diff changeset
   277
		graphics.setForegroundPattern(pattern)
cawthron
parents:
diff changeset
   278
		
cawthron
parents:
diff changeset
   279
//		graphics.setBackground(Colors.getColor(255, 128, 64))
cawthron
parents:
diff changeset
   280
		graphics.setForeground(Colors.getColor(0, 0, 0))
cawthron
parents:
diff changeset
   281
		graphics.fillRectangle(0, 0, width, height)
cawthron
parents:
diff changeset
   282
		
cawthron
parents:
diff changeset
   283
		break;
cawthron
parents:
diff changeset
   284
		
cawthron
parents:
diff changeset
   285
cawthron
parents:
diff changeset
   286
	}
cawthron
parents:
diff changeset
   287
cawthron
parents:
diff changeset
   288
	// draw a label on top identifying this	
cawthron
parents:
diff changeset
   289
	full = new Rectangle(0, 0, width, height)
cawthron
parents:
diff changeset
   290
	graphics.setClipping(full)
cawthron
parents:
diff changeset
   291
	graphics.setForeground(Colors.getColor(0, 0, 128))
cawthron
parents:
diff changeset
   292
	graphics.setBackground(Colors.getColor(128, 128, 128))
cawthron
parents:
diff changeset
   293
	//java.lang.System.out.println("1")
cawthron
parents:
diff changeset
   294
	graphics.setFont(Fonts.getGlobalFont(base+"/fonts/Alpi12.9.ttf", 9))
cawthron
parents:
diff changeset
   295
	
cawthron
parents:
diff changeset
   296
	s = '(name='+properties.name+'; appearance='+properties.appearance+')';
cawthron
parents:
diff changeset
   297
	r = graphics.formattedStringExtent(s, full, Font.WRAPPING_ENABLED)
cawthron
parents:
diff changeset
   298
	//java.lang.System.out.println("r="+r)
cawthron
parents:
diff changeset
   299
	graphics.drawFormattedString(s, r,
cawthron
parents:
diff changeset
   300
		Font.WRAPPING_ENABLED+Font.DRAW_OPAQUE);
cawthron
parents:
diff changeset
   301
}
cawthron
parents:
diff changeset
   302
cawthron
parents:
diff changeset
   303
Visual.prototype.getPreferredSize = function(wHint, hHint) {
cawthron
parents:
diff changeset
   304
	return null; // needs implementation	
cawthron
parents:
diff changeset
   305
}
cawthron
parents:
diff changeset
   306