Changeset 473 for trunk/Include/Classes
- Timestamp:
- Mar 12, 2008, 9:54:46 PM (17 years ago)
- Location:
- trunk/Include/Classes
- Files:
-
- 7 added
- 18 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Include/Classes/ActiveBasic/Windows/WindowHandle.sbp
r303 r473 586 586 587 587 Const Function ClientRect() As RECT 588 Dim rc As RECT 589 _System_GetClientRect(hwnd, rc) 590 Return rc 588 _System_GetClientRect(hwnd, ClientRect) 591 589 End Function 592 590 #ifdef _UNDEF … … 603 601 #endif 604 602 Const Function WindowRect() As RECT 605 Dim rc As RECT 606 _System_GetWindowRect(hwnd, rc) 607 Return rc 603 _System_GetWindowRect(hwnd, WindowRect) 608 604 End Function 609 605 -
trunk/Include/Classes/System/Console.ab
r435 r473 36 36 */ 37 37 Static Function ReadLine() As String 38 Dim lock = enter() 39 Try 40 ReadLine = in.ReadLine() 41 Finally 42 lock.Leave() 43 End Try 38 ReadLine = in.ReadLine() 44 39 End Function 45 40 … … 50 45 */ 51 46 Static Function Read() As Long 52 Dim lock = enter() 53 Try 54 Read = in.Read() 55 Finally 56 lock.Leave() 57 End Try 47 Read = in.Read() 58 48 End Function 59 49 Private -
trunk/Include/Classes/System/Drawing/CharacterRange.ab
r166 r473 9 9 first = f 10 10 length = l 11 End Sub12 13 Sub CharacterRange(ByRef c As CharacterRange)14 first = c.first15 length = c.length16 11 End Sub 17 12 … … 30 25 31 26 Function Length() As Long 32 Return l 27 Return length 33 28 End Function 34 29 … … 37 32 End Sub 38 33 39 Sub Operator = (ByRef c As CharacterRange) 40 first = c.first 41 length = c.length 42 End Sub 43 44 Function Operator ==(c As CharacterRange) 34 Function Operator ==(c As CharacterRange) As Boolean 45 35 Return Equals(c) 46 36 End Function 47 37 48 Function Operator <>(c As CharacterRange) 38 Function Operator <>(c As CharacterRange) As Boolean 49 39 Return Not Equals(c) 50 40 End Function 51 41 52 Function Equals(c As CharacterRange) 42 Function Equals(c As CharacterRange) As Boolean 53 43 Return first = c.first And length = c.length 54 44 End Function -
trunk/Include/Classes/System/Drawing/Color.ab
r370 r473 4 4 #define __SYSTEM_DRAWING_COLOR_AB__ 5 5 6 '#include <Classes/System/Math.ab>7 6 #include <Classes/System/Drawing/Imaging/misc.ab> 8 7 … … 28 27 argb = newArgb 29 28 End Sub 30 /* 31 Sub Operator =(c As Color) 32 argb = c.argb 33 End Sub 34 */ 29 35 30 Function Operator ==(c As Color) As Boolean 36 31 Return Equals(c) … … 42 37 43 38 Function A() As Byte 44 Return(argb >> ALPHA_SHIFT) As Byte39 A = (argb >> ALPHA_SHIFT) As Byte 45 40 End Function 46 41 47 42 Function R() As Byte 48 R eturn(argb >> RED_SHIFT) As Byte43 R = (argb >> RED_SHIFT) As Byte 49 44 End Function 50 45 51 46 Function G() As Byte 52 Return(argb >> GREEN_SHIFT) As Byte47 G = (argb >> GREEN_SHIFT) As Byte 53 48 End Function 54 49 55 50 Function B() As Byte 56 Return(argb >> BLUE_SHIFT) As Byte51 B = (argb >> BLUE_SHIFT) As Byte 57 52 End Function 58 53 59 54 Function Value() As ARGB 60 Returnargb55 Value = argb 61 56 End Function 62 57 -
trunk/Include/Classes/System/Drawing/Font.ab
r212 r473 1 #ifndef _GDIPLUSFONT_H 2 #define _GDIPLUSFONT_H 3 4 #require <GdiPlus.ab> 5 #require <Classes/System/Drawing/misc.ab> 1 /** 2 @file Classes/System/Drawing/Font.ab 3 @brief Fontクラスなどの実装。 4 */ 5 6 6 #require <Classes/System/Drawing/Graphics.ab> 7 7 … … 10 10 11 11 Class Font 12 Implements System.IDisposable 12 13 Public 13 14 ' friend class Graphics … … 130 131 /*IN*/ style As Long, /*IN*/ unit As GraphicsUnit, 131 132 /*IN const*/ fontCollection As FontCollection) 132 #ifdef __STRING_IS_NOT_UNICODE 133 Dim oldAlloc = _System_AllocForConvertedString 134 _System_AllocForConvertedString = AddressOf (_System_malloc) 135 Dim name = ToWCStr(familyName) 136 Font(name, emSize, style, unit, fontCollection) 137 _System_free(name) 138 _System_AllocForConvertedString = oldAlloc 139 #else 140 Font(familyName.Chars, emSize, style, unit, fontCollection) 141 #endif 133 Font(ToWCStr(familyName), emSize, style, unit, fontCollection) 142 134 End Sub 143 135 144 136 Const Function GetLogFontA(/*IN const*/ g As Graphics, /*OUT*/ ByRef lf As LOGFONTA) As Status 145 137 Dim nativeGraphics As *GpGraphics 146 If VarPtr(g) <> 0Then138 If Not ActiveBasic.IsNothing(g) Then 147 139 nativeGraphics = g.nativeGraphics 148 140 End If … … 152 144 Const Function GetLogFontW(/*IN const*/ g As Graphics, /*OUT*/ ByRef lf As LOGFONTW) As Status 153 145 Dim nativeGraphics As *GpGraphics 154 If VarPtr(g) <> 0Then146 If Not ActiveBasic.IsNothing(g) Then 155 147 nativeGraphics = g.nativeGraphics 156 148 End If … … 160 152 Const Function GetLogFont(/*IN const*/ g As Graphics, /*OUT*/ ByRef lf As LOGFONT) As Status 161 153 Dim nativeGraphics As *GpGraphics 162 If VarPtr(g) <> 0Then154 If Not ActiveBasic.IsNothing(g) Then 163 155 nativeGraphics = g.nativeGraphics 164 156 End If … … 212 204 Const Function GetHeight(/*IN const*/ g As Graphics) As Single 213 205 Dim nativeGraphics As *GpGraphics 214 If VarPtr(g) <> 0Then206 If Not ActiveBasic.IsNothing(g) Then 215 207 nativeGraphics = g.NativeGraphics 216 208 End If … … 270 262 'Const Function SizeInPoint() As Boolean 271 263 272 Const Function NativeFont() As *GpFont273 Return nativeFont274 End Function275 276 264 Const Function StrikeOut() As Boolean 277 265 Dim lf As LOGFONT … … 341 329 /*mutable*/ lastResult As Status 342 330 End Class 343 344 #endif -
trunk/Include/Classes/System/Drawing/Graphics.ab
r212 r473 14 14 Class CachedBitmap : End Class 15 15 16 #include <GdiplusGpStubs.ab>17 #include <GdiPlusFlat.ab>18 #include <Classes/System/Drawing/misc.ab>19 #include <Classes/System/Drawing/Rectangle.ab>20 #include <Classes/System/Drawing/RectangleF.ab>21 #include <Classes/System/Drawing/Point.ab>22 #include <Classes/System/Drawing/PointF.ab>23 #include <Classes/System/Drawing/SizeF.ab>24 #include <Classes/System/Drawing/Font.ab>25 '#include <Classes/System/Drawing/Brush.ab>26 '#include <Classes/System/Drawing/Pen.ab>27 '#include <Classes/System/Drawing/Region.ab>28 '#include <Classes/System/Drawing/StringFormat.ab>29 '#include <Classes/System/Drawing/Image.ab>30 #include <Classes/System/Drawing/Drawing2D/misc.ab>31 #include <Classes/System/Drawing/Drawing2D/Matrix.ab>32 33 16 Class Graphics 34 17 Public -
trunk/Include/Classes/System/Drawing/Point.ab
r303 r473 1 1 ' Classes/System/Drawing/Point.ab 2 2 3 #ifndef __SYSTEM_DRAWING_POINT_AB__ 4 #define __SYSTEM_DRAWING_POINT_AB__ 5 6 #require <Classes/System/Drawing/PointF.ab> 7 #require <Classes/System/Drawing/Size.ab> 8 #require <Classes/System/Drawing/SizeF.ab> 3 Namespace System 4 Namespace Drawing 9 5 10 6 Class Point … … 31 27 32 28 Function X() As Long 33 Returnx29 X = x 34 30 End Function 35 31 … … 39 35 40 36 Function Y() As Long 41 Returny37 X = y 42 38 End Function 43 39 … … 50 46 End Function 51 47 52 Function Operator + 48 Function Operator +(pt As Point) As Point 53 49 Return Add(This, pt) 54 50 End Function 55 51 56 Function Operator + 52 Function Operator +(sz As Size) As Point 57 53 Return Add(This, sz) 58 54 End Function 59 55 60 Function Operator - 56 Function Operator -(pt As Point) As Point 61 57 Return Substract(This, pt) 62 58 End Function 63 59 64 Function Operator - 60 Function Operator -(sz As Size) As Point 65 61 Return Substract(This, sz) 66 62 End Function 67 63 68 Function Operator == 64 Function Operator ==(sz As Point) As Boolean 69 65 Return Equals(sz) 70 66 End Function 71 67 72 Function Operator <> 68 Function Operator <>(sz As Point) As Boolean 73 69 Return Not Equals(sz) 74 70 End Function … … 108 104 109 105 Static Function Ceiling(ptf As PointF) As Point 110 Return New Point( System.Math.Ceiling(ptf.X) As Long, System.Math.Ceiling(ptf.Y) As Long)106 Return New Point(Math.Ceiling(ptf.X) As Long, Math.Ceiling(ptf.Y) As Long) 111 107 End Function 112 108 113 109 Static Function Round(ptf As PointF) As Point 114 Return New Point( System.Math.Round(ptf.X) As Long, System.Math.Round(ptf.Y) As Long)110 Return New Point(Math.Round(ptf.X) As Long, Math.Round(ptf.Y) As Long) 115 111 End Function 116 112 117 113 Static Function Truncate(ptf As PointF) As Point 118 Return New Point( System.Math.Truncate(ptf.X) As Long, System.Math.Truncate(ptf.Y) As Long)114 Return New Point(Math.Truncate(ptf.X) As Long, Math.Truncate(ptf.Y) As Long) 119 115 End Function 120 116 … … 128 124 End Class 129 125 130 #endif '__SYSTEM_DRAWING_POINT_AB__ 126 End Namespace 127 End Namespace -
trunk/Include/Classes/System/Drawing/PointF.ab
r303 r473 1 1 ' Classes/System/Drawing/PointF.ab 2 2 3 #ifndef __SYSTEM_DRAWING_POINTF_AB__ 4 #define __SYSTEM_DRAWING_POINTF_AB__ 5 6 #include <Classes/System/Drawing/Size.ab> 7 #include <Classes/System/Drawing/SizeF.ab> 3 Namespace System 4 Namespace Drawing 8 5 9 6 Class PointF … … 30 27 31 28 Function X() As Single 32 Returnx29 X = x 33 30 End Function 34 31 … … 38 35 39 36 Function Y() As Single 40 Returny37 Y = y 41 38 End Function 42 39 … … 82 79 83 80 Static Function Add(pt1 As PointF, pt2 As PointF) As PointF 84 Dim ret As PointF(pt1.x + pt2.x, pt1.y + pt2.y) 85 Return ret 81 Return New PointF(pt1.x + pt2.x, pt1.y + pt2.y) 86 82 End Function 87 83 88 84 Static Function Add(pt As PointF, sz As Size) As PointF 89 Dim ret As PointF(pt.x + sz.Width, pt.y + sz.Height) 90 Return ret 85 Return New PointF(pt.x + sz.Width, pt.y + sz.Height) 91 86 End Function 92 87 93 88 Static Function Add(pt As PointF, sz As SizeF) As PointF 94 Dim ret As PointF(pt.x + sz.Width, pt.y + sz.Height) 95 Return ret 89 Return New PointF(pt.x + sz.Width, pt.y + sz.Height) 96 90 End Function 97 91 98 92 Static Function Substract(pt1 As PointF, pt2 As PointF) As PointF 99 Dim ret As PointF(pt1.x - pt2.x, pt1.y - pt2.y) 100 Return ret 93 Return New PointF(pt1.x - pt2.x, pt1.y - pt2.y) 101 94 End Function 102 95 103 96 Static Function Substract(pt As PointF, sz As Size) As PointF 104 Dim ret As PointF(pt.x - sz.Width, pt.y - sz.Height) 105 Return ret 97 Return New PointF(pt.x - sz.Width, pt.y - sz.Height) 106 98 End Function 107 99 108 100 Static Function Substract(pt As PointF, sz As SizeF) As PointF 109 Dim ret As PointF(pt.x - sz.Width, pt.y - sz.Height) 110 Return ret 101 Return New PointF(pt.x - sz.Width, pt.y - sz.Height) 111 102 End Function 112 103 … … 124 115 End Class 125 116 126 #endif '__SYSTEM_DRAWING_POINTF_AB__ 117 End Namespace 118 End Namespace -
trunk/Include/Classes/System/Drawing/Rectangle.ab
r335 r473 1 1 ' Classes/System/Drawing/Rectangle.ab 2 2 3 #ifndef __SYSTEM_DRAWING_RECTANGLE_AB__ 4 #define __SYSTEM_DRAWING_RECTANGLE_AB__ 5 6 '#require <Classes/System/Math.ab> 7 #require <Classes/System/Drawing/RectangleF.ab> 8 #require <Classes/System/Drawing/Point.ab> 9 #require <Classes/System/Drawing/Size.ab> 3 Namespace System 4 Namespace Drawing 10 5 11 6 Class Rectangle … … 40 35 41 36 Function Location() As Point 42 Dim pt As Point(x, y) 43 Return pt 37 Location = New Point(x, y) 44 38 End Function 45 39 … … 50 44 51 45 Function Size() As Size 52 Dim size AsSize(width, height)46 Size = New Size(width, height) 53 47 End Function 54 48 … … 59 53 60 54 Function X() As Long 61 Returnx55 X = x 62 56 End Function 63 57 … … 67 61 68 62 Function Y() As Long 69 Returny63 Y = y 70 64 End Function 71 65 … … 75 69 76 70 Function Width() As Long 77 Returnwidth71 Width = width 78 72 End Function 79 73 … … 83 77 84 78 Function Height() As Long 85 Returnheight79 Height = height 86 80 End Function 87 81 … … 91 85 92 86 Function Left() As Long 93 ReturnX87 Left = X 94 88 End Function 95 89 96 90 Function Top() As Long 97 ReturnY91 Top = Y 98 92 End Function 99 93 100 94 Function Right() As Long 101 R eturnX + Width95 Right = X + Width 102 96 End Function 103 97 104 98 Function Bottom() As Long 105 ReturnY + Height99 Bottom = Y + Height 106 100 End Function 107 101 … … 110 104 End Function 111 105 112 Function Operator == 106 Function Operator ==(rc As Rectangle) As Boolean 113 107 Return Equals(rc) 114 108 End Function 115 109 116 Function Operator <> 110 Function Operator <>(rc As Rectangle) As Boolean 117 111 Return (Not Equals(rc)) 118 112 End Function … … 206 200 Static Function Ceiling(rcf As RectangleF) As Rectangle 207 201 Dim r As Rectangle( 208 System.Math.Ceiling(rcf.X) As Long,209 System.Math.Ceiling(rcf.Y) As Long,210 System.Math.Ceiling(rcf.Width) As Long,211 System.Math.Ceiling(rcf.Height) As Long)202 Math.Ceiling(rcf.X) As Long, 203 Math.Ceiling(rcf.Y) As Long, 204 Math.Ceiling(rcf.Width) As Long, 205 Math.Ceiling(rcf.Height) As Long) 212 206 Return r 213 207 End Function … … 215 209 Static Function Round(rcf As RectangleF) As Rectangle 216 210 Dim r As Rectangle( 217 System.Math.Round(rcf.X) As Long,218 System.Math.Round(rcf.Y) As Long,219 System.Math.Round(rcf.Width) As Long,220 System.Math.Round(rcf.Height) As Long)211 Math.Round(rcf.X) As Long, 212 Math.Round(rcf.Y) As Long, 213 Math.Round(rcf.Width) As Long, 214 Math.Round(rcf.Height) As Long) 221 215 Return r 222 216 End Function … … 224 218 Static Function Truncate(rcf As RectangleF) As Rectangle 225 219 Dim r As Rectangle( 226 System.Math.Truncate(rcf.X) As Long,227 System.Math.Truncate(rcf.Y) As Long,228 System.Math.Truncate(rcf.Width) As Long,229 System.Math.Truncate(rcf.Height) As Long)220 Math.Truncate(rcf.X) As Long, 221 Math.Truncate(rcf.Y) As Long, 222 Math.Truncate(rcf.Width) As Long, 223 Math.Truncate(rcf.Height) As Long) 230 224 Return r 231 225 End Function … … 247 241 End Class 248 242 249 #endif '__SYSTEM_DRAWING_RECTFANGLE_AB__ 243 End Namespace 244 End Namespace -
trunk/Include/Classes/System/Drawing/RectangleF.ab
r335 r473 1 1 ' Classes/System/Drawing/RectangleF.ab 2 2 3 #ifndef __SYSTEM_DRAWING_RECTANGLEF_AB__ 4 #define __SYSTEM_DRAWING_RECTANGLEF_AB__ 5 6 '#include <Classes/System/Math.ab> 7 #include <Classes/System/Drawing/PointF.ab> 8 #include <Classes/System/Drawing/SizeF.ab> 3 Namespace System 4 Namespace Drawing 9 5 10 6 Class RectangleF … … 39 35 40 36 Function Location() As PointF 41 Dim pt As PointF(x, y) 42 Return pt 37 Location = New PointF(x, y) 43 38 End Function 44 39 … … 49 44 50 45 Function Size() As SizeF 51 Dim size AsSizeF(width, height)46 Size = New SizeF(width, height) 52 47 End Function 53 48 … … 58 53 59 54 Function X() As Single 60 Returnx55 X = x 61 56 End Function 62 57 … … 66 61 67 62 Function Y() As Single 68 Returny63 Y = y 69 64 End Function 70 65 … … 74 69 75 70 Function Width() As Single 76 Returnwidth71 Width = width 77 72 End Function 78 73 … … 82 77 83 78 Function Height() As Single 84 Returnheight79 Height = height 85 80 End Function 86 81 … … 90 85 91 86 Function Left() As Single 92 ReturnX87 Left = X 93 88 End Function 94 89 95 90 Function Top() As Single 96 ReturnY91 Top = Y 97 92 End Function 98 93 99 94 Function Right() As Single 100 R eturnX + Width95 Right = X + Width 101 96 End Function 102 97 103 98 Function Bottom() As Single 104 ReturnY + Height99 Bottom = Y + Height 105 100 End Function 106 101 … … 210 205 End Class 211 206 212 #endif '__SYSTEM_DRAWING_RECTFANGLE_AB__ 207 End Namespace 208 End Namespace -
trunk/Include/Classes/System/Drawing/Size.ab
r335 r473 1 1 ' Classes/System/Drawing/Size.ab 2 2 3 #ifndef __SYSTEM_DRAWING_SIZE_AB__ 4 #define __SYSTEM_DRAWING_SIZE_AB__ 5 6 '#include <Classes/System/Math.ab> 7 #include <Classes/System/Drawing/SizeF.ab> 3 Namespace System 4 Namespace Drawing 8 5 9 6 Class Size … … 41 38 42 39 Function Operator +(sz As Size) As Size 43 Dim ret As Size(width + sz.width, height + sz.height) 44 Return ret 40 Return New Size(width + sz.width, height + sz.height) 45 41 End Function 46 42 47 43 Function Operator -(sz As Size) As Size 48 Dim ret As Size(width - sz.width, height - sz.height) 49 Return ret 44 Return New Size(width - sz.width, height - sz.height) 50 45 End Function 51 46 52 47 Function Operator () As SizeF 53 Dim szf As SizeF(width, height) 54 Return szf 48 Return New SizeF(width, height) 55 49 End Function 56 50 … … 62 56 Return Not Equals(sz) 63 57 End Function 64 /* 65 Sub Operator =(ByRef sz As Size) 66 width = sz.width 67 height = sz.height 68 End Sub 69 */ 58 70 59 Function Equals(sz As Size) As Boolean 71 60 If width = sz.width And height = sz.height Then … … 93 82 94 83 Static Function Ceiling(szf As SizeF) As Size 95 Dim sz As Size(System.Math.Ceiling(szf.Width) As Long, System.Math.Ceiling(szf.Height) As Long) 96 Return sz 84 Return New Size(System.Math.Ceiling(szf.Width) As Long, System.Math.Ceiling(szf.Height) As Long) 97 85 End Function 98 86 99 87 Static Function Round(szf As SizeF) As Size 100 Dim sz As Size(System.Math.Round(szf.Width) As Long, System.Math.Round(szf.Height) As Long) 101 Return sz 88 Return New Size(System.Math.Round(szf.Width) As Long, System.Math.Round(szf.Height) As Long) 102 89 End Function 103 90 104 91 Static Function Truncate(szf As SizeF) As Size 105 Dim sz As Size(System.Math.Truncate(szf.Width) As Long, System.Math.Truncate(szf.Height) As Long) 106 Return sz 92 Return New Size(System.Math.Truncate(szf.Width) As Long, System.Math.Truncate(szf.Height) As Long) 107 93 End Function 108 94 … … 112 98 End Class 113 99 114 #endif '__SYSTEM_DRAWING_SIZE_AB__ 100 End Namespace 101 End Namespace -
trunk/Include/Classes/System/Drawing/SizeF.ab
r303 r473 1 1 ' Classes/System/Drawing/SizeF.ab 2 2 3 #ifndef __SYSTEM_DRAWING_SIZEF_AB__ 4 #define __SYSTEM_DRAWING_SIZEF_AB__ 5 6 #include <Classes/System/Drawing/Size.ab> 7 #include <Classes/System/Drawing/PointF.ab> 3 Namespace System 4 Namespace Drawing 8 5 9 6 Class SizeF … … 41 38 42 39 Function Operator +(sz As SizeF) As SizeF 43 Dim ret As SizeF(width + sz.width, height + sz.height) 44 Return ret 40 Return New SizeF(width + sz.width, height + sz.height) 45 41 End Function 46 42 47 43 Function Operator -(sz As SizeF) As SizeF 48 Dim ret As SizeF(width - sz.width, height - sz.height) 49 Return ret 44 Return New SizeF(width - sz.width, height - sz.height) 50 45 End Function 51 46 … … 57 52 Return Not Equals(sz) 58 53 End Function 59 /* 60 Sub Operator =(ByRef sz As SizeF) 61 width = sz.width 62 height = sz.height 63 End Sub 64 */ 54 65 55 Function Equals(sz As SizeF) As Boolean 66 56 Return width = sz.width And height = sz.height … … 88 78 89 79 Function ToPointF() As PointF 90 Dim pt As PointF(width, height) 91 Return pt 80 Return New PointF(width, height) 92 81 End Function 93 82 Private … … 96 85 End Class 97 86 98 #endif '__SYSTEM_DRAWING_SIZEF_AB__ 87 End Namespace 88 End Namespace -
trunk/Include/Classes/System/Drawing/misc.ab
r137 r473 37 37 38 38 Enum FontStyle 39 /* 39 40 Regular = 0 40 41 Bold = 1 … … 42 43 Strikeout = 4 43 44 Underline = 8 45 */ 44 46 End Enum 45 47 -
trunk/Include/Classes/System/IO/StreamWriter.ab
r470 r473 1 /* 2 @file Include/Classes/System/IO/StreamWriter.ab 3 @brief StreamWriterの実装。 4 */ 5 1 6 Namespace System 2 7 Namespace IO 3 4 8 9 /* 10 @biref ストリームへの書き込みを行うTextWriterの派生。 11 @date 2008/03/09 12 @auther Egtra 13 */ 5 14 Class StreamWriter 6 15 Inherits TextWriter 7 16 Public 8 17 /* 9 @date 2008/0 2/2518 @date 2008/03/09 10 19 @auther Egtra 11 20 */ … … 15 24 16 25 /* 17 @date 2008/0 2/2526 @date 2008/03/09 18 27 @auther Egtra 19 28 */ 20 29 Sub StreamWriter(stream As Stream) 21 30 init(stream) 31 End Sub 32 33 Override Sub Flush() 34 Dim len = buf.Length 35 If len > 0 Then 36 s.Write(StrPtr(buf) As *Byte, 0, len) 37 buf.Length = 0 38 End If 22 39 End Sub 23 40 … … 104 121 End Class 105 122 106 107 123 End Namespace 108 124 End Namespace -
trunk/Include/Classes/System/IO/TextReader.ab
r468 r473 98 98 99 99 Static Function Synchronized(reader As TextReader) As TextReader 100 Synchronized = New Detail.SynchronizedTextReader(reader) 100 101 End Function 101 102 -
trunk/Include/Classes/System/IO/TextWriter.ab
r468 r473 28 28 Sub TextWriter() 29 29 newLine = Environment.NewLine 30 End Sub 31 32 Virtual Sub Flush() 30 33 End Sub 31 34 -
trunk/Include/Classes/System/Windows/Forms/Control.ab
r461 r473 113 113 End Sub 114 114 115 Const Function Bounds() As Rectangle115 Const Function Bounds() As Drawing.Rectangle 116 116 Dim wr As RECT 117 117 wr = wnd.WindowRect 118 Dim r = New Rectangle(wr)118 Dim r = New Drawing.Rectangle(wr) 119 119 Dim parent = Parent 120 120 If Object.ReferenceEquals(parent, Nothing) Then 121 Return parent ->RectangleToClient(r)121 Return parent.RectangleToClient(r) 122 122 Else 123 123 Return r … … 129 129 End Sub 130 130 */ 131 Const Function Location() As Point131 Const Function Location() As Drawing.Point 132 132 Return Bounds.Location 133 133 End Function … … 137 137 End Sub 138 138 */ 139 Const Function Size() As Size139 Const Function Size() As Drawing.Size 140 140 Return Bounds.Size 141 141 End Function … … 213 213 End Function 214 214 */ 215 Const Function RectangleToScreen(r As Rectangle) AsRectangle215 Const Function RectangleToScreen(r As Drawing.Rectangle) As Drawing.Rectangle 216 216 Dim rc = r.ToRECT 217 217 wnd.ClientToScreen(rc) 218 Return New Rectangle(rc)219 End Function 220 221 Const Function RectangleToClient(r As Rectangle) AsRectangle218 Return New Drawing.Rectangle(rc) 219 End Function 220 221 Const Function RectangleToClient(r As Drawing.Rectangle) As Drawing.Rectangle 222 222 Dim rc = r.ToRECT() 223 223 wnd.ScreenToClient(rc) 224 Return New Rectangle(rc)224 Return New Drawing.Rectangle(rc) 225 225 End Function 226 226 … … 405 405 ' Virtual Function DefaultCursor() As Cursor 406 406 407 Virtual Function DefaultSize() As Size408 Return New Size(300, 300)407 Virtual Function DefaultSize() As Drawing.Size 408 Return New Drawing.Size(300, 300) 409 409 End Function 410 410 … … 543 543 End Sub 544 544 545 Virtual Sub NotifyInvalidate(r As Rectangle)545 Virtual Sub NotifyInvalidate(r As Drawing.Rectangle) 546 546 Dim rc As RECT 547 547 rc = r.ToRECT() -
trunk/Include/Classes/index.ab
r471 r473 38 38 #require "./System/Diagnostics/TraceListener.ab" 39 39 #require "./System/Diagnostics/TraceListenerCollection.ab" 40 '#require "./System/Drawing/CharacterRange.ab"40 #require "./System/Drawing/CharacterRange.ab" 41 41 #require "./System/Drawing/Color.ab" 42 42 '#require "./System/Drawing/Font.ab" 43 43 '#require "./System/Drawing/Graphics.ab" 44 44 '#require "./System/Drawing/Image.ab" 45 '#require "./System/Drawing/misc.ab"45 #require "./System/Drawing/misc.ab" 46 46 #require "./System/Drawing/Point.ab" 47 '#require "./System/Drawing/PointF.ab"47 #require "./System/Drawing/PointF.ab" 48 48 #require "./System/Drawing/Rectangle.ab" 49 '#require "./System/Drawing/RectangleF.ab"49 #require "./System/Drawing/RectangleF.ab" 50 50 #require "./System/Drawing/Size.ab" 51 '#require "./System/Drawing/SizeF.ab"51 #require "./System/Drawing/SizeF.ab" 52 52 '#require "./System/Drawing/Drawing2D/Matrix.ab" 53 53 '#require "./System/Drawing/Drawing2D/misc.ab"
Note:
See TracChangeset
for help on using the changeset viewer.