Update ooo320-m1
[ooovba.git] / qadevOOo / tests / basic / ifc / style / CharacterPropertiesAsian / style_CharacterPropertiesAsian.xba
blob3f1f77b2b89c799ffc009fb3bab7dd7838c1303f
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!DOCTYPE script:module PUBLIC "-//OpenOffice.org//DTD OfficeDocument 1.0//EN" "module.dtd">
3 <script:module xmlns:script="http://openoffice.org/2000/script" script:name="style_CharacterPropertiesAsian" script:language="StarBasic">
6 '*************************************************************************
8 ' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
9 '
10 ' Copyright 2008 by Sun Microsystems, Inc.
12 ' OpenOffice.org - a multi-platform office productivity suite
14 ' $RCSfile: style_CharacterPropertiesAsian.xba,v $
16 ' $Revision: 1.3 $
18 ' This file is part of OpenOffice.org.
20 ' OpenOffice.org is free software: you can redistribute it and/or modify
21 ' it under the terms of the GNU Lesser General Public License version 3
22 ' only, as published by the Free Software Foundation.
24 ' OpenOffice.org is distributed in the hope that it will be useful,
25 ' but WITHOUT ANY WARRANTY; without even the implied warranty of
26 ' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
27 ' GNU Lesser General Public License version 3 for more details
28 ' (a copy is included in the LICENSE file that accompanied this code).
30 ' You should have received a copy of the GNU Lesser General Public License
31 ' version 3 along with OpenOffice.org. If not, see
32 ' <http://www.openoffice.org/license.html>
33 ' for a copy of the LGPLv3 License.
35 '*************************************************************************
36 '*************************************************************************
40 ' Be sure that all variables are dimensioned:
41 option explicit
45 Sub RunTest()
47 '*************************************************************************
48 ' SERVICE:
49 ' com.sun.star.style.CharacterPropertiesAsian
50 '*************************************************************************
51 On Error Goto ErrHndl
52 Dim bOK As Boolean
54 Dim charHeightAsian(3) As Double
55 charHeightAsian(0) = 12.3
56 charHeightAsian(1) = 16.2
57 charHeightAsian(2) = 26.6
58 charHeightAsian(3) = 42.8
60 Dim charWeightAsian(9) As Integer
61 with com.sun.star.awt.FontWeight
62 charWeightAsian(0) = .DONTKNOW
63 charWeightAsian(1) = .THIN
64 charWeightAsian(2) = .ULTRALIGHT
65 charWeightAsian(3) = .LIGHT
66 charWeightAsian(4) = .SEMILIGHT
67 charWeightAsian(5) = .NORMAL
68 charWeightAsian(6) = .SEMIBOLD
69 charWeightAsian(7) = .BOLD
70 charWeightAsian(8) = .ULTRABOLD
71 charWeightAsian(9) = .BLACK
72 end with
74 PropertyTester.TestProperty("CharHeightAsian",charHeightAsian())
76 PropertyTester.TestProperty("CharWeightAsian",charWeightAsian())
78 PropertyTester.TestProperty("CharFontNameAsian")
80 PropertyTester.TestProperty("CharFontStyleNameAsian")
82 PropertyTester.TestProperty("CharFontFamilyAsian")
84 PropertyTester.TestProperty("CharFontCharSetAsian")
86 PropertyTester.TestProperty("CharFontPitchAsian")
88 PropertyTester.TestProperty("CharPostureAsian")
90 PropertyTester.TestProperty("CharLocaleAsian")
92 PropertyTester.TestProperty("ParaIsCharacterDistance")
94 PropertyTester.TestProperty("ParaIsForbiddenRules")
96 PropertyTester.TestProperty("ParaIsHangingPunctuation")
98 Exit Sub
99 ErrHndl:
100 Test.Exception()
101 bOK = false
102 resume next
103 End Sub
104 </script:module>