1 /************************************************************** 2 * 3 * Licensed to the Apache Software Foundation (ASF) under one 4 * or more contributor license agreements. See the NOTICE file 5 * distributed with this work for additional information 6 * regarding copyright ownership. The ASF licenses this file 7 * to you under the Apache License, Version 2.0 (the 8 * "License"); you may not use this file except in compliance 9 * with the License. You may obtain a copy of the License at 10 * 11 * http://www.apache.org/licenses/LICENSE-2.0 12 * 13 * Unless required by applicable law or agreed to in writing, 14 * software distributed under the License is distributed on an 15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16 * KIND, either express or implied. See the License for the 17 * specific language governing permissions and limitations 18 * under the License. 19 * 20 *************************************************************/ 21 22 23 24 #include <basic/sbstar.hxx> 25 #include "sbtrace.hxx" 26 27 #define RTLFUNC( name ) void SbRtl_##name( StarBASIC* pBasic, SbxArray& rPar, sal_Bool bWrite ) 28 #define RTLNAME( name ) &SbRtl_##name 29 30 typedef void( *RtlCall ) ( StarBASIC* p, SbxArray& rArgs, sal_Bool bWrite ); 31 32 // Properties 33 34 extern RTLFUNC(Date); 35 extern RTLFUNC(Err); 36 extern RTLFUNC(Erl); 37 extern RTLFUNC(False); 38 extern RTLFUNC(Empty); 39 extern RTLFUNC(Nothing); 40 extern RTLFUNC(Null); 41 extern RTLFUNC(True); 42 43 extern RTLFUNC(ATTR_NORMAL); 44 extern RTLFUNC(ATTR_READONLY); 45 extern RTLFUNC(ATTR_HIDDEN); 46 extern RTLFUNC(ATTR_SYSTEM); 47 extern RTLFUNC(ATTR_VOLUME); 48 extern RTLFUNC(ATTR_DIRECTORY); 49 extern RTLFUNC(ATTR_ARCHIVE); 50 51 extern RTLFUNC(V_EMPTY); 52 extern RTLFUNC(V_NULL); 53 extern RTLFUNC(V_INTEGER); 54 extern RTLFUNC(V_LONG); 55 extern RTLFUNC(V_SINGLE); 56 extern RTLFUNC(V_DOUBLE); 57 extern RTLFUNC(V_CURRENCY); 58 extern RTLFUNC(V_DATE); 59 extern RTLFUNC(V_STRING); 60 61 extern RTLFUNC(MB_OK); 62 extern RTLFUNC(MB_OKCANCEL); 63 extern RTLFUNC(MB_ABORTRETRYIGNORE); 64 extern RTLFUNC(MB_YESNOCANCEL); 65 extern RTLFUNC(MB_YESNO); 66 extern RTLFUNC(MB_RETRYCANCEL); 67 extern RTLFUNC(MB_ICONSTOP); 68 extern RTLFUNC(MB_ICONQUESTION); 69 extern RTLFUNC(MB_ICONEXCLAMATION); 70 extern RTLFUNC(MB_ICONINFORMATION); 71 extern RTLFUNC(MB_DEFBUTTON1); 72 extern RTLFUNC(MB_DEFBUTTON2); 73 extern RTLFUNC(MB_DEFBUTTON3); 74 extern RTLFUNC(MB_APPLMODAL); 75 extern RTLFUNC(MB_SYSTEMMODAL); 76 77 extern RTLFUNC(IDOK); 78 extern RTLFUNC(IDCANCEL); 79 extern RTLFUNC(IDABORT); 80 extern RTLFUNC(IDRETRY); 81 extern RTLFUNC(IDYES); 82 extern RTLFUNC(IDNO); 83 84 extern RTLFUNC(CF_TEXT); 85 extern RTLFUNC(CF_BITMAP); 86 extern RTLFUNC(CF_METAFILEPICT); 87 88 extern RTLFUNC(PI); 89 90 extern RTLFUNC(SET_OFF); 91 extern RTLFUNC(SET_ON); 92 extern RTLFUNC(TOGGLE); 93 94 extern RTLFUNC(TYP_AUTHORFLD); 95 extern RTLFUNC(TYP_CHAPTERFLD); 96 extern RTLFUNC(TYP_CONDTXTFLD); 97 extern RTLFUNC(TYP_DATEFLD); 98 extern RTLFUNC(TYP_DBFLD); 99 extern RTLFUNC(TYP_DBNAMEFLD); 100 extern RTLFUNC(TYP_DBNEXTSETFLD); 101 extern RTLFUNC(TYP_DBNUMSETFLD); 102 extern RTLFUNC(TYP_DBSETNUMBERFLD); 103 extern RTLFUNC(TYP_DDEFLD); 104 extern RTLFUNC(TYP_DOCINFOFLD); 105 extern RTLFUNC(TYP_DOCSTATFLD); 106 extern RTLFUNC(TYP_EXTUSERFLD); 107 extern RTLFUNC(TYP_FILENAMEFLD); 108 extern RTLFUNC(TYP_FIXDATEFLD); 109 extern RTLFUNC(TYP_FIXTIMEFLD); 110 extern RTLFUNC(TYP_FORMELFLD); 111 extern RTLFUNC(TYP_GETFLD); 112 extern RTLFUNC(TYP_GETREFFLD); 113 extern RTLFUNC(TYP_HIDDENPARAFLD); 114 extern RTLFUNC(TYP_HIDDENTXTFLD); 115 extern RTLFUNC(TYP_INPUTFLD); 116 extern RTLFUNC(TYP_MACROFLD); 117 extern RTLFUNC(TYP_NEXTPAGEFLD); 118 extern RTLFUNC(TYP_PAGENUMBERFLD); 119 extern RTLFUNC(TYP_POSTITFLD); 120 extern RTLFUNC(TYP_PREVPAGEFLD); 121 extern RTLFUNC(TYP_SEQFLD); 122 extern RTLFUNC(TYP_SETFLD); 123 extern RTLFUNC(TYP_SETINPFLD); 124 extern RTLFUNC(TYP_SETREFFLD); 125 extern RTLFUNC(TYP_TEMPLNAMEFLD); 126 extern RTLFUNC(TYP_TIMEFLD); 127 extern RTLFUNC(TYP_USERFLD); 128 extern RTLFUNC(TYP_USRINPFLD); 129 extern RTLFUNC(TYP_SETREFPAGEFLD); 130 extern RTLFUNC(TYP_GETREFPAGEFLD); 131 extern RTLFUNC(TYP_INTERNETFLD); 132 extern RTLFUNC(TYP_JUMPEDITFLD); 133 134 extern RTLFUNC(FRAMEANCHORPAGE); 135 extern RTLFUNC(FRAMEANCHORPARA); 136 extern RTLFUNC(FRAMEANCHORCHAR); 137 138 extern RTLFUNC(CLEAR_ALLTABS); 139 extern RTLFUNC(CLEAR_TAB); 140 extern RTLFUNC(SET_TAB); 141 142 extern RTLFUNC(LINEPROP); 143 extern RTLFUNC(LINE_1); 144 extern RTLFUNC(LINE_15); 145 extern RTLFUNC(LINE_2); 146 147 // Methoden 148 149 extern RTLFUNC(CreateObject); 150 extern RTLFUNC(Error); 151 extern RTLFUNC(Sin); 152 extern RTLFUNC(Abs); 153 extern RTLFUNC(Asc); 154 extern RTLFUNC(Atn); 155 extern RTLFUNC(Chr); 156 extern RTLFUNC(ChrW); 157 extern RTLFUNC(Cos); 158 extern RTLFUNC(CurDir); 159 extern RTLFUNC(ChDir); // JSM 160 extern RTLFUNC(ChDrive); // JSM 161 extern RTLFUNC(FileCopy); // JSM 162 extern RTLFUNC(Kill); // JSM 163 extern RTLFUNC(MkDir); // JSM 164 extern RTLFUNC(RmDir); // JSM 165 extern RTLFUNC(SendKeys); // JSM 166 extern RTLFUNC(DimArray); 167 extern RTLFUNC(Dir); 168 extern RTLFUNC(DoEvents); 169 extern RTLFUNC(Exp); 170 extern RTLFUNC(FileLen); 171 extern RTLFUNC(Fix); 172 extern RTLFUNC(Hex); 173 extern RTLFUNC(Input); 174 extern RTLFUNC(InStr); 175 extern RTLFUNC(InStrRev); 176 extern RTLFUNC(Int); 177 extern RTLFUNC(Join); 178 extern RTLFUNC(LCase); 179 extern RTLFUNC(Left); 180 extern RTLFUNC(Log); 181 extern RTLFUNC(LTrim); 182 extern RTLFUNC(Mid); 183 extern RTLFUNC(Oct); 184 extern RTLFUNC(Replace); 185 extern RTLFUNC(Right); 186 extern RTLFUNC(RTrim); 187 extern RTLFUNC(RTL); 188 extern RTLFUNC(Sgn); 189 extern RTLFUNC(Space); 190 extern RTLFUNC(Split); 191 extern RTLFUNC(Sqr); 192 extern RTLFUNC(Str); 193 extern RTLFUNC(StrComp); 194 extern RTLFUNC(String); 195 extern RTLFUNC(StrReverse); 196 extern RTLFUNC(Tan); 197 extern RTLFUNC(UCase); 198 extern RTLFUNC(Val); 199 extern RTLFUNC(Len); 200 extern RTLFUNC(Spc); 201 extern RTLFUNC(DateSerial); 202 extern RTLFUNC(TimeSerial); 203 extern RTLFUNC(DateValue); 204 extern RTLFUNC(TimeValue); 205 extern RTLFUNC(Day); 206 extern RTLFUNC(Hour); 207 extern RTLFUNC(Minute); 208 extern RTLFUNC(Month); 209 extern RTLFUNC(MonthName); 210 extern RTLFUNC(Now); 211 extern RTLFUNC(Second); 212 extern RTLFUNC(Time); 213 extern RTLFUNC(Timer); 214 extern RTLFUNC(Weekday); 215 extern RTLFUNC(WeekdayName); 216 extern RTLFUNC(Year); 217 extern RTLFUNC(Date); 218 extern RTLFUNC(InputBox); 219 extern RTLFUNC(Me); 220 extern RTLFUNC(MsgBox); 221 extern RTLFUNC(IsArray); 222 extern RTLFUNC(IsDate); 223 extern RTLFUNC(IsEmpty); 224 extern RTLFUNC(IsError); 225 extern RTLFUNC(IsNull); 226 extern RTLFUNC(IsNumeric); 227 extern RTLFUNC(IsObject); 228 extern RTLFUNC(IsUnoStruct); 229 230 extern RTLFUNC(FileDateTime); 231 extern RTLFUNC(Format); 232 extern RTLFUNC(GetAttr); 233 extern RTLFUNC(Randomize); // JSM 234 extern RTLFUNC(Round); 235 extern RTLFUNC(Rnd); 236 extern RTLFUNC(Shell); 237 extern RTLFUNC(VarType); 238 extern RTLFUNC(TypeName); 239 extern RTLFUNC(TypeLen); 240 241 extern RTLFUNC(EOF); 242 extern RTLFUNC(FileAttr); 243 extern RTLFUNC(Loc); 244 extern RTLFUNC(Lof); 245 extern RTLFUNC(Seek); 246 extern RTLFUNC(SetAttr); // JSM 247 extern RTLFUNC(Reset); // JSM 248 249 extern RTLFUNC(DDEInitiate); 250 extern RTLFUNC(DDETerminate); 251 extern RTLFUNC(DDETerminateAll); 252 extern RTLFUNC(DDERequest); 253 extern RTLFUNC(DDEExecute); 254 extern RTLFUNC(DDEPoke); 255 256 extern RTLFUNC(FreeFile); 257 extern RTLFUNC(IsMissing); 258 extern RTLFUNC(LBound); 259 extern RTLFUNC(UBound); 260 extern RTLFUNC(RGB); 261 extern RTLFUNC(QBColor); 262 extern RTLFUNC(StrConv); 263 264 extern RTLFUNC(Beep); 265 266 extern RTLFUNC(Load); 267 extern RTLFUNC(Unload); 268 extern RTLFUNC(AboutStarBasic); 269 extern RTLFUNC(LoadPicture); 270 extern RTLFUNC(SavePicture); 271 272 extern RTLFUNC(CallByName); 273 extern RTLFUNC(CBool); // JSM 274 extern RTLFUNC(CByte); // JSM 275 extern RTLFUNC(CCur); // JSM 276 extern RTLFUNC(CDate); // JSM 277 extern RTLFUNC(CDbl); // JSM 278 extern RTLFUNC(CInt); // JSM 279 extern RTLFUNC(CLng); // JSM 280 extern RTLFUNC(CSng); // JSM 281 extern RTLFUNC(CStr); // JSM 282 extern RTLFUNC(CVar); // JSM 283 extern RTLFUNC(CVErr); // JSM 284 285 extern RTLFUNC(Iif); // JSM 286 287 extern RTLFUNC(DumpAllObjects); 288 289 extern RTLFUNC(GetSystemType); 290 extern RTLFUNC(GetGUIType); 291 extern RTLFUNC(Red); 292 extern RTLFUNC(Green); 293 extern RTLFUNC(Blue); 294 295 extern RTLFUNC(Switch); 296 extern RTLFUNC(Wait); 297 //i#64882# add new WaitUntil 298 extern RTLFUNC(WaitUntil); 299 300 extern RTLFUNC(GetGUIVersion); 301 extern RTLFUNC(Choose); 302 extern RTLFUNC(Trim); 303 304 extern RTLFUNC(DateAdd); 305 extern RTLFUNC(DateDiff); 306 extern RTLFUNC(DatePart); 307 extern RTLFUNC(FormatDateTime); 308 extern RTLFUNC(GetSolarVersion); 309 extern RTLFUNC(TwipsPerPixelX); 310 extern RTLFUNC(TwipsPerPixelY); 311 extern RTLFUNC(FreeLibrary); 312 extern RTLFUNC(Array); 313 extern RTLFUNC(FindObject); 314 extern RTLFUNC(FindPropertyObject); 315 extern RTLFUNC(EnableReschedule); 316 317 extern RTLFUNC(Put); 318 extern RTLFUNC(Get); 319 extern RTLFUNC(Environ); 320 extern RTLFUNC(GetDialogZoomFactorX); 321 extern RTLFUNC(GetDialogZoomFactorY); 322 extern RTLFUNC(GetSystemTicks); 323 extern RTLFUNC(GetPathSeparator); 324 extern RTLFUNC(ResolvePath); 325 extern RTLFUNC(CreateUnoStruct); 326 extern RTLFUNC(CreateUnoService); 327 extern RTLFUNC(CreateUnoServiceWithArguments); 328 extern RTLFUNC(CreateUnoValue); 329 extern RTLFUNC(GetProcessServiceManager); 330 extern RTLFUNC(GetDefaultContext); 331 extern RTLFUNC(CreatePropertySet); 332 extern RTLFUNC(CreateUnoListener); 333 extern RTLFUNC(HasUnoInterfaces); 334 extern RTLFUNC(EqualUnoObjects); 335 extern RTLFUNC(CreateUnoDialog); 336 extern RTLFUNC(GlobalScope); 337 extern RTLFUNC(FileExists); 338 extern RTLFUNC(ConvertToUrl); 339 extern RTLFUNC(ConvertFromUrl); 340 extern RTLFUNC(CDateToIso); 341 extern RTLFUNC(CDateFromIso); 342 extern RTLFUNC(CompatibilityMode); 343 extern RTLFUNC(CDec); 344 extern RTLFUNC(CaptureAssertions); 345 346 extern RTLFUNC(Partition); // Fong 347 348 #ifdef DBG_TRACE_BASIC 349 extern RTLFUNC(TraceCommand); 350 #endif 351 352 extern double Now_Impl(); 353 extern void Wait_Impl( bool bDurationBased, SbxArray& rPar ); 354