BASIC256.nsi0000664000175000017500000001167711675357462011025 0ustar jimjim; BASIC256.nsi ; Modification History ; date...... programmer... description... ; 2008-09-01 j.m.reneau original coding !include nsDialogs.nsh Var VERSION Var VERSIONDATE var customDialog var customLabel0 var customLabel1 var customImage var customImageHandle Function .onInit StrCpy $VERSION "0.9.6.66" StrCpy $VERSIONDATE "2011-07-06" FunctionEnd Function customPage nsDialogs::Create /NOUNLOAD 1018 Pop $customDialog ${If} $customDialog == error Abort ${EndIf} ${NSD_CreateBitmap} 0 0 100% 100% "" Pop $customImage ${NSD_SetImage} $customImage resources\images\basic256.bmp $customImageHandle ${NSD_CreateLabel} 50 0 80% 10% "BASIC256 $VERSION ($VERSIONDATE)" Pop $customLabel0 ${NSD_CreateLabel} 0 50 100% 80% "This installer will load BASIC256. Previous versions will be overwritten and any saved files will be preserved." Pop $customLabel1 nsDialogs::Show FunctionEnd ; The name of the installer Name "BASIC256 $VERSION ($VERSIONDATE)" ; The file to write OutFile "BASIC256-$VERSION_Win32_Install.exe" ; The default installation directory InstallDir $PROGRAMFILES\BASIC256 ; Registry key to check for directory (so if you install again, it will ; overwrite the old one automatically) InstallDirRegKey HKLM "Software\BASIC256" "Install_Dir" ; Request application privileges for Windows Vista RequestExecutionLevel admin InstType "Full" InstType "Minimal" ;-------------------------------- ; Pages Page custom customPage "" ": BASIC256 Welcome" Page license LicenseData "license.txt" Page components Page directory Page instfiles UninstPage uninstConfirm UninstPage instfiles ;-------------------------------- ; The stuff to install Section "BASIC256" SectionIn 1 2 RO SetOutPath $INSTDIR File .\release\BASIC256.exe File .\release\libgcc_s_dw2-1.dll File .\release\mingwm10.dll File .\release\phonon4.dll File .\release\QtCore4.dll File .\release\QtGui4.dll File .\release\sqlite3.dll File .\release\inpout32.dll File ChangeLog File CONTRIBUTORS File license.txt SetOutPath $INSTDIR\Translations File .\Translations\*.qm ; Write the installation path into the registry WriteRegStr HKLM SOFTWARE\BASIC256 "Install_Dir" "$INSTDIR" ; Write the uninstall keys for Windows WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\BASIC256" "DisplayName" "BASIC-256" WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\BASIC256" "UninstallString" '"$INSTDIR\uninstall.exe"' WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\BASIC256" "NoModify" 1 WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\BASIC256" "NoRepair" 1 WriteUninstaller "uninstall.exe" SectionEnd ; Start Menu Shrtcuts (can be disabled by the user) Section "Start Menu Shortcuts" SectionIn 1 SetOutPath $INSTDIR CreateDirectory "$SMPROGRAMS\BASIC256" CreateShortCut "$SMPROGRAMS\BASIC256\BASIC256.lnk" "$INSTDIR\BASIC256.exe" "" "$INSTDIR\BASIC256.exe" 0 CreateShortCut "$SMPROGRAMS\BASIC256\Uninstall.lnk" "$INSTDIR\uninstall.exe" "" "$INSTDIR\uninstall.exe" 0 SectionEnd ; Offline Help (can be disabled by the user for each language) SectionGroup "Off-line Help and Documentation" Section "English (en)" SectionIn 1 SetOutPath $INSTDIR\help\en File /x ".svn" .\help\en\*.* SectionEnd Section "Russian (ru)" SectionIn 1 SetOutPath $INSTDIR\help\ru File /x ".svn" .\help\ru\*.* SectionEnd Section "Spanish (es)" SectionIn 1 SetOutPath $INSTDIR\help\es File /x ".svn" .\help\es\*.* SectionEnd Section "French (fr)" SectionIn 1 SetOutPath $INSTDIR\help\fr File /x ".svn" .\help\fr\*.* SectionEnd Section "German (de)" SectionIn 1 SetOutPath $INSTDIR\help\de File /x ".svn" .\help\de\*.* SectionEnd SectionGroupEnd ; Examples (can be disabled by the user) Section "Example Programs" SectionIn 1 SetOutPath $INSTDIR File /r /x ".svn" Examples SectionEnd ;-------------------------------- ; Uninstaller Section "Uninstall" ; Remove registry keys DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\BASIC256" DeleteRegKey HKLM SOFTWARE\BASIC256 ; Remove files and uninstaller Delete $INSTDIR\BASIC256.exe Delete $INSTDIR\libgcc_s_dw2-1.dll Delete $INSTDIR\mingwm10.dll Delete $INSTDIR\phonon4.dll Delete $INSTDIR\QtCore4.dll Delete $INSTDIR\QtGui4.dll Delete $INSTDIR\sqlite3.dll Delete $INSTDIR\inpout32.dll Delete $INSTDIR\ChangeLog Delete $INSTDIR\CONTRIBUTORS Delete $INSTDIR\license.txt RMDir /r $INSTDIR\Examples RMDir /r $INSTDIR\help RMDir /r $INSTDIR\Translations Delete $INSTDIR\uninstall.exe ; Remove shortcuts, if any Delete "$SMPROGRAMS\BASIC256\*.*" ; Remove directories used RMDir "$SMPROGRAMS\BASIC256" RMDir "$INSTDIR" SectionEnd BASIC256.pro0000664000175000017500000001353411675357462011026 0ustar jimjim###################################################################### # Automatically generated by qmake (2.00a) Fri Sep 15 19:35:58 2006 ###################################################################### TEMPLATE = app TARGET = BASIC256 DEPENDPATH += . INCLUDEPATH += . TMAKE_CXXFLAGS = -g CONFIG += qt debug_and_release OBJECTS_DIR = tmp/obj MOC_DIR = tmp/moc QT += webkit RESOURCES += resources/resource.qrc RC_FILE = resources/basic256.rc TRANSLATIONS = Translations/basic256_en_US.ts \ Translations/basic256_de.ts \ Translations/basic256_ru_RU.ts \ Translations/basic256_sp.ts \ Translations/basic256_nl.ts LIBS += -lsqlite3 win32 { # use SAPI for speech DEFINES += WIN32 DEFINES += USEQSOUND LIBS += -lole32 \ -lsapi \ -lws2_32 \ -lwinmm } unix:!macx { ## this is the LINUX (unix-non-mac) DEFINES += LINUX ## TTS Option 1 - ececute 'espak' command to speak #DEFINES += LINUX_ESPEAK_EXECUTE ## TTS Option 2 - use the espeak library DEFINES += LINUX_ESPEAK INCLUDEPATH += /usr/include/espeak LIBS += -lespeak ## TTS Option 3 - use the flite library #DEFINES += LINUX_FLITE #INCLUDEPATH += /usr/include/flite #LIBS += -lflite_cmu_us_kal16 #LIBS += -lflite #LIBS += -lflite_cmulex #LIBS += -lflite_usenglish LIBS += -lm ## include libraries for SDL audio for wav and sound output DEFINES += USESDL LIBS += -lSDL LIBS += -lSDL_mixer ## rules for make install examplesDiceFiles.files = ./Examples/dice/*.kbs \ ./Examples/dice/*.wav examplesDiceFiles.path = /usr/share/basic256/Examples/dice INSTALLS += examplesDiceFiles examplesImgloadFiles.files = ./Examples/imgload/*.kbs \ ./Examples/imgload/*.png \ ./Examples/imgload/*.bmp examplesImgloadFiles.path = /usr/share/basic256/Examples/imgload INSTALLS += examplesImgloadFiles examplesNetworkingFiles.files = ./Examples/networking/*.kbs examplesNetworkingFiles.path = /usr/share/basic256/Examples/networking INSTALLS += examplesNetworkingFiles examplesSpritesFiles.files = ./Examples/sprites/*.kbs \ ./Examples/sprites/*.wav \ ./Examples/sprites/*.png \ ./Examples/sprites/*.bmp examplesSpritesFiles.path = /usr/share/basic256/Examples/sprites INSTALLS += examplesSpritesFiles examplesTestingFiles.files = ./Examples/testing/*.kbs examplesTestingFiles.path = /usr/share/basic256/Examples/testing INSTALLS += examplesTestingFiles examplesFiles.files = ./Examples/*.kbs examplesFiles.path = /usr/share/basic256/Examples INSTALLS += examplesFiles transFiles.files = ./Translations/*.qm transFiles.path = /usr/share/basic256 INSTALLS += transFiles # EN - english help files helpENFiles.files = ../doc/help/en/*.html \ ./help/en/*.css \ ./help/en/*.png \ ./help/en/*.jpg helpENFiles.path = /usr/share/basic256/help/en INSTALLS += helpENFiles # DE - german help files helpDEFiles.files = ../doc/help/de/*.html \ ./help/de/*.css \ ./help/de/*.png \ ./help/de/*.jpg helpDEFiles.path = /usr/share/basic256/help/de INSTALLS += helpDEFiles # ES - spanish help files helpESFiles.files = ../doc/help/es/*.html \ ./help/es/*.css \ ./help/es/*.png \ ./help/es/*.jpg helpESFiles.path = /usr/share/basic256/help/es INSTALLS += helpESFiles # FR - french help files helpFRFiles.files = ../doc/help/fr/*.html \ ./help/fr/*.css \ ./help/fr/*.png \ ./help/fr/*.jpg helpFRFiles.path = /usr/share/basic256/help/fr INSTALLS += helpFRFiles # RU - russian help files helpRUFiles.files = ../doc/help/ru/*.html \ ./help/ru/*.css \ ./help/ru/*.png \ ./help/ru/*.jpg helpRUFiles.path = /usr/share/basic256/help/ru INSTALLS += helpRUFiles # all language translation files transFiles.files = ./Translations/*.qm transFiles.path = /usr/share/basic256 INSTALLS += transFiles # main program executable target.path = /usr/local/bin INSTALLS += target } macx { # macintosh DEFINES += MACX DEFINES += MACX_SAY ICON = resources/basic256.icns LIBS += -L/opt/local/lib INCLUDEPATH += /opt/local/include ## include libraries for SDL audio for wav and sound output DEFINES += USESDL LIBS += -lSDL LIBS += -lSDL_mixer } exists( ./LEX/Makefile ) { message( Running make for ./LEX/Makefile ) system( make -C ./LEX ) } else { error( Couldn't make LEX project - aborting... ) } # Input HEADERS += LEX/basicParse.tab.h HEADERS += BasicEdit.h HEADERS += Interpreter.h HEADERS += RunController.h HEADERS += BasicOutput.h HEADERS += BasicGraph.h HEADERS += ErrorCodes.h HEADERS += GhostButton.h HEADERS += PauseButton.h HEADERS += DockWidget.h HEADERS += BasicWidget.h HEADERS += ToolBar.h HEADERS += ViewWidgetIFace.h HEADERS += MainWindow.h HEADERS += Variables.h HEADERS += VariableWin.h HEADERS += DocumentationWin.h HEADERS += Version.h HEADERS += EditSyntaxHighlighter.h HEADERS += Stack.h HEADERS += PreferencesWin.h HEADERS += FindWin.h HEADERS += ReplaceWin.h HEADERS += md5.h SOURCES += LEX/lex.yy.c SOURCES += LEX/basicParse.tab.c SOURCES += BasicEdit.cpp SOURCES += Interpreter.cpp SOURCES += RunController.cpp SOURCES += Main.cpp SOURCES += BasicOutput.cpp SOURCES += BasicGraph.cpp SOURCES += GhostButton.cpp SOURCES += PauseButton.cpp SOURCES += DockWidget.cpp SOURCES += BasicWidget.cpp SOURCES += ToolBar.cpp SOURCES += ViewWidgetIFace.cpp SOURCES += MainWindow.cpp SOURCES += Variables.cpp SOURCES += VariableWin.cpp SOURCES += DocumentationWin.cpp SOURCES += EditSyntaxHighlighter.cpp SOURCES += Stack.cpp SOURCES += PreferencesWin.cpp SOURCES += FindWin.cpp SOURCES += ReplaceWin.cpp SOURCES += md5.cpp basic256.sln0000664000175000017500000000156611675357462011264 0ustar jimjim Microsoft Visual Studio Solution File, Format Version 10.00 # Visual C++ Express 2008 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "basic256", "basic256.vcproj", "{9D316B66-CCFF-4100-9110-B19F86F19490}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Win32 = Debug|Win32 Release|Win32 = Release|Win32 EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution {9D316B66-CCFF-4100-9110-B19F86F19490}.Debug|Win32.ActiveCfg = Debug|Win32 {9D316B66-CCFF-4100-9110-B19F86F19490}.Debug|Win32.Build.0 = Debug|Win32 {9D316B66-CCFF-4100-9110-B19F86F19490}.Release|Win32.ActiveCfg = Release|Win32 {9D316B66-CCFF-4100-9110-B19F86F19490}.Release|Win32.Build.0 = Release|Win32 EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE EndGlobalSection EndGlobal basic256.vcproj0000664000175000017500000002124211675357462011764 0ustar jimjim BasicEdit.cpp0000664000175000017500000002600311707617312011541 0ustar jimjim/** Copyright (C) 2006, Ian Paul Larsen. ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License along ** with this program; if not, write to the Free Software Foundation, Inc., ** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. **/ #include #include #include #include #include #include #include #include #include using namespace std; #include "BasicEdit.h" #include "Settings.h" BasicEdit::BasicEdit(QMainWindow *mw) { QFont f; QSettings settings(SETTINGSORG, SETTINGSAPP); mainwin = mw; f.setFamily("Sans"); f.setFixedPitch(true); f.setPointSize(settings.value(SETTINGSFONTSIZE, SETTINGSFONTSIZEDEFAULT).toInt()); setFont(f); currentMaxLine = 10; currentLine = 1; startPos = textCursor().position(); setAcceptRichText(false); connect(this, SIGNAL(cursorPositionChanged()), this, SLOT(cursorMove())); codeChanged = false; } void BasicEdit::fontSmall() { changeFontSize(8); } void BasicEdit::fontMedium() { changeFontSize(10); } void BasicEdit::fontLarge() { changeFontSize(12); } void BasicEdit::fontHuge() { changeFontSize(15); } void BasicEdit::changeFontSize(unsigned int pointSize) { QFont f; f.setFamily("Sans"); f.setFixedPitch(true); f.setPointSize(pointSize); setFont(f); QSettings settings(SETTINGSORG, SETTINGSAPP); settings.setValue(SETTINGSFONTSIZE, pointSize); } void BasicEdit::cursorMove() { QTextCursor t(textCursor()); // get current column int col = t.position(); t.movePosition(QTextCursor::StartOfLine); col = col - t.position() + 1; t.movePosition(QTextCursor::StartOfBlock); // get line int line = 1; while (t.movePosition(QTextCursor::PreviousBlock)) { line++; } currentLine = line; // mainwin->statusBar()->showMessage(tr("Line: ") + QString::number(currentLine) + tr(" Column: ") + QString::number(col)); } void BasicEdit::highlightLine(int hline) { QTextCursor t(textCursor()); t.setPosition(0); int line = 1; while (line < hline) { t.movePosition(QTextCursor::NextBlock); line++; } t.movePosition(QTextCursor::EndOfBlock, QTextCursor::KeepAnchor, 1); setTextCursor(t); } void BasicEdit::goToLine(int newLine) { QTextCursor t(textCursor()); t.setPosition(0); int line = 1; while (line < newLine && t.movePosition(QTextCursor::NextBlock)) { line++; } setTextCursor(t); setFocus(); } void BasicEdit::keyPressEvent(QKeyEvent *e) { e->accept(); codeChanged = true; QTextEdit::keyPressEvent(e); } void BasicEdit::newProgram() { bool donew = true; if (codeChanged) { QMessageBox msgBox; msgBox.setText(tr("New Program?")); msgBox.setInformativeText(tr("Are you sure you want to completely clear this program and start a new one?")); msgBox.setStandardButtons(QMessageBox::Yes | QMessageBox::No); msgBox.setDefaultButton(QMessageBox::Yes); donew = (msgBox.exec() == QMessageBox::Yes); } if (donew) { clear(); mainwin->setWindowTitle(tr("Untitled - BASIC-256")); filename = ""; codeChanged = false; } } void BasicEdit::saveProgram() { if (filename == "") { filename = QFileDialog::getSaveFileName(this, tr("Save file as"), ".", tr("BASIC-256 File ") + "(*.kbs);;" + tr("Any File ") + "(*.*)"); } if (filename != "") { QRegExp rx("\\.[^\\/]*$"); if (rx.indexIn(filename) == -1) { filename += ".kbs"; } QFile f(filename); bool dooverwrite = true; if (f.exists()) { QMessageBox msgBox; msgBox.setText(tr("The file ") + filename + tr(" already exists.")); msgBox.setInformativeText(tr("Do you want to overwrite?")); msgBox.setStandardButtons(QMessageBox::Yes | QMessageBox::No); msgBox.setDefaultButton(QMessageBox::Yes); dooverwrite = (msgBox.exec() == QMessageBox::Yes); } if (dooverwrite) { f.open(QIODevice::WriteOnly | QIODevice::Truncate); f.write(this->document()->toPlainText().toUtf8()); f.close(); QFileInfo fi(f); mainwin->setWindowTitle(fi.fileName() + tr(" - BASIC-256")); QDir::setCurrent(fi.absolutePath()); codeChanged = false; addFileToRecentList(filename); } } } void BasicEdit::addFileToRecentList(QString fn) { // keep list of recently open or saved files // put file name at position 0 on list QSettings settings(SETTINGSORG, SETTINGSAPP); settings.beginGroup(SETTINGSGROUPHIST); // if program is at top then do nothing if (settings.value(QString::number(0), "").toString() != fn) { // find end of scootdown int e; for(e=1; e=1; i--) { settings.setValue(QString::number(i), settings.value(QString::number(i-1), "")); } settings.setValue(QString::number(0), fn); } settings.endGroup(); // print out for debugging //settings.beginGroup(SETTINGSGROUPHIST); //for (int i=0; isetPlainText(QString::fromUtf8(ba.data())); f.close(); filename = s; QFileInfo fi(f); mainwin->setWindowTitle(fi.fileName() + tr(" - BASIC-256")); QDir::setCurrent(fi.absolutePath()); codeChanged = false; addFileToRecentList(s); } } } void BasicEdit::slotPrint() { QTextDocument *document = this->document(); QPrinter printer; QPrintDialog *dialog = new QPrintDialog(&printer, this); dialog->setWindowTitle(QObject::tr("Print Code")); if (dialog->exec() == QDialog::Accepted) { if ((printer.printerState() != QPrinter::Error) && (printer.printerState() != QPrinter::Aborted)) { document->print(&printer); } else { QMessageBox::warning(this, QObject::tr("Print Error"), QObject::tr("Unable to carry out printing.\nPlease check your printer settings.")); } } } void BasicEdit::beautifyProgram() { QString program; QStringList lines; const int TAB = 3; int indent = 0; bool indentThisLine = true; bool increaseIndent = false; bool decreaseIndent = false; program = this->document()->toPlainText(); lines = program.split(QRegExp("\\n")); for (int i = 0; i < lines.size(); i++) { QString line = lines.at(i); line = line.trimmed(); if (line.contains(QRegExp("^\\S+[:]"))) { // label - one line no indent indentThisLine = false; } else if (line.contains(QRegExp("^[Ff][Oo][Rr]\\s"))) { // for - indent next (block of code) increaseIndent = true; } else if (line.contains(QRegExp("^[Nn][Ee][Xx][Tt]\\s"))) { // next - come out of block - reduce indent decreaseIndent = true; } else if (line.contains(QRegExp("^[Ii][Ff]\\s.+\\s[Tt][Hh][Ee][Nn]$"))) { // if/then (NOTHING FOLLOWING) - indent next (block of code) increaseIndent = true; } else if (line.contains(QRegExp("^[Ee][Ll][Ss][Ee]$"))) { // else - come out of block and start new block decreaseIndent = true; increaseIndent = true; } else if (line.contains(QRegExp("^[Ee][Nn][Dd]\\s*[Ii][Ff]$"))) { // end if - come out of block - reduce indent decreaseIndent = true; } else if (line.contains(QRegExp("^[Ww][Hh][Ii][Ll][Ee]\\s"))) { // while - indent next (block of code) increaseIndent = true; } else if (line.contains(QRegExp("^[Ee][Nn][Dd]\\s*[Ww][Hh][Ii][Ll][Ee]$"))) { // endwhile - come out of block decreaseIndent = true; } else if (line.contains(QRegExp("^[Dd][Oo]$"))) { // do - indent next (block of code) increaseIndent = true; } else if (line.contains(QRegExp("^[Uu][Nn][Tt][Ii][Ll]\\s"))) { // until - come out of block decreaseIndent = true; } // if (decreaseIndent) { indent -= TAB; if (indent<0) indent=0; decreaseIndent = false; } if (indentThisLine) { line = QString(indent, QChar(' ')) + line; } else { indentThisLine = true; } if (increaseIndent) { indent += TAB; increaseIndent = false; } // lines.replace(i, line); } this->setPlainText(lines.join("\n")); codeChanged = true; } void BasicEdit::findString(QString s, bool reverse, bool casesens) { QTextDocument::FindFlags flag; if (reverse) flag |= QTextDocument::FindBackward; if (casesens) flag |= QTextDocument::FindCaseSensitively; if (!find(s, flag)) { QMessageBox msgBox; msgBox.setText(tr("String not found.")); msgBox.setStandardButtons(QMessageBox::Ok); msgBox.setDefaultButton(QMessageBox::Ok); msgBox.exec(); } } void BasicEdit::replaceString(QString from, QString to, bool casesens, bool doall) { bool doone = true; QTextDocument::FindFlags flag; if (casesens) flag |= QTextDocument::FindCaseSensitively; while (doone) { if (from.compare(this->textCursor().selectedText(),(casesens ? Qt::CaseSensitive : Qt::CaseInsensitive))!=0) { if (!find(from, flag)) { QMessageBox msgBox; msgBox.setText(tr("Replace completed.")); msgBox.setStandardButtons(QMessageBox::Ok); msgBox.setDefaultButton(QMessageBox::Ok); msgBox.exec(); doall = false; } } else { this->textCursor().clearSelection(); this->textCursor().insertText(to); codeChanged = true; } doone = doall; } } BasicEdit.h0000664000175000017500000000371111707617315011212 0ustar jimjim/** Copyright (C) 2006, Ian Paul Larsen. ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License along ** with this program; if not, write to the Free Software Foundation, Inc., ** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. **/ #ifndef __BASICEDIT_H #define __BASICEDIT_H #include #include #include #include #include "ViewWidgetIFace.h" class BasicEdit : public QTextEdit, public ViewWidgetIFace { Q_OBJECT; public: BasicEdit(QMainWindow *); void loadFile(QString); void findString(QString, bool, bool); void replaceString(QString, QString, bool, bool); bool codeChanged; public slots: void newProgram(); void saveProgram(); void saveAsProgram(); void loadProgram(); void cursorMove(); void goToLine(int); void highlightLine(int); void slotPrint(); void beautifyProgram(); void fontSmall(); void fontMedium(); void fontLarge(); void fontHuge(); void loadRecent0(); void loadRecent1(); void loadRecent2(); void loadRecent3(); void loadRecent4(); void loadRecent5(); void loadRecent6(); void loadRecent7(); void loadRecent8(); protected: void keyPressEvent(QKeyEvent *); private: QMainWindow *mainwin; int currentMaxLine; int currentLine; int startPos; int linePos; QString filename; void changeFontSize(unsigned int); void addFileToRecentList(QString); void loadRecent(int); }; #endif BasicGraph.cpp0000664000175000017500000001014111675357462011724 0ustar jimjim/** Copyright (C) 2006, Ian Paul Larsen. ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License along ** with this program; if not, write to the Free Software Foundation, Inc., ** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. **/ #include #include #include #include #include #include #include #include #include using namespace std; #include "BasicGraph.h" #include "MainWindow.h" extern QMutex keymutex; extern int currentKey; BasicGraph::BasicGraph(BasicOutput *o) { image = NULL; resize(GSIZE_INITIAL_WIDTH, GSIZE_INITIAL_HEIGHT); output = o; setMinimumSize(gwidth, gheight); } void BasicGraph::resize(int width, int height) { if (image != NULL && width == image->width() && height == image->height()) { return; } gwidth = width; gheight = height; delete image; imagedata = new uchar[sizeof(int) * width * height]; image = new QImage(imagedata, width, height, QImage::Format_ARGB32); image->fill(Qt::color0); mouseX = 0; mouseY = 0; mouseB = 0; clickX = 0; clickY = 0; clickB = 0; setMouseTracking(true); } void BasicGraph::paintEvent(QPaintEvent *) { QPainter p2(this); gtop = (height() - gheight) / 2; gleft = (width() - gwidth) / 2; p2.drawImage(gleft, gtop, *image); } void BasicGraph::keyPressEvent(QKeyEvent *e) { e->accept(); keymutex.lock(); currentKey = e->key(); keymutex.unlock(); } void BasicGraph::mouseMoveEvent(QMouseEvent *e) { if (e->x() >= (int) gleft && e->x() < (int) (gleft+gwidth) && e->y() >= (int) gtop && e->y() < (int) (gtop+gheight)) { mouseX = e->x() - gleft; mouseY = e->y() - gtop; mouseB = e->buttons(); } } void BasicGraph::mouseReleaseEvent(QMouseEvent *e) { // cascade call to mouse move so we record clicks real time like moves mouseMoveEvent(e); } void BasicGraph::mousePressEvent(QMouseEvent *e) { if (e->x() >= (int) gleft && e->x() < (int) (gleft+gwidth) && e->y() >= (int) gtop && e->y() < (int) (gtop+gheight)) { clickX = mouseX = e->x() - gleft; clickY = mouseY = e->y() - gtop; clickB = mouseB = e->buttons(); } setFocus(); } bool BasicGraph::initActions(QMenu * vMenu, ToolBar * vToolBar) { if ((NULL == vMenu) || (NULL == vToolBar)) { return false; } QAction *copyAct = vMenu->addAction(QObject::tr("Copy")); QAction *printAct = vMenu->addAction(QObject::tr("Print")); vToolBar->addAction(copyAct); vToolBar->addAction(printAct); QObject::connect(copyAct, SIGNAL(triggered()), this, SLOT(slotCopy())); QObject::connect(printAct, SIGNAL(triggered()), this, SLOT(slotPrint())); m_usesToolBar = true; m_usesMenu = true; return true; } void BasicGraph::slotCopy() { QClipboard *clipboard = QApplication::clipboard(); clipboard->setImage(*image); } void BasicGraph::slotPrint() { QPrinter printer(QPrinter::HighResolution); QPrintDialog *dialog = new QPrintDialog(&printer, this); dialog->setWindowTitle(QObject::tr("Print Graphics Output")); if (dialog->exec() == QDialog::Accepted) { if ((printer.printerState() != QPrinter::Error) && (printer.printerState() != QPrinter::Aborted)) { QPainter painter(&printer); QRect rect = painter.viewport(); QSize size = image->size(); size.scale(rect.size(), Qt::KeepAspectRatio); painter.setViewport(rect.x(), rect.y(), size.width(), size.height()); painter.setWindow(image->rect()); painter.drawImage(0, 0, *image); } else { QMessageBox::warning(this, QObject::tr("Print Error"), QObject::tr("Unable to carry out printing.\nPlease check your printer settings.")); } } } BasicGraph.h0000664000175000017500000000366211675357462011403 0ustar jimjim/** Copyright (C) 2006, Ian Paul Larsen. ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License along ** with this program; if not, write to the Free Software Foundation, Inc., ** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. **/ #ifndef __BASICGRAPH_H #define __BASICGRAPH_H #include #include #include #include "ViewWidgetIFace.h" #include "BasicOutput.h" #define GSIZE_INITIAL_WIDTH 300 #define GSIZE_INITIAL_HEIGHT 300 class BasicGraph : public QWidget, public ViewWidgetIFace { Q_OBJECT; public: BasicGraph(BasicOutput *); QImage *image; bool initActions(QMenu *, ToolBar *); // used to store current location of mouse // default value of -1 when no mouse recorded over graphic output int mouseX; int mouseY; int mouseB; // used to store location of last mouse click // default value of -1 when no click recorded int clickX; int clickY; int clickB; public slots: void resize(int, int); void slotCopy(); void slotPrint(); protected: void paintEvent(QPaintEvent *); void keyPressEvent(QKeyEvent *); void mousePressEvent(QMouseEvent *); void mouseReleaseEvent(QMouseEvent *); void mouseMoveEvent(QMouseEvent *); private: uchar *imagedata; BasicOutput *output; unsigned int gwidth; unsigned int gheight; unsigned int gtop; // position of image in basicgraph widget unsigned int gleft; }; #endif BasicOutput.cpp0000664000175000017500000001003511675357462012165 0ustar jimjim/** Copyright (C) 2006, Ian Paul Larsen. ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License along ** with this program; if not, write to the Free Software Foundation, Inc., ** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. **/ #include #include #include #include #include #include #include #include #include #include #include "Settings.h" #include "BasicOutput.h" extern QMutex keymutex; extern int currentKey; BasicOutput::BasicOutput( ) : QTextEdit () { setFocusPolicy(Qt::StrongFocus); gettingInput = false; QSettings settings(SETTINGSORG, SETTINGSAPP); changeFontSize(settings.value(SETTINGSFONTSIZE, SETTINGSFONTSIZEDEFAULT).toInt()); } void BasicOutput::fontSmall() { changeFontSize(8); } void BasicOutput::fontMedium() { changeFontSize(10); } void BasicOutput::fontLarge() { changeFontSize(12); } void BasicOutput::fontHuge() { changeFontSize(15); } void BasicOutput::changeFontSize(unsigned int pointSize) { QFont f; f.setFamily("Sans"); f.setFixedPitch(true); f.setPointSize(pointSize); setFont(f); } void BasicOutput::getInput() { gettingInput = true; startPos = textCursor().position(); setReadOnly(false); setFocus(); } void BasicOutput::keyPressEvent(QKeyEvent *e) { e->accept(); if (!gettingInput) { keymutex.lock(); currentKey = e->key(); keymutex.unlock(); //QTextEdit::keyPressEvent(e); } else { if (e->key() == Qt::Key_Return || e->key() == Qt::Key_Enter) { QTextCursor t(textCursor()); t.setPosition(startPos, QTextCursor::KeepAnchor); emit(inputEntered(t.selectedText())); insertPlainText("\n"); gettingInput = false; setReadOnly(true); } else if (e->key() == Qt::Key_Backspace || e->key() == Qt::Key_Left) { QTextCursor t(textCursor()); t.movePosition(QTextCursor::PreviousCharacter); if (t.position() >= startPos) QTextEdit::keyPressEvent(e); } else if (e->key() == Qt::Key_Home || e->key() == Qt::Key_PageUp || e->key() == Qt::Key_Up) { QTextCursor t(textCursor()); t.setPosition(startPos); setTextCursor(t); } else { QTextEdit::keyPressEvent(e); } } } bool BasicOutput::initActions(QMenu * vMenu, ToolBar * vToolBar) { if ((NULL == vMenu) || (NULL == vToolBar)) { return false; } QAction *copyAct = vMenu->addAction(QObject::tr("Copy")); QAction *pasteAct = vMenu->addAction(QObject::tr("Paste")); QAction *printAct = vMenu->addAction(QObject::tr("Print")); vToolBar->addAction(copyAct); vToolBar->addAction(pasteAct); vToolBar->addAction(printAct); QObject::connect(copyAct, SIGNAL(triggered()), this, SLOT(copy())); QObject::connect(pasteAct, SIGNAL(triggered()), this, SLOT(paste())); QObject::connect(printAct, SIGNAL(triggered()), this, SLOT(slotPrint())); m_usesToolBar = true; m_usesMenu = true; return true; } void BasicOutput::slotPrint() { QTextDocument *document = this->document(); QPrinter printer; QPrintDialog *dialog = new QPrintDialog(&printer, this); dialog->setWindowTitle(QObject::tr("Print Text Output")); if (dialog->exec() == QDialog::Accepted) { if ((printer.printerState() != QPrinter::Error) && (printer.printerState() != QPrinter::Aborted)) { document->print(&printer); } else { QMessageBox::warning(this, QObject::tr("Print Error"), QObject::tr("Unable to carry out printing.\nPlease check your printer settings.")); } } } BasicOutput.h0000664000175000017500000000267311675357462011643 0ustar jimjim/** Copyright (C) 2006, Ian Paul Larsen. ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License along ** with this program; if not, write to the Free Software Foundation, Inc., ** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. **/ #ifndef __BASICOUTPUT_H #define __BASICOUTPUT_H #include #include #include #include "ViewWidgetIFace.h" class BasicOutput : public QTextEdit, public ViewWidgetIFace { Q_OBJECT; public: BasicOutput(); char *inputString; void inputStart(); virtual bool initActions(QMenu *, ToolBar *); public slots: void getInput(); void slotPrint(); void fontSmall(); void fontMedium(); void fontLarge(); void fontHuge(); signals: void inputEntered(QString); protected: void keyPressEvent(QKeyEvent *); private: int startPos; bool gettingInput; void changeFontSize(unsigned int); }; #endif BasicWidget.cpp0000664000175000017500000000435511675357462012120 0ustar jimjim/** Copyright (C) 2006, Ian Paul Larsen. ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License along ** with this program; if not, write to the Free Software Foundation, Inc., ** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. **/ #include #include "ToolBar.h" #include "ViewWidgetIFace.h" #include "BasicWidget.h" BasicWidget::BasicWidget(const QString & title, QWidget * parent, Qt::WindowFlags f) : QWidget(parent, f) , m_viewWidget(NULL) , m_toolBar(NULL) , m_menu(NULL) { m_toolBar = new ToolBar(); m_menu = new QMenu(title); m_layout = new QVBoxLayout(); setLayout(m_layout); } BasicWidget::~BasicWidget() { if (NULL != m_toolBar) { delete m_toolBar; m_toolBar = NULL; } } bool BasicWidget::setViewWidget(QWidget * view) { if (NULL == view) { return false; } m_viewWidget = dynamic_cast< ViewWidgetIFace * >(view); if (NULL != m_viewWidget) { if (m_viewWidget->initActions(m_menu, m_toolBar)) { if (!m_viewWidget->usesToolBar()) { delete m_toolBar; m_toolBar = NULL; } else { m_layout->addWidget(m_toolBar); } if (!m_viewWidget->usesMenu()) { delete m_menu; m_menu = NULL; } } m_layout->addWidget(view, 1); return true; } return false; } void BasicWidget::slotShowToolBar(const bool vShow) { if (NULL == m_toolBar) return; m_toolBar->setShown(vShow); } bool BasicWidget::usesToolBar() { if (NULL != m_viewWidget) { return m_viewWidget->usesToolBar(); } return false; } bool BasicWidget::usesMenu() { if (NULL != m_viewWidget) { return m_viewWidget->usesMenu(); } return false; } BasicWidget.h0000664000175000017500000000256011675357462011561 0ustar jimjim/** Copyright (C) 2006, Ian Paul Larsen. ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License along ** with this program; if not, write to the Free Software Foundation, Inc., ** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. **/ #ifndef __BASICWIDGET_H #define __BASICWIDGET_H #include #include class QMenu; class ToolBar; class ViewWidgetIFace; class BasicWidget : public QWidget { Q_OBJECT; public: BasicWidget(const QString & title = QString::null, QWidget * parent = 0, Qt::WindowFlags f = 0); ~BasicWidget(); bool setViewWidget(QWidget * view); bool usesToolBar(); bool usesMenu(); QMenu *getMenu() { return m_menu; } public slots: void slotShowToolBar(const bool); private: ViewWidgetIFace *m_viewWidget; ToolBar *m_toolBar; QMenu *m_menu; QVBoxLayout *m_layout; }; #endif ByteCodes.h0000664000175000017500000001727111675357462011262 0ustar jimjim/** Copyright (C) 2006, Ian Paul Larsen. ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License along ** with this program; if not, write to the Free Software Foundation, Inc., ** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. **/ //No argument ops #define OP_END 0x00 #define OP_NOP 0x01 #define OP_RETURN 0x02 #define OP_CONCAT 0x03 #define OP_EQUAL 0x04 #define OP_NEQUAL 0x05 #define OP_GT 0x06 #define OP_LT 0x07 #define OP_GTE 0x08 #define OP_LTE 0x09 #define OP_AND 0x0a #define OP_NOT 0x0b #define OP_OR 0x0c #define OP_XOR 0x0d #define OP_INT 0x0e #define OP_STRING 0x0f #define OP_ADD 0x10 #define OP_SUB 0x11 #define OP_MUL 0x12 #define OP_DIV 0x13 #define OP_EX 0x14 #define OP_NEGATE 0x15 #define OP_PRINT 0x16 #define OP_PRINTN 0x17 #define OP_INPUT 0x18 #define OP_KEY 0x19 #define OP_PLOT 0x1a #define OP_RECT 0x1b #define OP_CIRCLE 0x1c #define OP_LINE 0x1d #define OP_REFRESH 0x1e #define OP_FASTGRAPHICS 0x1f #define OP_CLS 0x20 #define OP_CLG 0x21 #define OP_GRAPHSIZE 0x22 #define OP_GRAPHWIDTH 0x23 #define OP_GRAPHHEIGHT 0x24 #define OP_SIN 0x28 #define OP_COS 0x29 #define OP_TAN 0x2a #define OP_RAND 0x2b #define OP_CEIL 0x2c #define OP_FLOOR 0x2d #define OP_ABS 0x2e #define OP_PAUSE 0x2f #define OP_POLY 0x30 #define OP_LENGTH 0x31 #define OP_MID 0x32 #define OP_INSTR 0x33 #define OP_INSTR_S 0x34 #define OP_INSTR_SC 0x35 #define OP_INSTRX 0x36 #define OP_INSTRX_S 0x37 #define OP_OPEN 0x38 #define OP_READ 0x39 #define OP_WRITE 0x3a #define OP_CLOSE 0x3b #define OP_RESET 0x3c #define OP_SOUND 0x40 //Int argument ops #define OP_GOTO 0x41 #define OP_GOSUB 0x42 #define OP_BRANCH 0x43 #define OP_NUMASSIGN 0x45 #define OP_STRINGASSIGN 0x46 #define OP_ARRAYASSIGN 0x47 #define OP_STRARRAYASSIGN 0x48 #define OP_PUSHVAR 0x49 #define OP_PUSHINT 0x4a #define OP_DEREF 0x4b #define OP_FOR 0x4c #define OP_NEXT 0x4d #define OP_CURRLINE 0x4e #define OP_DIM 0x4f #define OP_DIMSTR 0x50 #define OP_ONERROR 0x51 #define OP_EXPLODESTR 0x52 #define OP_EXPLODESTR_C 0x53 #define OP_EXPLODE 0x54 #define OP_EXPLODE_C 0x55 #define OP_EXPLODEXSTR 0x56 #define OP_EXPLODEX 0x57 #define OP_IMPLODE 0x58 //2 Int argument ops #define OP_ARRAYLISTASSIGN 0x60 #define OP_STRARRAYLISTASSIGN 0x61 //Float argument ops #define OP_PUSHFLOAT 0x70 //String argument ops #define OP_PUSHSTRING 0x80 // jmr #define OP_ASC 0x90 #define OP_CHR 0x91 #define OP_FLOAT 0x92 #define OP_READLINE 0x93 #define OP_WRITELINE 0x94 #define OP_EOF 0x95 #define OP_MOD 0x96 #define OP_YEAR 0x97 #define OP_MONTH 0x98 #define OP_DAY 0x99 #define OP_HOUR 0x9a #define OP_MINUTE 0x9b #define OP_SECOND 0x9c #define OP_SETCOLORRGB 0x9d #define OP_TEXT 0x9e #define OP_FONT 0x9f #define OP_SAY 0xa0 #define OP_WAVPLAY 0xa1 #define OP_WAVSTOP 0xa2 #define OP_SEEK 0xa3 #define OP_SIZE 0xa4 #define OP_EXISTS 0xa5 #define OP_STAMP 0xa6 // stamp with 4 numbers x,y,scale,rotation and an array #define OP_STAMP_LIST 0xa7 // stamp with x, y, and an immediate list #define OP_STAMP_S_LIST 0xa8 // stamp with x, y, scale and an immediate list #define OP_STAMP_SR_LIST 0xa9 // stamp with x, y, scale, and rotation and an immediate list #define OP_POLY_LIST 0xaa #define OP_MOUSEX 0xab #define OP_MOUSEY 0xac #define OP_MOUSEB 0xad #define OP_CLICKCLEAR 0xae #define OP_CLICKX 0xaf #define OP_CLICKY 0xb0 #define OP_CLICKB 0xb1 #define OP_LEFT 0xb2 #define OP_RIGHT 0xb3 #define OP_UPPER 0xb4 #define OP_LOWER 0xb5 #define OP_ARRAYASSIGN2D 0xb8 #define OP_STRARRAYASSIGN2D 0xb9 #define OP_DEREF2D 0xba #define OP_SYSTEM 0xbb #define OP_VOLUME 0xbc #define OP_SOUND_ARRAY 0xbd #define OP_SOUND_LIST 0xbe #define OP_SETCOLORINT 0xbf #define OP_RGB 0xc0 #define OP_PIXEL 0xc1 #define OP_GETCOLOR 0xc2 #define OP_ASIN 0xc3 #define OP_ACOS 0xc4 #define OP_ATAN 0xc5 #define OP_DEGREES 0xc6 #define OP_RADIANS 0xc7 #define OP_REDIM 0xc8 #define OP_REDIMSTR 0xc9 #define OP_REDIM2D 0xca #define OP_REDIMSTR2D 0xcb #define OP_ALEN 0xcd #define OP_ALENX 0xce #define OP_ALENY 0xcf #define OP_INTDIV 0xd0 #define OP_LOG 0xd1 #define OP_LOGTEN 0xd2 #define OP_GETSLICE 0xd3 #define OP_PUTSLICE 0xd4 #define OP_PUTSLICEMASK 0xd5 #define OP_IMGLOAD 0xd6 #define OP_IMGLOAD_S 0xd7 #define OP_IMGLOAD_SR 0xd8 #define OP_SQR 0xd9 #define OP_EXP 0xda // extended codes #define OP_EXTENDED_0 0xe0 #define OP_EXTENDED_1 0xe1 #define OP_EXTENDED_2 0xe2 #define OP_EXTENDED_3 0xe3 #define OP_EXTENDED_4 0xe4 #define OP_EXTENDED_5 0xe5 #define OP_EXTENDED_6 0xe6 #define OP_EXTENDED_7 0xe7 #define OP_EXTENDED_8 0xe8 #define OP_EXTENDED_9 0xe9 #define OP_EXTENDED_A 0xea #define OP_EXTENDED_B 0xeb #define OP_EXTENDED_C 0xec #define OP_EXTENDED_D 0xed #define OP_EXTENDED_E 0xee #define OP_EXTENDED_F 0xef // stack manipulation #define OP_STACKSWAP 0xf0 #define OP_STACKTOPTO2 0xf1 // extended opcodes (second byte) // first group e0xx #define OP_SPRITEDIM 0x00 #define OP_SPRITELOAD 0x01 #define OP_SPRITESLICE 0x02 #define OP_SPRITEMOVE 0x03 #define OP_SPRITEHIDE 0x04 #define OP_SPRITESHOW 0x05 #define OP_SPRITECOLLIDE 0x06 #define OP_SPRITEPLACE 0x07 #define OP_SPRITEX 0x08 #define OP_SPRITEY 0x09 #define OP_SPRITEH 0x0a #define OP_SPRITEW 0x0b #define OP_SPRITEV 0x0c #define OP_CHANGEDIR 0x0d #define OP_CURRENTDIR 0x0e #define OP_WAVWAIT 0x0f #define OP_DECIMAL 0x10 #define OP_DBOPEN 0x11 #define OP_DBCLOSE 0x12 #define OP_DBEXECUTE 0x13 #define OP_DBOPENSET 0x14 #define OP_DBCLOSESET 0x15 #define OP_DBROW 0x16 #define OP_DBINT 0x17 #define OP_DBFLOAT 0x18 #define OP_DBSTRING 0x19 #define OP_LASTERROR 0x1a #define OP_LASTERRORLINE 0x1b #define OP_LASTERRORMESSAGE 0x1c #define OP_LASTERROREXTRA 0x1d #define OP_OFFERROR 0x1e #define OP_NETLISTEN 0x1f #define OP_NETCONNECT 0x20 #define OP_NETREAD 0x21 #define OP_NETWRITE 0x22 #define OP_NETCLOSE 0x23 #define OP_NETDATA 0x24 #define OP_NETADDRESS 0x25 #define OP_KILL 0x26 #define OP_MD5 0x27 #define OP_SETSETTING 0x28 #define OP_GETSETTING 0x29 #define OP_PORTIN 0x2a #define OP_PORTOUT 0x2b #define OP_BINARYOR 0x2c #define OP_BINARYAND 0x2d #define OP_BINARYNOT 0x2e #define OP_IMGSAVE 0x2f #define OP_DIR 0x30 #define OP_REPLACE 0x31 #define OP_REPLACE_C 0x32 #define OP_REPLACEX 0x33 #define OP_COUNT 0x34 #define OP_COUNT_C 0x35 #define OP_COUNTX 0x36 #define OP_OSTYPE 0x37 #define OP_MSEC 0x38 #define OP_EDITVISIBLE 0x39 #define OP_GRAPHVISIBLE 0x40 #define OP_OUTPUTVISIBLE 0x41 #define OP_TEXTWIDTH 0x42 ChangeLog0000664000175000017500000006722411675357462011005 0ustar jimjim2011-08-08 j.m.reneau 0.9.6.68 * added TEXTWIDTH statement to return width of a string i the current font before output to the graphics area 2011-08-07 j.m.reneau 0.9.6.67 * added -r option to command line to switch UI to run only mode 2011-07-01 j.m.reneau 0.9.6.66 * changed inpout32.dll linking to dynamic for Windows port to eliminate the dll hell * merged in http://patch-tracker.debian.org/patch/series/view/basic256/0.9.6.60-2/04_portable_sound.diff * fix off-line documentation load on windows - to use the application absolute path to fing help folder 2011-05-01 j.m.reneau 0.9.6.65 * renamed spanish help file to es not sp 2011-03-19 j.m.reneau 0.9.6.65 * Added GRAPHVISIBLE, EDITVISIBLE, and OUTPUTVISIBLE statements to hide sections if the UI from a running program. 2011-03-18 j.m.reneau 0.9.6.64 * Added option to View menu to hide Edit Widget (program source) 2011-03-17 Javier Gonzlez * new Spanish UI translation 2011-03-05 j.m.reneau 0.9.6.63 * Added replace dialog and refined find dialog 2011-03-04 j.m.reneau 0.9.6.62 * Added find dialog 2011-02-14 j.m.reneau 0.9.6.61 * fixed windows only problem with DIR statement * restructured and documented the doc tree * worked on the windows installer to allow for optional install of offline help and examples 2011-02-14 j.m.reneau 0.9.6.60 * added MSEC function to return program running time in milliseconds 2011-01-20 j.m.reneau 0.9.6.59 * added option to use espeak for TTS from shell not as a library * update documentation in BASIC256.pro and COMPILING.txt 2011-01-07 j.m.reneau 0.9.6.58 * added OSTYPE function to return the type of OS this was compiled 2011-01-06 j.m.reneau 0.9.6.57 (473) * added IMPLODE to change an array to a string * updated Russian translation 2011-01-05 j.m.reneau 0.9.6.56 (469) * added INSTRX() to return position of a Regular Expression * added REPLACEX() function to find an regular expression and replace with a string * added COUNTX() function to retuen number of occourances of a regular expression * added EXPLODEX() function to split a string into a string or numeric array on a regular expression 2011-01-03 j.m.reneau 0.9.6.55 (468) * allow assignment of indirect list of values {} to redimision an array to the correct size * added two optional arguments to INSTR() - Start and IgnoreCase * added Unicode safe string REPLACE() function * added Unicode safe substring count COUNT() function * added EXPLODE() function to split a string into a string or numeric array 2011-01-02 j.m.reneau 0.9.6.54 (467) * added dir() function 2010-12-31 sergey irupin 0.9.6.53 (466) * add offline help system * replace About window * fixed highlighting of keywords 2010-12-13 j.m.reneau 0.9.6.53 (452) * changed variables object to use a map for storage and not a static array - in preparation for some day handling run levels 2010-12-12 j.m.reneau 0.9.6.52 (451) * moved variables out of interperter into a new object in preparation for some day adding multiple run levels to handle true functions and subroutines * also celeaned up several variable related memory leaks 2010-12-10 sergey irupin 0.9.6.51 (449) * add 2 mathematics functions - sqr()/sqrt(), exp() 2010-11-26 sergey irupin 0.9.6.50 (448) * icon updates and fixed functions upper() and lower() 2010-11-18 j.m.reneau 0.9.6.49 (443) * added close of database files if database not closed by program 2010-11-03 j.m.reneau 0.9.6.48 (439) * removed mutex from say statement - eliminate frezing after speech 2010-10-25 j.m.reneau 0.9.6.47 (438) * initial MAC port - tested help & preferences * added Mac Icon * added logic to save font size as a preference 2010-10-24 j.m.reneau 0.9.6.46 (437) * initial MAC port - tested sound, say, playwav, database, and networking 2010-10-17 j.m.reneau 0.9.6.45 (435) * added IMGSAVE statement to save graphics area as a .png or other qt supported file type 2010-10-15 j.m.reneau 0.9.6.44 (434) * forces locale to "C" so that decimal mark '.' will always work 2010-10-11 j.m.reneau 0.9.6.43 (433) * fixed seek statement 2010-09-21 j.m.reneau 0.9.6.42 * tested inpout32 with Windows7-x64 and Vista-x32 and changed compiling instructions 2010-09-20 j.m.reneau 0.9.6.41 (431) * finished and tested PORTIN/PORTOUT statements for parallel port control (WINDOWS ONLY) * added preference settings to allow or disable PORTIN/PORTOUT statements * added three new operators &, | and ~ - bitwise and or and not that work with integers 2010-09-19 j.m.reneau 0.9.6.40 (430) * INCOMPLETE - Code to start adding PORTIN/PORTOUT statementf for parallel port control 2010-09-14 j.m.reneau 0.9.6.39 (429) * fixed SYSTEM statement to use mutex to wait correctly * added preference settings to allow or disable system, get/setsetting 2010-09-12 j.m.reneau 0.9.6.38 (428) * added GETSETTING and SETSETTING for persistant application storage to the registery/config folder 2010-09-12 j.m.reneau 0.9.6.37 (427) * Created password protected preferences dialog - nothing on it yet except the password * added MD5 function to return a hex string digest for a string 2010-09-11 j.m.reneau 0.9.6.36 (425) * added settings to restore IDE and help to size and location when re-opened * added list of 9 most recently opened or saved items for quick open on file menu 2010-09-08 j.m.reneau 0.9.6.35 (423) * Added NETADDRESS to return the local IPv4 address as a string 2010-09-06 j.m.reneau 0.9.6.34 (422) * Added kill statement to delete a file from the file system 2010-08-22 j.m.reneau 0.9.6.33 (421) * fixed problem with focus effecting "key" statement - if focus was ever lost from - graphics window - key statement would stop working. added key trap to BasicOutput - and logic to allow BasicGraph to regain focus * syntax highliter updated for a few misses commands 2010-08-17 j.m.reneau 0.9.6.32 (419) * Added net* statements and functions to the syntax highlighter and a new networking example 2010-08-17 j.m.reneau 0.9.6.31 (418) * fixed linux to compile again after changes in 0.9.6.30 * removed most of the errors from LEX/basicParse.y 2010-08-17 j.m.reneau 0.9.6.30 (416) * changed all tokens to B256... in lex folder to stop conflicts with windows wtypes.h * work on porting to winsock (Windows) - have functioning well enough to test * changed net commands to act like file io commands and allow up to 8 open - sockets 0-7 with 0 being the default. 2010-08-15 j.m.reneau 0.9.6.29 (416) * cleaned up socket release (close) * added NETDATA function to return true if data is waiting to be received 2010-08-13 j.m.reneau 0.9.6.28 (415) * added first attempt at networking statements - statements NETLISTEN, NETCONNECT, NETREAD, NETOPEN, and NETCLOSE * added new networking folder to Examples with a few test programs * not compiled or tested in Windows yet. 2010-08-09 j.m.reneau 0.9.6.27 (412) * fixed string comparison problem caused since 0.9.6h 2010-08-05 j.m.reneau 0.9.6z (409) * Rewrote the error messaging process to allow for error trapping and reporting logic in BASIC code * added ONERROR label to jump to a subroutine to handle errors * added LASTERROR, LASTERRORMESSAGE, LASTERRORLINE, and LASTERROREXTRA functions that describe last runtime error * added OFFERROR statement to restore default error handling - fail on error * changed parser to allow labels at the begining of any line or on a line by themselves * added display of column number of cursor in status bar when editing * added _ as a valid character in a veriable or label name (first letter MUST still be a letter) 2010-08-02 j.m.reneau 0.9.6y * Added sqLite database processing - dbopen, dbclose, dbsetopen, dbsetclose, and dbexecute statements, also dbint, dbfloat, dbstring, and dbrow functions to manipulate recordsets 2010-07-27 j.m.reneau 0.9.6x * left alen, alenx, and aleny in lex files when adding 2d and redim of arrays - unused - removed 2010-07-26 j.m.reneau 0.9.6w (405) * added decimal statemene to define maximum number of decimal places to display (full precision of a double is still being maintained behind the scenes) * fixed web site on about box * added recent new statements to syntax highliter 2010-07-21 j.m.reneau 0.9.6v (403) * fixed several gramatical errors with file messages - thanks joel * removed maximum size of graphical output widget 2010-07-13 j.m.reneau 0.9.6u (402) * fixed wavwait logic for compile under Win32. Also noticed in the QSound documentation that wavwait will not work under Windows because of a quirk with the library. * made the graphics and text output so that they may float 2010-07-04 j.m.reneau 0.9.6t * added new wavwait statement to wait for the currently playing wav to finish 2010-07-02 j.m.reneau 0.9.6s * totally re-wrote linux sound functionallity to use the SDL library and SDL_mixer. Resolved issued with QSound (requiring NAS) and the /dev/dsp not being released bu the TTS libraries. 2010-06-25 j.m.reneau 0.9.6r * added currentdir and changedir statements to manage the current folder * moved documentation to WIKI at doc.basic256.org and changed link in documentwindow. 2010-06-25 j.m.reneau 0.9.6q * found read statement removed from LEX - readded * fixed string pointer conversion in readline * changed sprite move to limit range to 0-graphwidth|graphheight-1 * changed all file io statements to allow for 0-7 files simultaneously - syntax didn't change for single file operations but new filenumber parameter added to allow for multiple files 2010-06-14 j.m.reneau 0.9.6p (393) * re-wrote the way color "Clear" works - getcolor and pixel will return a -1 when the drawing color or pixel requested is clear (or after a clg and nothing has been drawn there) - the CLEAR constant/function now has a value of -1 - all of the drawing commands (point,line,rect,cir,poly,stamp) now will replace pixels with a transparent when color is clear # added clear of the graphics output area - when initialized to cleanup LINUX display 2010-06-13 j.m.reneau 0.9.6o * added spritev - visible function * added spriteslice - extract a sprite from the screen and demo program * changed sprite to be not visible when created - so that is can be moved and so that it does not change the screen when sliced out. 2010-06-09 j.m.reneau 0.9.6n * fixed several memory leaks with strings from stack and variable assignments * added sprites - spritedim, spriteload, spritemove, spriteplace, spritex, spritey, spritew, spriteh, and spritecollide 2010-06-07 j.m.reneau 0.9.6m * fixed linux compile with lib espeak * added logic to parser to allow for whitespace before a label - to allow older examples to run 2010-06-01 j.m.reneau 0.9.6l * fixed help display path when windows installed. * added getslice, putslice, and imgload into syntax highlighter * changed imgload from 0.9.6k to place the center of the image at the specified coordinates * added rotate and scale parameters to imgload like stamp 2010-05-31 j.m.reneau 0.9.6k (377) * added imgload statement to load a bmp, gif, jpg, or pgn from a file and siaplsy it on the graphics output window * compiled new ru translation from Sergey 2010-05-25 j.m.reneau 0.9.6j (376) * added ability to enter integers in code with 0[bB][01] for binary 0[oO][0-7] for octal and 0[xX][0-9a-fA-F] for hexidecimal 2010-05-18 j.m.reneau 0.9.6i (374) * added dialog to verify overwriting file * added dialog to verify loading program and loosing changes * changed new dialog to only appear if unsaved changes are in buffer * added dialog on close to verify loosing changes (both exit and window close) * added undo and redo to menu and toolbar for editor * changed genhelp.list to make all ids and see also links lowercase - for LINUX 2010-05-18 j.m.reneau 0.9.6h (370) * added search to Documentation Window 2010-05-17 j.m.reneau 0.9.6g (369) * changed Documentation Window to use WebView to fix the #tags for navigation 2010-05-12 j.m.reneau 0.9.6f (362) * added error statements to linus sound and speech functions. They are still rough and troublesome. 2010-05-11 j.m.reneau 0.9.6e (361) * added statements to BASIC256.pro file so qmake would make the "make install" for linux to ease build 2010-05-10 j.m.reneau 0.9.6c (359) * changes for fontsize * update Russian translation 2010-05-09 j.m.reneau 0.9.6b (353) * GetSlice returns a hex string representing a slice (rectangular area) of the screen * PutSlice will draw the slice. you may defina a transparent color in slice. 2010-05-02 j.m.reneau 0.9.6a (350) * handle Utf8 strings (drblast) * rewrite string functions to use unicode characters * now program save and load in utf8 * compiled RU translation 2010-04-18 j.m.reneau 0.9.5v (329) * added \ operator for integer division * added log() and log10() functions 2010-04-15 j.m.reneau 0.9.5t (326) * Redim an array to change it's size while maintaining it's contents 2010-03-08 j.m.reneau 0.9.5m (318) * changed color staretemt to accept a single number RGB value r*255^2+g*255+b. * changed colors to constants that return a color integer * added rgb function to take color triplet and return color integer * added getcolor to return the value of the current drawing color * added pixel to get the color value of a pixel on the graphics output 2010-02-01 j.m.reneau 0.9.5l (316) * finished linux implementastion of new sound command 2010-01-29 j.m.reneau 0.9.5j (315) * added cut, copy and paste icons to tool bar * added option for sound to accept an array or list of frequency and durations. This allows for fast smooth transition when playing multiple tones in a stream. linux logic not tested with this commit. 2010-01-28 j.m.reneau 0.9.5i (312) * added volume command to control the amplitude of the sound wave out * changed LINUX TTS to flite engine from espeak. espeak was having problems releasing the /dev/dsp device * cleaned up syntax high-liter 2010-01-26 j.m.reneau 0.9.5h (311) * added system command and cleaned up documentation 2010-01-26 j.m.reneau 0.9.5g (310) * re-wrote say to use libespeak under linux - need to get same change made to windows * added logic to do the sound command in LINUX by writing a sine wave to /dev/dsp * update doc.lisp and compiling.txt with info * changed say command to use Microsoft SAPI instead of running a command line version of espeak. Also changed the Windows version of sound to generate a wave out to the soundcard and only use the system speaker if sound is not available (sound on a laptop) 2010-01-16 j.m.reneau 0.9.5e (308) * added UPPER and LOWER character functions, cleaned up syntax highlighter 2010-01-15 j.m.reneau 0.9.5c (306) * added two dimensional arrays to language (dim, reference, assignment, and input without prompt. Still need to add to input with a prompt. * updated documentation and 15puzzle.kbs example 2010-01-12 j.m.reneau 0.9.5c (303) * added left and right string functions, documented them * cleaned up syntax highliter with newer reserved words and fixed string highlight 2009-12-25 j.m.reneau 0.9.4g (296) * added multi line if/endif and if/else/endif. a;so added while/endwhile loop 0.9.4f * Asc, Chr, Float, Font, Text 2009-12-21 j.m.reneau 0.9.4e * added mouse functions - Mouseb, Mousex, Mousey, Clickb, Clickx, Clicky, Clickclear 2009-12-03 j.m.reneau 0.9.4 * added date and time functions - Day, Hour, Minute, Month, Second, Year * added file functions - Eof, Writeline, Exist, Seek, Size * added sound and speak functions - Say, WAVplay, WAVstop 2009-11-05 j.m.reneau 0.9.3o * added STAMP to draw a scaled poly at a position on the graphics display - sort of a simple sprite * added TRUE and FALSE boolean constant values * corrected problem with x&y reversing when an indirect list was defined for a POLY * removed the unused number of points from the syntax of POLY 2009-11-04 j.m.reneau 0.9.3n * added SIZE, EXISTS, and SEEK for use during file IO 2009-11-02 j.m.reneau 0.9.3m * rewrite popint/popfloat/popstring in interperter.cpp to return type not a stack value 2009-11-01 j.m.reneau 0.9.3l * added alternate syntax of input statement to allow a numeric variable or array. If non numeric data is entered a zero will be stored in the variable * added logic to allow for < > <= >= comparisons of strings 2009-10-31 j.m.reneau 0.9.3k * added WAVPLAY and WAVSTOP commands to asynchronously play a wav audio file and to stop it 2009-10-29 j.m.reneau 0.9.3j * added GRAPHHEIGHT and GRAPHIDTH to return the size of the graphics window * worked on the HTML documentation, added GRAPHSIZE, GRAPHWIDTH, and GRAPHHEIGHT 2009-10-28 j.m.reneau 0.9.3.i * worked my prior changes into the trunk 2009-10-26 j.m.reneau 0.9.3h * changed say statement to allow for same arguments (float and string) as print * changes say to use espeak without a direct path to the exe file. requires espeak in path on windows 2008-09-23 j.m.reneau 0.9.3g * added SAY statement to call locally installed espeak to tts string - need to re-write for linux and would like to see it use the espeak lib 2008-09-08 j.m.reneau 0.9.3f * added font "fontname", point, weight and text x, y, "txt" commands to paint text onto the graphics window (TestPrograms/testtextfont.kbs" 2008-09-07 * added logic to yyerror in LEX\basicParse.y to fix syntax error line number problem. If an error was the last token on the line it would report the error on the next line. check yytoken if \n and if it is then report previous line * added column number to syntax error printing - added count logic to basicParse.l * fixed rand - it would return values between 0 and 1 with 1 inclusive changed to return almost one but not quite (see TestPrograms/random_one.kbs) 2008-09-05 * changed yacc scriopt for order of operations * removed imask logic from BasicGraph and Interperter. Was causing refresh and draw errors on fast (dual core win32 xp&vista) boxes * split version # out of MainWindow into Version.h 2008-09-01 * Added array testing to array input like logic added 2008-08-29 * Added COLOR #,#,# to set colors by rgb * changed poly to draw filled not just outline * created NSIS install script for Win32 2008-08-29 * Added Functions asc, chr, float * Added command readline and writeline to i/o an entire line as a string * Added boolean flag eof to test if file was at eof * added % operator for modulo * added logic to allow for concatenation if float + string or string + float * combined redudant graphics wait mutex logic in Interperter * in Interperter added popint, popfloat, popstring to the stack and changed most ops to use these new pops so that type checking could be removed in the op code * found error in array element assign (string and number) if assigning as an array a non array variable or a non defined variable * found error in arraylist assign (string and number) if assigning as an array a non array variable or a non defined variable - see uaarray.kbs * added print statement with no string to go to next line * added YEAR MONTH DAY HOUD MINUTE SECOND as constants like RAND and PI 2006-12-12 ian larsen * LEX\basicParse.y: Added sound command. * LEX\basicParse.l: Added sound command. * RunController.cpp (playSound): Added sound support. * Interpreter.cpp (execByteCode): Added sound support. 2006-12-10 ian larsen * BasicEdit.cpp (newProgram): fixed file overwrite bug when new program saves as last file's name. * LEX\basicParse.l: Added semicolon as alternate remark command 2006-12-04 ian larsen 0.9.1 * VariableWin.cpp (addVar): Changed variable window to use TreeWidget instead of a list, to allow for showing arrays. 2006-11-28 ian larsen 0.9 * Interpreter.cpp (execByteCode): Changed variable window updates to only occur in debug mode. Otherwise this is a severe performance hit for programs updating many variables in tight loops. * VariableWin.cpp (clearTable): Added Variable Watch window. 2006-11-26 ian larsen * MainWindow.cpp (QMainWindow): Added two items to view menu to enable/disable text and graphics output windows. 2006-11-20 ian larsen * Interpreter.cpp (execByteCode): Merged file ops and changed them to work more simply. * Changed array printing to print pointer address instead of int, which should fix the 64 bit compile problem. 2006-11-19 * Added file operations "open", "read", "write", "close". The read and write functions work on a token basis. EOF is returned by returning an empty token. * Added code to test new functions "fileops1.kbs" (and 2 and 3). 2006-11-17 * Added string "length" function and sample code "length.kbs" * Added alternative spelling for "color" function: "colour" * Added "poly" function and sample code "polygon.kbs" 2006-11-07 ian larsen 0.8 * LEX\basicParse.y: Fixed rather important memory allocation bug that affected large programs that used lots of if statements. * Interpreter.cpp (execByteCode): Fixed bug 1589686 2006-11-03 ian larsen * Interpreter.cpp (compileProgram): Changed the way the interpreter keeps track of line numbers. Now there's a CURRLINE bytecode which is executed every time the line changes. Also added step-by-step debugging. 2006-11-02 ian larsen * Interpreter.cpp (execByteCode): Printing of floating point instead of integers fixed. 2006-11-01 ian larsen * Interpreter.cpp (execByteCode): Added OP_LINE, which draws lines. 2006-10-31 ian larsen * Interpreter.cpp (execByteCode): Added pause command * BasicEdit.cpp (cursorMove): Added slot to calculate line number when the cursor moves, and display it on the status bar. 2006-10-25 ian larsen 0.7 * Main.cpp (main): Added actions to edit menu. Removed close button on output windows. 2006-10-20 ian larsen 0.6 * Interpreter.cpp: Added internationalization support. * BasicEdit.cpp: Added internationalization support. * Main.cpp (main): Added internationalization support. 2006-10-18 ian larsen * BasicEdit.cpp (BasicEdit): Editor now won't accept rich text, fixing weird font bugs. * RunController.cpp (saveByteCode): Added saveByteCode function which saves the compiled byte code to a .kbc file. * Main.cpp (main): Added save byte code function and Advanced menu. * LEX\basicParse.y: Changed to more dynamic allocation of byteCode to reduce memory footprint for small programs and to prevent memory errors from occurring on 64-bit architectures. * Interpreter.cpp (execByteCode): Added mathematical functions FLOOR, CEIL, RAND, SIN, COS, TAN, and ABS Separated initialize from compileProgram to support saving byte code as a file. 2006-10-16 ian larsen 0.5 * Interpreter.cpp (execByteCode): Added and, not, xor, and or operations * LEX\basicParse.y: Added AND, NOT, XOR, OR * LEX\basicParse.l: Added floor, ceil, int, str, and rand tokens * LEX\basicParse.y: Added arrays and string arrays. * Interpreter.h (struct variable): Added arrays and string arrays. * Interpreter.cpp (execByteCode): Added arrays and string arrays. 2006-10-11 ian larsen 0.4 * BasicGraph.cpp (keyPressEvent): Added keyPressEvent to set currentKey global variable whenever a key is pressed during run time. * LEX\basicParse.y: Added KEY keyword as floatexpr * Interpreter.cpp (execByteCode): Added OP_KEY operation, which gets the last key pressed. 2006-10-09 ian larsen * LEX\basicParse.y: Added colon as multiple statement separator 2006-10-07 0.3.1 * RunController.cpp (stopRun): Changed to threaded model. * Interpreter.cpp (execByteCode): Changed to a threaded model. * BasicOutput.cpp (getInput): Added slot to support threading. * Interpreter.cpp (execByteCode): Changed from using QPixmaps for graphical output to QImage, which is thread-safe. 2006-10-06 ian larsen 0.3 * Interpreter.cpp (pause): Removed unnecessary pause and unpause functions * RunController.cpp (pauseResume): Enabled Pause/Resume feature * PauseButton.h: Created Pause button which changes text based on operation * Main.cpp (main): Removed Renumber Lines menu option (main): Pause/Resume button enabled 2006-09-30 ian larsen 0.1 * n sourceforge.net uploaded the first version COMPILING.txt0000664000175000017500000000703611675357462011310 0ustar jimjimCompiling Instructions and Dependencies - 2011-06-30 LINUX you will need: * g++ * qt4-dev-tools * flex * bison * libsdl-mixer??-dev * libespeak-dev (if using the LINUX_ESPEAK option in BASIC256.pro) - this option gives an integrated library approach to the say statement * espeak (if using the LINUX_ESPEAK_EXECUTE option in BASIC256.pro) - use this option and install if the library use of portaudio conflicts with other sound systems installed * and the sqlite3 amalgamation installed from sqlite.org Windows you will need: * mingw c++ compiler for Win32 and the qt sdk - the easiest way to get this installed and working is to use the Qt SDK version 1.x.x from the downloas page at QT. Choose a custom install and select mingw to be installed - You will have problems getting this to work if you do not have the EXACT mingw version required - be sure you have the following (or similar) fildres listed in the PATH system variable C:\QtSDK\mingw\bin and C:\QtSDK\Desktop\Qt\4.7.3\mingw\bin * gtk win32 bundle headers and libraries from http://www.gtk.org/download/win32.php - extract the zip file to the mingw folder * the gretl development headers need to be added to mingw they are in a file called mingw-extra.zip and can be found at http://ricardo.ecn.wfu.edu/pub/gretl/winbuild/ * sqlite development libraries and headers need to be installed and downloaded fron http://www.sqlite.org/download.html - use the *amalgation* zip file and copy the *.h files into MinGW/include - download the windows dll zip file, extract files into MinGW/lib, and run the following dlltool -D sqlite3.dll -d sqlite3.def -l libsqlite3dll.a - you will also need to place the sqlite.dll file in the project/trunk/debug and project/trunk/release folders. * inpout32.dll - download version 1.2 from http://www.highrez.co.uk/Downloads/InpOut32/default.htm - copy the file inpout32.dll into MinGW/lib - you will also need to place the inpout32.dll and inpout32.sys fileg in the project/trunk/debug and project/trunk/release folders. For MAC 10.6.4 - QT - XCode (from apple) - MACPorts (Porticus front end is handy) - sqlite3 - flex - libsdl_dev - libsdl_dev-framework - libsdl_mixer - libsdl_mixer-framework Build Windows MINGW, LINUX, and MACX (g++): open a command window (cmd) type "make clean" and hit enter type "qmake" and hit enter - for MACX "qmake -spec macx-g++" type "make" and hit enter You'll see an executable called BASIC256 either in this directory or in a "debug" directory, depending on your version of QT. linux: "make install" will install translations, help and binary You can then create a launcher to "BASIC256" or "BASIC256 -l locale". windows (observed under vista business sp2): make will not work because of Microsoft's command line length issue. A possible work around would be to use 'msys'. It gives a unix like shell to work from without the problem. Release Build (Windows): To build a nice WIN32 installer use the nullsoft scriptable install system file 2.39 or better) called BASIC256.nsi. You must build a release copy of BASCI256. You must also copy the QtCore4.dll, QtGui4.dll, sqlite3.dll, and mingwm10.dll to the release folder before testing the build or running the installer script. Under QT 4.5.3 be sure to use the dlls from C:\Qt\nnnn.nn\qt\bin and not the ones from C:\Qt\nnnn.nn\bin. make clean qmake -config release make release then run the NSIS script CONTRIBUTORS0000664000175000017500000000062611675357462011104 0ustar jimjim Developers ----------- Ian Larsen Tony Dann Ferry Hendrikx Jim Reneau Sergey Irupin Translators ----------- Immo-Gert Birn German Ferry Hendrikx Dutch Damir Shayhutdinov Russian Sergey Irupin Russian Javier González Spanish DockWidget.cpp0000664000175000017500000000226311675357462011753 0ustar jimjim/** Copyright (C) 2006, Ian Paul Larsen. ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. **/ #include "DockWidget.h" DockWidget::DockWidget( const QString & title, QWidget * parent, Qt::WindowFlags flags ) : QDockWidget( title, parent, flags ) , m_pWidget( NULL ) { } DockWidget::DockWidget( QWidget * parent, Qt::WindowFlags flags ) : QDockWidget( parent, flags ) , m_pWidget( NULL ) { } void DockWidget::setWidget( QWidget * vpWidget ) { m_pWidget = vpWidget; QDockWidget::setWidget( m_pWidget ); } DockWidget.h0000664000175000017500000000211711675357462011416 0ustar jimjim/** Copyright (C) 2006, Ian Paul Larsen. ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. **/ #include class DockWidget : public QDockWidget { Q_OBJECT public: DockWidget( const QString & title, QWidget * parent = 0, Qt::WindowFlags flags = 0 ); DockWidget( QWidget * parent = 0, Qt::WindowFlags flags = 0 ); void setWidget( QWidget * vpWidget ); private: QWidget * m_pWidget; }; DocumentationWin.cpp0000664000175000017500000000577711675357462013233 0ustar jimjim/** Copyright (C) 2010, J.M.Reneau, S.W.Irupin ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License along ** with this program; if not, write to the Free Software Foundation, Inc., ** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. **/ #include using namespace std; #include "DocumentationWin.h" #include "MainWindow.h" DocumentationWin::DocumentationWin (QWidget * parent) :QDialog(parent) { QString localecode = ((MainWindow *) parent)->localecode; QString windowsPath = QApplication::applicationDirPath() + "/help/"; QString linuxPath = "/usr/share/basic256/help/"; QString currentPath = "./"; QString indexfile = "index.html"; // position where it was last on screen QSettings settings(SETTINGSORG, SETTINGSAPP); resize(settings.value(SETTINGSDOCSIZE, QSize(700, 500)).toSize()); move(settings.value(SETTINGSDOCPOS, QPoint(150, 150)).toPoint()); docs = new QTextBrowser( this ); toolbar = new QToolBar( this ); QAction *backward = new QAction(QIcon(":images/backward.png"), tr("&Back"), this); connect(backward, SIGNAL(triggered()), docs, SLOT(backward())); connect(docs, SIGNAL(backwardAvailable(bool)), backward, SLOT(setEnabled(bool))); toolbar->addAction(backward); QAction *forward = new QAction(QIcon(":images/forward.png"), tr("&Forward"), this); connect(forward, SIGNAL(triggered()), docs, SLOT(forward())); connect(docs, SIGNAL(forwardAvailable(bool)), forward, SLOT(setEnabled(bool))); toolbar->addAction(forward); QAction *home = new QAction(QIcon(":images/home.png"), tr("&Home"), this); connect(home, SIGNAL(triggered()), docs, SLOT(home())); toolbar->addAction(home); toolbar->addSeparator(); QAction *exit = new QAction(QIcon(":images/exit.png"), tr("&Exit"), this); connect(exit, SIGNAL(triggered()), this, SLOT(close())); toolbar->addAction(exit); layout = new QVBoxLayout; layout->addWidget(toolbar); layout->addWidget(docs); this->setLayout(layout); this->setWindowTitle(QObject::tr("BASIC-256 Reference")); this->show(); docs->setSearchPaths(QStringList() << windowsPath+localecode.left(2) << linuxPath+localecode.left(2) << currentPath+localecode.left(2) << windowsPath+"en" << linuxPath+"en" << currentPath+"en"); docs->setSource(QUrl(indexfile)); } void DocumentationWin::resizeEvent(QResizeEvent *e) { this->resize(size()); } void DocumentationWin::closeEvent(QCloseEvent *e) { QSettings settings(SETTINGSORG, SETTINGSAPP); settings.setValue(SETTINGSDOCSIZE, size()); settings.setValue(SETTINGSDOCPOS, pos()); } DocumentationWin.h0000664000175000017500000000230711675357462012662 0ustar jimjim/** Copyright (C) 2010, J.M.Reneau. ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License along ** with this program; if not, write to the Free Software Foundation, Inc., ** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. **/ #include #include #include #include #include #ifndef DOCUMENTATIONWINH #define DOCUMENTATIONWINH class DocumentationWin : public QDialog { Q_OBJECT; public: DocumentationWin(QWidget * parent); void resizeEvent(QResizeEvent *e); void closeEvent(QCloseEvent *); public slots: private: QVBoxLayout* layout; QToolBar* toolbar; QTextBrowser* docs; }; #endif EditSyntaxHighlighter.cpp0000664000175000017500000003174011675357462014204 0ustar jimjim/** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. **/ #include #include "EditSyntaxHighlighter.h" EditSyntaxHighlighter::EditSyntaxHighlighter(QTextDocument *parent) : QSyntaxHighlighter(parent) { initKeywords(); initColors(); initFunctions(); initComments(); initQuotes(); } void EditSyntaxHighlighter::highlightBlock(const QString &text) { HighlightRule rule; VecHighlightRules::iterator sIt = m_standardRules.begin(); VecHighlightRules::iterator sItEnd = m_standardRules.end(); while (sIt != sItEnd) { rule = (*sIt); QRegExp expression(rule.pattern); int index = text.indexOf(expression); while (index >= 0) { int length = expression.matchedLength(); setFormat(index, length, rule.format); index = text.indexOf(expression, index + length); } ++sIt; } // Now do the functions, checking for calls to any matches. VecHighlightRules::iterator fIt = m_functionRules.begin(); VecHighlightRules::iterator fItEnd = m_functionRules.end(); while (fIt != fItEnd) { rule = (*fIt); QRegExp expression(rule.pattern); int index = text.indexOf(expression); while (index >= 0) { int length = expression.matchedLength(); setFormat(index, length, rule.format); index = text.indexOf(expression, index + length); } ++fIt; } } void EditSyntaxHighlighter::initKeywords() { HighlightRule rule; m_keywordFmt.setForeground(Qt::darkBlue); m_keywordFmt.setFontWeight(QFont::Bold); QStringList keywordPatterns; keywordPatterns << "\\b[Aa][Bb][Ss]\\b" // abs << "\\b[Aa][Cc][Oo][Ss]\\b" // acos << "\\b[Aa][Nn][Dd]\\b" // and << "\\b[Aa][Ss][Cc]\\b" // asc << "\\b[Aa][Ss][Ii][Nn]\\b" // asin << "\\b[Aa][Tt][Aa][Nn]\\b" // atan << "\\b[Cc][Ee][Ii][Ll]\\b" // ceil << "\\b[Cc][Hh][Aa][Nn][Gg][Ee][Dd][Ii][Rr]\\b" // changedir << "\\b[Cc][Hh][Rr]\\b" // chr << "\\b[Cc][Ii][Rr][Cc][Ll][Ee]\\b" // circle << "\\b[Cc][Ll][Ii][Cc][Kk][Bb]\\b" // clickb << "\\b[Cc][Ll][Ii][Cc][Kk][Cc][Ll][Ee][Aa][Rr]\\b" // clickclear << "\\b[Cc][Ll][Ii][Cc][Kk][Xx]\\b" // clickx << "\\b[Cc][Ll][Ii][Cc][Kk][Yy]\\b" // clicky << "\\b[Cc][Ll][Gg]\\b" // clg << "\\b[Cc][Ll][Oo][Ss][Ee]\\b" // close << "\\b[Cc][Ll][Ss]\\b" // cls << "\\b[Cc][Oo][Ll][Oo][Rr]\\b" // color << "\\b[Cc][Oo][Ll][Oo][Uu][Rr]\\b" // colour << "\\b[Cc][Oo][Ss]\\b" // cos << "\\b[Cc][Oo][Uu][Nn][Tt]\\b" // count << "\\b[Cc][Oo][Uu][Nn][Tt][Xx]\\b" // countx << "\\b[Cc][Uu][Rr][Rr][Ee][Nn][Tt][Dd][Ii][Rr]\\b" // currentdir << "\\b[Dd][Aa][Yy]\\b" // day << "\\b[Dd][Bb][Cc][Ll][Oo][Ss][Ee]\\b" // dbclose << "\\b[Dd][Bb][Cc][Ll][Oo][Ss][Ee][Ss][Ee][Tt]\\b" // dbcloseset << "\\b[Dd][Bb][Ee][Xx][Ee][Cc][Uu][Tt][Ee]\\b" // dbexecute << "\\b[Dd][Bb][Ff][Ll][Oo][Aa][Tt]\\b" // dbfloat << "\\b[Dd][Bb][Ii][Nn][Tt]\\b" // dbint << "\\b[Dd][Bb][Oo][Pp][Ee][Nn]\\b" // dbopen << "\\b[Dd][Bb][Oo][Pp][Ee][Nn][Ss][Ee][Tt]\\b" // dbopenset << "\\b[Dd][Bb][Rr][Oo][Ww]\\b" // dbrow << "\\b[Dd][Bb][Ss][Tt][Rr][Ii][Nn][Gg]\\b" // dbstring << "\\b[Dd][Ee][Cc][Ii][Mm][Aa][Ll]\\b" // decimal << "\\b[Dd][Ee][Gg][Rr][Ee][Ee][Ss]\\b" // degrees << "\\b[Dd][Ii][Mm]\\b" // dim << "\\b[Dd][Ii][Rr]\\b" // dir << "\\b[Dd][Oo]\\b" // do << "\\b[Ee][Dd][Ii][Tt][Vv][Ii][Ss][Ii][Bb][Ll][Ee]\\b" // editvisible << "\\b[Ee][Ll][Ss][Ee]\\b" // else << "\\b[Ee][Nn][Dd]\\b" // end << "\\b[Ee][Nn][Dd][Ii][Ff]\\b" // endif << "\\b[Ee][Nn][Dd][Ww][Hh][Ii][Ll][Ee]\\b" // endwhile << "\\b[Ee][Oo][Ff]\\b" // eof << "\\b[Ee][Xx][Ii][Ss][Tt][Ss]\\b" // exists << "\\b[Ee][Xx][Pp]\\b" // exp << "\\b[Ee][Xx][Pp][Ll][Oo][Dd][Ee]\\b" // explode << "\\b[Ee][Xx][Pp][Ll][Oo][Dd][Ee][Xx]\\b" // explodex << "\\b[Ff][Aa][Ss][Tt][Gg][Rr][Aa][Pp][Hh][Ii][Cc][Ss]\\b" // fastgraphics << "\\b[Ff][Ll][Oo][Oo][Rr]\\b" // floor << "\\b[Ff][Oo][Nn][Tt]\\b" // font << "\\b[Ff][Oo][Rr]\\b" // for << "\\b[Gg][Ee][Tt][Cc][Oo][Ll][Oo][Rr]\\b" // getcolor << "\\b[Gg][Ee][Tt][Ss][Ee][Tt][Tt][Ii][Nn][Gg]\\b" // getsetting << "\\b[Gg][Ee][Tt][Ss][Ll][Ii][Cc][Ee]\\b" // getslice << "\\b[Gg][Oo][Ss][Uu][Bb]\\b" // gosub << "\\b[Gg][Oo][Tt][Oo]\\b" // goto << "\\b[Gg][Rr][Aa][Pp][Hh][Hh][Ee][Ii][Gg][Hh][Tt]\\b" // graphheignt << "\\b[Gg][Rr][Aa][Pp][Hh][Ss][Ii][Zz][Ee]\\b" // graphsize << "\\b[Gg][Rr][Aa][Pp][Hh][Vv][Ii][Ss][Ii][Bb][Ll][Ee]\\b" // graphvisible << "\\b[Gg][Rr][Aa][Pp][Hh][Ww][Ii][Dd][Tt][Hh]\\b" // graphwidth << "\\b[Hh][Oo][Uu][Rr]\\b" // hour << "\\b[Ii][Ff]\\b" // if << "\\b[Ii][Mm][Gg][Ll][Oo][Aa][Dd]\\b" // imgload << "\\b[Ii][Mm][Gg][Ss][Aa][Vv][Ee]\\b" // imgsave << "\\b[Ii][Mm][Pp][Ll][Oo][Dd][Ee]\\b" // implode << "\\b[Ii][Nn][Pp][Uu][Tt]\\b" // input << "\\b[Ii][Nn][Ss][Tt][Rr]\\b" // instr << "\\b[Ii][Nn][Ss][Tt][Rr][Xx]\\b" // instrx << "\\b[Ii][Nn][Tt]\\b" // int << "\\b[Kk][Ee][Yy]\\b" // key << "\\b[Kk][Ii][Ll][Ll]\\b" // kill << "\\b[Ll][Aa][Ss][Tt][Ee][Rr][Rr][Oo][Rr]\\b" // lasterror << "\\b[Ll][Aa][Ss][Tt][Ee][Rr][Rr][Oo][Rr][Ee][Xx][Tt][Rr][Aa]\\b" // lasterrorextra << "\\b[Ll][Aa][Ss][Tt][Ee][Rr][Rr][Oo][Rr][Ll][Ii][Nn][Ee]\\b" // lasterrorline << "\\b[Ll][Aa][Ss][Tt][Ee][Rr][Rr][Oo][Rr][Mm][Ee][Ss][Ss][Aa][Gg][Ee]\\b"// lasterrormessage << "\\b[Ll][Ee][Ff][Tt]\\b" // left << "\\b[Ll][Ee][Nn][Gg][Tt][Hh]\\b" // length << "\\b[Ll][Ii][Nn][Ee]\\b" // line << "\\b[Ll][Oo][Gg]\\b" // log << "\\b[Ll][Oo][Gg][1][0]\\b" // log10 << "\\b[Ll][Oo][Ww][Ee][Rr]\\b" // lower << "\\b[Mm][Dd][5]\\b" // md5 << "\\b[Mm][Ii][Dd]\\b" // mid << "\\b[Mm][Ii][Nn][Uu][Tt][Ee]\\b" // minute << "\\b[Mm][Oo][Nn][Tt][Hh]\\b" // month << "\\b[Mm][Oo][Uu][Ss][Ee][Bb]\\b" // mouseb << "\\b[Mm][Oo][Uu][Ss][Ee][Xx]\\b" // mousex << "\\b[Mm][Oo][Uu][Ss][Ee][Yy]\\b" // mousey << "\\b[Mm][Ss][Ee][Cc]\\b" // msec << "\\b[Nn][Ee][Tt][Aa][Dd][Dd][Rr][Ee][Ss][Ss]\\b" // netaddress << "\\b[Nn][Ee][Tt][Cc][Ll][Oo][Ss][Ee]\\b" // netclose << "\\b[Nn][Ee][Tt][Cc][Oo][Nn][Nn][Ee][Cc][Tt]\\b" // netconnect << "\\b[Nn][Ee][Tt][Dd][Aa][Tt][Aa]\\b" // netdata << "\\b[Nn][Ee][Tt][Ll][Ii][Ss][Tt][Ee][Nn]\\b" // netlisten << "\\b[Nn][Ee][Tt][Rr][Ee][Aa][Dd]\\b" // netread << "\\b[Nn][Ee][Tt][Ww][Rr][Ii][Tt][Ee]\\b" // netwrite << "\\b[Nn][Ee][Xx][Tt]\\b" // next << "\\b[Nn][Oo][Tt]\\b" // not << "\\b[Oo][Ff][Ff][Ee][Rr][Rr][Oo][Rr]\\b" // offerror << "\\b[Oo][Nn][Ee][Rr][Rr][Oo][Rr]\\b" // onerror << "\\b[Oo][Pp][Ee][Nn]\\b" // open << "\\b[Oo][Rr]\\b" // or << "\\b[Oo][Ss][Tt][Yy][Pp][Ee]\\b" // ostype << "\\b[Oo][Uu][Tt][Pp][Uu][Tt][Vv][Ii][Ss][Ii][Bb][Ll][Ee]\\b" // outputvisible << "\\b[Pp][Aa][Uu][Ss][Ee]\\b" // pause << "\\b[Pp][Ii]\\b" // pi << "\\b[Pp][Ii][Xx][Ee][Ll]\\b" // pixel << "\\b[Pp][Ll][Oo][Tt]\\b" // plot << "\\b[Pp][Oo][Ll][Yy]\\b" // poly << "\\b[Pp][Oo][Rr][Tt][Ii][Nn]\\b" // portin << "\\b[Pp][Oo][Rr][Tt][Oo][Uu][Tt]\\b" // portout << "\\b[Pp][Rr][Ii][Nn][Tt]\\b" // print << "\\b[Pp][Uu][Tt][Ss][Ll][Ii][Cc][Ee]\\b" // putslice << "\\b[Rr][Aa][Dd][Ii][Aa][Nn][Ss]\\b" // radians << "\\b[Rr][Aa][Nn][Dd]\\b" // rand << "\\b[Rr][Ee][Aa][Dd]\\b" // read << "\\b[Rr][Ee][Aa][Dd][Ll][Ii][Nn][Ee]\\b" // readline << "\\b[Rr][Ee][Cc][Tt]\\b" // rect << "\\b[Rr][Ee][Dd][Ii][Mm]\b" // redim << "\\b[Rr][Ee][Ff][Rr][Ee][Ss][Hh]\\b" // refresh << "\\b[Rr][Ee][Pp][Ll][Aa][Cc][Ee]\\b" // replace << "\\b[Rr][Ee][Pp][Ll][Aa][Cc][Ee][Xx]\\b" // replacex << "\\b[Rr][Ee][Ss][Ee][Tt]\\b" // reset << "\\b[Rr][Ee][Tt][Uu][Rr][Nn]\\b" // return << "\\b[Rr][Gg][Bb]\\b" // rgb << "\\b[Rr][Ii][Gg][Hh][Tt]\\b" // right << "\\b[Ss][Aa][Yy]\\b" // say << "\\b[Ss][Ee][Cc][Oo][Nn][Dd]\\b" // second << "\\b[Ss][Ee][Ee][Kk]\\b" // seek << "\\b[Ss][Ee][Tt][Ss][Ee][Tt][Tt][Ii][Nn][Gg]\\b" // setsetting << "\\b[Ss][Ii][Nn]\\b" // sin << "\\b[Ss][Ii][Zz][Ee]\\b" // size << "\\b[Ss][Oo][Uu][Nn][Dd]\\b" // sound << "\\b[Ss][Pp][Rr][Ii][Tt][Ee][Cc][Oo][Ll][Ll][Ii][Dd][Ee]\\b" // spritedcollide << "\\b[Ss][Pp][Rr][Ii][Tt][Ee][Dd][Ii][Mm]\\b" // spritedim << "\\b[Ss][Pp][Rr][Ii][Tt][Ee][Hh]\\b" // spriteh << "\\b[Ss][Pp][Rr][Ii][Tt][Ee][Hh][Ii][Dd][Ee]\\b" // spritehide << "\\b[Ss][Pp][Rr][Ii][Tt][Ee][Ll][Oo][Aa][Dd]\\b" // spriteload << "\\b[Ss][Pp][Rr][Ii][Tt][Ee][Mm][Oo][Vv][Ee]\\b" // spritemove << "\\b[Ss][Pp][Rr][Ii][Tt][Ee][Pp][Ll][Aa][Cc][Ee]\\b" // spriteplace << "\\b[Ss][Pp][Rr][Ii][Tt][Ee][Ss][Hh][Oo][Ww]\\b" // spriteshow << "\\b[Ss][Pp][Rr][Ii][Tt][Ee][Ss][Ll][Ii][Cc][Ee]\\b" // spriteslice << "\\b[Ss][Pp][Rr][Ii][Tt][Ee][Vv]\\b" // spritev << "\\b[Ss][Pp][Rr][Ii][Tt][Ee][Ww]\\b" // spritew << "\\b[Ss][Pp][Rr][Ii][Tt][Ee][Xx]\\b" // spritex << "\\b[Ss][Pp][Rr][Ii][Tt][Ee][Yy]\\b" // spritey << "\\b[Ss][Qq][Rr]\\b" // sqr << "\\b[Ss][Qq][Rr][Tt]\\b" // sqrt << "\\b[Ss][Tt][Aa][Mm][Pp]\\b" // stamp << "\\b[Ss][Tt][Ee][Pp]\\b" // step << "\\b[Ss][Yy][Ss][Tt][Ee][Mm]\\b" // system << "\\b[Tt][Aa][Nn]\\b" // tan << "\\b[Tt][Ee][Xx][Tt]\\b" // text << "\\b[Tt][Hh][Ee][Nn]\\b" // then << "\\b[Tt][Oo]\\b" // to << "\\b[Ss][Tt][Rr][Ii][Nn][Gg]\\b" // tostring << "\\b[Uu][Nn][Tt][Ii][Ll]\\b" // until << "\\b[Uu][Pp][Pp][Ee][Rr]\\b" // upper << "\\b[Vv][Oo][Ll][Uu][Mm][Ee]\\b" // volume << "\\b[Ww][Aa][Vv][Pp][Ll][Aa][Yy]\\b" // wavplay << "\\b[Ww][Aa][Vv][Ss][Tt][Oo][Pp]\\b" // wavstop << "\\b[Ww][Aa][Vv][Ww][Aa][Ii][Tt]\\b" // wavwait << "\\b[Ww][Hh][Ii][Ll][Ee]\\b" // while << "\\b[Ww][Rr][Ii][Tt][Ee]\\b" // write << "\\b[Ww][Rr][Ii][Tt][Ee][Ll][Ii][Nn][Ee]\\b" // writeline << "\\b[Xx][Oo][Rr]\\b" // xor << "\\b[Yy][Ee][Aa][Rr]\\b" // year ; for (QStringList::iterator it = keywordPatterns.begin(); it != keywordPatterns.end(); ++it) { rule.pattern = QRegExp(*it); rule.format = m_keywordFmt; m_standardRules.append(rule); } } void EditSyntaxHighlighter::initColors() { HighlightRule rule; m_colorFmt.setForeground(Qt::darkCyan); QStringList colorPatterns; colorPatterns << "\\b[Tt][Rr][Uu][Ee]\\b" // true << "\\b[Ff][Aa][Ll][Ss][Ee]\\b" // false << "\\b[Cc][Ll][Ee][Aa][Rr]\\b" // clear << "\\b[Bb][Ll][Aa][Cc][Kk]\\b" // black << "\\b[Ww][Hh][Ii][Tt][Ee]\\b" // white << "\\b([Dd][Aa][Rr][Kk]){0,1}[Rr][Ee][Dd]\\b" // red and darkred << "\\b([Dd][Aa][Rr][Kk]){0,1}[Gg][Rr][Ee][Ee][Nn]\\b" // green and darkgreen << "\\b([Dd][Aa][Rr][Kk]){0,1}[Bb][Ll][Uu][Ee]\\b" // blue and darkblue << "\\b([Dd][Aa][Rr][Kk]){0,1}[Cc][Yy][Aa][Nn]\\b" // cyan and darkcyan << "\\b([Dd][Aa][Rr][Kk]){0,1}[Pp][Uu][Rr][Pp][Ll][Ee]\\b" // purple and darkpurple << "\\b([Dd][Aa][Rr][Kk]){0,1}[Yy][Ee][Ll][Ll][Oo][Ww]\\b" // yellow and darkyellow << "\\b([Dd][Aa][Rr][Kk]){0,1}[Oo][Rr][Aa][Nn][Gg][Ee]\\b" // orange and darkorange << "\\b([Dd][Aa][Rr][Kk]){0,1}[Gg][Rr][AaEe][Yy]\\b" // gray and darkgrey ; for (QStringList::iterator it = colorPatterns.begin(); it != colorPatterns.end(); ++it ) { rule.pattern = QRegExp(*it); rule.format = m_colorFmt; m_standardRules.append(rule); } } void EditSyntaxHighlighter::initQuotes() { HighlightRule rule; m_quoteFmt.setForeground(Qt::darkRed); rule.pattern = QRegExp("\"[^\"]*\""); rule.format = m_quoteFmt; m_standardRules.append(rule); } void EditSyntaxHighlighter::initFunctions() { HighlightRule rule; m_functionFmt.setForeground(Qt::blue); rule.pattern = QRegExp("\\b[A-Za-z0-9]+(?=\\:$)"); rule.format = m_functionFmt; m_functionRules.append(rule); } void EditSyntaxHighlighter::initComments() { HighlightRule rule; m_commentFmt.setForeground(Qt::darkGreen); m_commentFmt.setFontItalic(true); rule.pattern = QRegExp("(([Rr][Ee][Mm][ ].+)|([Rr][Ee][Mm])|#.*)$"); rule.format = m_commentFmt; m_standardRules.append(rule); } EditSyntaxHighlighter.h0000664000175000017500000000324511675357462013650 0ustar jimjim/** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License ** along with this program; if not, write to the Free Software ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. **/ #ifndef __EDITSYNTAXHIGHLIGHTER_H #define __EDITSYNTAXHIGHLIGHTER_H #include //#include #include class QTextDocument; class EditSyntaxHighlighter : public QSyntaxHighlighter { Q_OBJECT public: EditSyntaxHighlighter(QTextDocument *parent = 0); protected: virtual void highlightBlock(const QString &text); private: struct HighlightRule { QRegExp pattern; QTextCharFormat format; }; typedef QVector< HighlightRule > VecHighlightRules; VecHighlightRules m_standardRules; VecHighlightRules m_functionRules; void initKeywords(); void initColors(); void initQuotes(); void initFunctions(); void initComments(); QTextCharFormat m_keywordFmt; QTextCharFormat m_colorFmt; QTextCharFormat m_quoteFmt; QTextCharFormat m_functionFmt; QTextCharFormat m_commentFmt; }; #endif // __EDITSYNTAXHIGHLIGHTER_H ErrorCodes.h0000664000175000017500000001226211675357462011443 0ustar jimjim/** Copyright (C) 2006, Ian Paul Larsen. ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License along ** with this program; if not, write to the Free Software Foundation, Inc., ** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. **/ #ifndef ERROR_NONE #define ERROR_NONE 0 #define ERROR_NOSUCHLABEL 1 #define ERROR_NOSUCHLABEL_MESSAGE "No such label" #define ERROR_FOR1 2 #define ERROR_FOR1_MESSAGE "Illegal FOR -- start number > end number" #define ERROR_FOR2 3 #define ERROR_FOR2_MESSAGE "Illegal FOR -- start number < end number" #define ERROR_NEXTNOFOR 4 #define ERROR_NEXTNOFOR_MESSAGE "Next without FOR" #define ERROR_FILENUMBER 5 #define ERROR_FILENUMBER_MESSAGE "Invalid File Number" #define ERROR_FILEOPEN 6 #define ERROR_FILEOPEN_MESSAGE "Unable to open file" #define ERROR_FILENOTOPEN 7 #define ERROR_FILENOTOPEN_MESSAGE "File not open." #define ERROR_FILEWRITE 8 #define ERROR_FILEWRITE_MESSAGE "Unable to write to file" #define ERROR_FILERESET 9 #define ERROR_FILERESET_MESSAGE "Unable to reset file" #define ERROR_ARRAYSIZELARGE 10 #define ERROR_ARRAYSIZELARGE_MESSAGE "Array dimension too large" #define ERROR_ARRAYSIZESMALL 11 #define ERROR_ARRAYSIZESMALL_MESSAGE "Array dimension too small" #define ERROR_NOSUCHVARIABLE 12 #define ERROR_NOSUCHVARIABLE_MESSAGE "Unknown variable" #define ERROR_NOTARRAY 13 #define ERROR_NOTARRAY_MESSAGE "Not an array variable" #define ERROR_NOTSTRINGARRAY 14 #define ERROR_NOTSTRINGARRAY_MESSAGE "Not a string array variable" #define ERROR_ARRAYINDEX 15 #define ERROR_ARRAYINDEX_MESSAGE "Array index out of bounds" #define ERROR_STRNEGLEN 16 #define ERROR_STRNEGLEN_MESSAGE "Substring length less that zero" #define ERROR_STRSTART 17 #define ERROR_STRSTART_MESSAGE "Starting position less than zero" #define ERROR_STREND 18 #define ERROR_STREND_MESSAGE "String not long enough for given starting character" #define ERROR_NONNUMERIC 19 #define ERROR_NONNUMERIC_MESSAGE "Non-numeric value in numeric expression" #define ERROR_RGB 20 #define ERROR_RGB_MESSAGE "RGB Color values must be in the range of 0 to 255." #define ERROR_PUTBITFORMAT 21 #define ERROR_PUTBITFORMAT_MESSAGE "String input to putbit incorrect." #define ERROR_POLYARRAY 22 #define ERROR_POLYARRAY_MESSAGE "Argument not an array for poly()/stamp()" #define ERROR_POLYPOINTS 23 #define ERROR_POLYPOINTS_MESSAGE "Not enough points in array for poly()/stamp()" #define ERROR_IMAGEFILE 24 #define ERROR_IMAGEFILE_MESSAGE "Unable to load image file." #define ERROR_SPRITENUMBER 25 #define ERROR_SPRITENUMBER_MESSAGE "Sprite number out of range." #define ERROR_SPRITENA 26 #define ERROR_SPRITENA_MESSAGE "Sprite has not been assigned." #define ERROR_SPRITESLICE 27 #define ERROR_SPRITESLICE_MESSAGE "Unable to slice image." #define ERROR_FOLDER 28 #define ERROR_FOLDER_MESSAGE "Invalid directory name." #define ERROR_DECIMALMASK 29 #define ERROR_DECIMALMASK_MESSAGE "Decimal mask must be in the range of 0 to 15." #define ERROR_DBOPEN 30 #define ERROR_DBOPEN_MESSAGE "Unable to open SQLITE database." #define ERROR_DBQUERY 31 #define ERROR_DBQUERY_MESSAGE "Database query error (message follows)." #define ERROR_DBNOTOPEN 32 #define ERROR_DBNOTOPEN_MESSAGE "Database must be opened first." #define ERROR_DBCOLNO 33 #define ERROR_DBCOLNO_MESSAGE "Column number out of range." #define ERROR_DBNOTSET 34 #define ERROR_DBNOTSET_MESSAGE "Record set must be opened first." #define ERROR_EXTOPBAD 35 #define ERROR_EXTOPBAD_MESSAGE "Invalid Extended Op-code." #define ERROR_NETSOCK 36 #define ERROR_NETSOCK_MESSAGE "Error opening network socket." #define ERROR_NETHOST 37 #define ERROR_NETHOST_MESSAGE "Error finding network host." #define ERROR_NETCONN 38 #define ERROR_NETCONN_MESSAGE "Unable to connect to network host." #define ERROR_NETREAD 39 #define ERROR_NETREAD_MESSAGE "Unable to read from network connection." #define ERROR_NETNONE 40 #define ERROR_NETNONE_MESSAGE "Network connection has not been opened." #define ERROR_NETWRITE 41 #define ERROR_NETWRITE_MESSAGE "Unable to write to network connection." #define ERROR_NETSOCKOPT 42 #define ERROR_NETSOCKOPT_MESSAGE "Unable to set network socket options." #define ERROR_NETBIND 43 #define ERROR_NETBIND_MESSAGE "Unable to bind network socket." #define ERROR_NETACCEPT 44 #define ERROR_NETACCEPT_MESSAGE "Unable to accept network connection." #define ERROR_NETSOCKNUMBER 45 #define ERROR_NETSOCKNUMBER_MESSAGE "Invalid Socket Number" #define ERROR_PERMISSION 46 #define ERROR_PERMISSION_MESSAGE "You do not have permission to use this statement/function." #define ERROR_IMAGESAVETYPE 47 #define ERROR_IMAGESAVETYPE_MESSAGE "Invalid image save type." // #define ERROR_NOTIMPLEMENTED 9999 #define ERROR_NOTIMPLEMENTED_MESSAGE "Feature not implemented in this environment." #endif Examples/0000775000175000017500000000000011675357447011001 5ustar jimjimExamples/sliceanimation.kbs0000664000175000017500000000200311675357447014474 0ustar jimjim# sliceanimation.kbs # 2010-05-08 j.m.reneau # demonstration program of getslice function # and putslice statements. fastgraphics # capture slice of red foreground and white background clg color red gosub randomdraw refresh slice$ = getslice(100,100,100,100) # draw a screen of yellow and black to # draw slice onto color yellow rect 0,0,300,300 color black gosub randomdraw refresh # initial place and direction x = 0 dx = rand * 3 + 1 y = 0 dy = rand * 3 + 1 while true # get new loction to put slise at x = x + dx if x < 0 or x > 200 then dx = dx * -1 y = y + dy if y < 0 or y > 200 then dy = dy * -1 # get whet is there before putting slice original$ = getslice(x,y,100,100) # draw the slize with white as a transparent color putslice x,y,slice$,black refresh # change it back to what it was before the slice putslice x,y,original$ end while end randomdraw: # crap on the screen for example for t = 1 to 100 line rand * 300, rand * 300, rand * 300, rand * 300 next t return Examples/BASICtest1.kbs0000664000175000017500000000072211675357447013305 0ustar jimjimREM arithmetic operator test if 4 < 5 then print "PASS <" if 5 < 4 then print "FAIL <" if 5 > 4 then print "PASS >" if 4 > 5 then print "FAIL >" if 4 <= 5 then print "PASS <=" if 5 <= 5 then print "PASS <=" if 5 <= 4 then print "FAIL <=" if 4 >= 4 then print "PASS >=" if 5 >= 5 then print "PASS >=" if 4 >= 5 then print "FAIL >=" if 4 = 4 then print "PASS =" if 4 = 5 then print "FAIL =" if 4 <> 5 then print "PASS <>" if 4 <> 4 then print "FAIL <>" Examples/cards_deal5.kbs0000664000175000017500000000536111675357447013655 0ustar jimjim# 2009-12-25 j.m.reneau # create a deck of cards, shuffle them, and display # 5 of them graphically on the screen # requires 0.9.4g # # shapes of the card suits dim diamond(8) diamond = {0, 2.5, 2, 0, 4, 2.5, 2, 5} dim heart(12) heart = {0, 1, 1, 0, 2, 1, 3, 0, 4, 1, 2, 5} dim spade(18) spade = {0, 3, 2, 0, 4, 3, 4, 4, 2, 3, 3, 5, 1, 5, 2, 3, 0, 4} dim club(30) club = {0, 1, 1, 0, 2, 1, 3, 0, 4, 1, 3, 2, 4, 3, 3, 4, 2, 3, 3, 5, 1, 5, 2, 3, 1, 4, 0, 3, 1, 2} # # suits and faces dim suits$(4) suits$ = {"D", "H", "S", "C"} dim cards$(13) cards$ = {"A", "2", "3", "4", "5", "6", "7", "8", "9", "10", "J" ,"Q", "K"} # # array to hold the shuffled deck dim deck$(52) gosub makedeck gosub shuffledeck clg # draw poker table color 139,69,19 rect 0,0,300,300 color darkgreen rect 10,10,280,280 print "click on cards to turn over" # show 5 cards face down for t = 1 to 5 x = 25 + t*40 y = 100 gosub drawcardback next t clickloop: pause .1 # if we have not clicked - go back and wait if clickb = -1 then goto clickloop card1 = -1 # see if the click was on a card for t = 1 to 5 if clickx >= 25 + t*40 and clickx <= 55 + t*40 and clicky >= 100 and clicky <= 150 then card1 = t next t # clear the click clickclear if card1 = -1 then goto clickloop # we clicked on a card - show it card$ = deck$[card1] x = 25 + card1*40 y = 100 gosub drawcard goto clickloop end makedeck: # # makedeck - loop through the suits$ and cards$ arrays # to build 52 card deck$ for suit = 0 to 3 for card = 0 to 12 deck$[suit*13+card] = suits$[suit] + cards$[card] next card next suit return shuffledeck: # # shuffledeck - for many times pick two random # cards from the deck and switch them for t = 1 to 200 card1 = int(rand*52) card2 = int(rand*52) card$ = deck$[card2] deck$[card2] = deck$[card1] deck$[card1] = card$ next t return drawcardback: # # draw a moire pattern for the back of a card gosub drawcardborder color blue for card1 = 3 to 30 step 4 line x+2,y+2,x+card1,y+48 next card1 for card1 = 3 to 50 step 4 line x+2,y+2,x+28,y+card1 next card1 return drawcardborder: # # draw blank card with border color blue rect x,y,30,50 color white rect x+2,y+2,26,46 return drawcard: # # drawcard - draw a 30x50 card at the location x,y # on the screen. also set card$ to be the card # you want to be displayed # # set card color gosub drawcardborder color black if mid(card$,1,1) = "H" or mid(card$,1,1) = "D" then color red # stamp suit on card if mid(card$,1,1) = "H" then stamp x+7, y+26, 4, heart if mid(card$,1,1) = "D" then stamp x+7, y+26, 4, diamond if mid(card$,1,1) = "S" then stamp x+7, y+26, 4, spade if mid(card$,1,1) = "C" then stamp x+7, y+26, 4, club # now show card value font "tahoma",13,100 text x + 4, y + 1, mid(card$,2,2) return Examples/networking/0000775000175000017500000000000011675357445013166 5ustar jimjimExamples/networking/netgetmany.kbs0000664000175000017500000000103711675357445016043 0ustar jimjim# open 5 network connections at once dim a$(5) dim t$(5) a$ = { "www.google.com", "www.yahoo.com", "www.cnn.com", "www.espn.com", "www.basic256.org"} for t = 0 to 4 NETCONNECT t, a$[t], 80 print t + " connected to " + a$[t] next t for t = 0 to 4 NETWRITE t, "GET HTTP/1.1" + chr(13) + chr(10) + chr(13) + chr(10) print t + " request written" next t for t = 0 to 4 t$[t] = NETREAD(t) print t + " read" next t for t = 0 to 4 print t + " " + left(t$[t],40) next t for t = 0 to 4 netclose t print t + " closed" next t Examples/networking/netclient.kbs0000664000175000017500000000034611675357445015657 0ustar jimjim# have the user enter a message and send it to the server input "enter message?", m$ netconnect "127.0.0.1", 9997 for t = 1 to 10 pause rand netwrite t + " " + m$ print netread next t netwrite "end" print netread netcloseExamples/networking/netserver.kbs0000664000175000017500000000040411675357445015702 0ustar jimjim# get a message and send back success print "wait for connection" netlisten 9997 print "got connection" do while not netdata pause .1 print "."; end while n$ = netread print n$ netwrite "I got '" + n$ + "'." until n$ = "end" netcloseExamples/networking/netgoogle.kbs0000664000175000017500000000023011675357445015645 0ustar jimjimNETCONNECT "www.google.com", 80 print "connected" NETWRITE "GET HTTP/1.1" + chr(13) + chr(10) + chr(13) + chr(10) print "written" print NETREAD NETCLOSEExamples/networking/netgethomepage.kbs0000664000175000017500000000115211675357445016662 0ustar jimjim# netgethomepage.kbs - connect to a web site and download # the home page into a variable site$ = "www.yahoo.com" port = 80 NETCONNECT site$, port print "connected to " + site$ + ":" + port get$ = "GET http://" + site$ + "/ HTTP/1.0" + chr(13) + chr(10) get$ = get$ + chr(13) + chr(10) NETWRITE get$ print "request written" s$ = "" do chunk$ = netread print "chunk '" + left(chunk$,10) + "..." + right(chunk$,10) + "'" + length(chunk$) s$ = s$ + chunk$ # wait for more data / may need to adjust for a slower connection pause .2 until not netdata NETCLOSE print "response" print s$ print length(s$) Examples/tictactoe_comp.kbs0000664000175000017500000001313111675357447014476 0ustar jimjim# tictactoe_comp # with a computer player - 2009-12-25 - j.m.reneau # requires BACIC256 0.9.4g or better # -1=empty 0=x, 1=0 fastgraphics dim board(9) board = {-1,-1,-1,-1,-1,-1,-1,-1,-1} gosub drawboard print "tictactoe" dim playertype$(2) for t = 0 to 1 do print "who is player " + (t+1) + " (c-computer, h-human)"; input playertype$[t] until playertype$[t] = "c" or playertype$[t] = "h" next t player = 1 otherplayer = 0 do # swap player and otherplayer t = player player = otherplayer otherplayer = t # play the player if playertype$[player] = "h" then gosub humanplayer if playertype$[player] = "c" then gosub computerplayer # gosub drawboard # see if there is a winner and if not loop for next player gosub iswinner until winner <> -1 # we must have a winner print "The winner was "; if winner = 0 then print "X" if winner = 1 then print "O" if winner = 2 then print "cat" end humanplayer: print "player "; if player = 0 then print "X"; else print "O"; end if print " please click on cell." clickclear while clickb = 0 pause .1 endwhile # what cell did they click on i = int(clickx/100) + int(clicky/100)*3 # if it is not empty then wait again if board[i] <> -1 then goto humanplayer # set cell and display board[i] = player return computerplayer: # go through each square and if it is a win do it # find the best offensive move I can make and save in mybest - we may do it later mybest = -1 mybesttwofer = 0 twoferplayer = player for i = 0 to 8 if board[i] = -1 then board[i] = player gosub iswinner if winner = player then return gosub counttwofer if twofer > mybesttwofer then mybesttwofer = twofer mybest = i endif board[i] = -1 endif next i # # go through each square and if it is a win for the other guy - block it # find the best defensive move I can make and save in hisbest - we may do it later hisbest = -1 hisbesttwofer = 0 twoferplayer = otherplayer for i = 0 to 8 if board[i] = -1 then board[i] = otherplayer gosub iswinner if winner = otherplayer then board[i] = player return endif gosub counttwofer if twofer > hisbesttwofer then hisbesttwofer = twofer hisbest = i endif board[i] = -1 endif next i # # if we can stop a 2 way 2fer stop it if hisbesttwofer >= 2 then board[hisbest] = player return endif # # if we can get a 2 way 2fer do it if mybesttwofer >= 2 then board[mybest] = player return endif # # if we can stop a 1 way 2fer stop it if hisbesttwofer = 1 then board[hisbest] = player return endif # # if we can get a 1 way 2fer do it if mybesttwofer = 1 then board[mybest] = player return endif # # last resort make a random move # - loop until we randomly select an empty cell do i = int(rand * 9) until board[i] = -1 board[i] = player return iswinner: # # is there a winner = return winner - -1 if ther game continues # winner = 0 for X, winner=1 for Y, winner=2 for cat for winner = 0 to 1 # check columns for t = 0 to 2 if board[0+t] = winner and board[3+t] = winner and board[6+t] = winner then return next t # check rows for t = 0 to 2 if board[3*t] = winner and board[3*t+1] = winner and board[3*t+2] = winner then return next t # check diagonals if board[0] = winner and board[4] = winner and board[8] = winner then return if board[2] = winner and board[4] = winner and board[6] = winner then return next winner # check for empty square winner = -1 for t = 0 to 8 if board[t]=-1 then return next t # must be a cat winner = 2 return counttwofer: # # count the number of 2 in a row with a blank for twoferplayer # return as twofers # check columns twofer = 0 for t = 0 to 2 if board[0+t] = twoferplayer and board[3+t] = twoferplayer and board[6+t] = -1 then twofer = twofer + 1 if board[0+t] = twoferplayer and board[3+t] = -1 and board[6+t] = twoferplayer then twofer = twofer + 1 if board[0+t] = -1 and board[3+t] = twoferplayer and board[6+t] = twoferplayer then twofer = twofer + 1 next t # check rows for t = 0 to 2 if board[3*t] = twoferplayer and board[3*t+1] = twoferplayer and board[3*t+2] = -1 then twofer = twofer + 1 if board[3*t] = twoferplayer and board[3*t+1] = -1 and board[3*t+2] = twoferplayer then twofer = twofer + 1 if board[3*t] = -1 and board[3*t+1] = twoferplayer and board[3*t+2] = twoferplayer then twofer = twofer + 1 next t # check diagonals if board[0] = twoferplayer and board[4] = twoferplayer and board[8] = -1 then twofer = twofer + 1 if board[0] = twoferplayer and board[4] = -1 and board[8] = twoferplayer then twofer = twofer + 1 if board[0] = -1 and board[4] = twoferplayer and board[8] = twoferplayer then twofer = twofer + 1 if board[2] = twoferplayer and board[4] = twoferplayer and board[6] = -1 then twofer = twofer + 1 if board[2] = twoferplayer and board[4] = -1 and board[6] = twoferplayer then twofer = twofer + 1 if board[2] = -1 and board[4] = twoferplayer and board[6] = twoferplayer then twofer = twofer + 1 return drawboard: # clg color black rect 0,95,300,10 rect 0,195,300,10 rect 95,0,10,300 rect 195,0,10,300 # font "Tahoma",50,100 # draw X and O for t = 0 to 8 if board[t]=0 then color red : text ((t % 3)*100)+25, (int(t/3)*100)+10, "X" if board[t]=1 then color blue : text ((t % 3)*100)+25, (int(t/3)*100)+10, "O" next t refresh return Examples/story.kbs0000664000175000017500000000263211675357447012665 0ustar jimjim rem Wacky Story input "Name? ", name$ input "Noun? ", noun1$ input "Adverb? ", adverb1$ input "Verb? ", verb1$ input "Noun? ", noun2$ input "Noun? ", noun3$ input "Adjective? ", adj1$ input "Noun? ", noun4$ input "Verb? ", verb4$ input "Adverb? ", adverb2$ input "Noun? ", noun5$ input "Noun? ", noun6$ input "Verb? ", verb3$ input "Noun? ", noun7$ rem *story* print "*********************" print "One dark and stormy night, " + name$; print " and her " + noun1$ + " were fast asleep in their beds. "; print " Suddenly, they heard a crack of " + noun2$; print ", followed quickly by a streak of " + noun3$ + " in the sky." print "" print name$ + " sat up and screamed. She could feel the "; print noun4$ + " running down her neck as she " + adverb1$ + " "; print verb1$ + " around the room. When her gaze landed on her "; print noun1$ + "'s bed, she realized that he wasn't there. " print "" print "She looked at the " + noun5$ + ". It was midnight. She took deep breaths,"; print " waiting for her " + noun1$ + " to return."; print " An hour later, he still wasn't there. " print "" print name$ + " climbed out of "; print noun6$ + "and stood up, her legs "; print adj1$ + ". She walked " + adverb2$; print " out of the room and into the kitchen. And there she found him, eating a "; print noun7$ + ". Outside, the " + noun2$ + " crashed again and Sally "; print verb3$ + " and " + verb4$ + " back to bed." print " " Examples/plot2.kbs0000664000175000017500000000006011675357447012536 0ustar jimjim color yellow for a = 1 to 100 plot a, a next a Examples/sqrt.kbs0000664000175000017500000000111211675357447012466 0ustar jimjim# calculate the square root geometrically (according to Heron) # Carsten Berndt, 2007 clg cls fastgraphics zuWurzeln=56224 zuZeichnen=zuWurzeln zweiteZahl=1 delta=0.000001 print "sqrt("; : print zuWurzeln; : print ") =" ; MainLoop: clg rect 0, 0, zuZeichnen, zweiteZahl zuZeichnen = (zuZeichnen+zweiteZahl)/2 zweiteZahl = zuWurzeln/zuZeichnen if zuZeichnen-zweiteZahl 255) then c = 255 sx = 100+ u * (w + 2) * 35 sy = 100+ v * (w + 2) * 35 font "arial",(w + 2) * 16 ,15 text sx,sy,"+" next z next y next x refresh returnExamples/collision.kbs0000664000175000017500000000557611675357447013512 0ustar jimjim# Collision # 2 "balls" reflect on the walls and can collide # see http://www.geocities.com/vobarian print "The return key ends the program." clg fastgraphics # graphics window size gwidth = 300 gheight = 300 graphsize gwidth,gheight # feel free to change the radius of the balls and their masses # radius r1 = 15 r2 = 15 # masses m1 = r1*r1*r1 m2 = r2*r2*r2 # initial positions and velocities x1 = rand * (gwidth - 2*r1) + r1 : y1 = r1 vx1 = 10*rand - 5 : vy1 = 3*rand x2 = rand * (gwidth - 2*r2) + r2 : y2 = gheight - r2 vx2 = 10*rand - 5 : vy2 = -3*rand #uncomment the following for direct central collision #gwidth = 500 #gheight = 200 #graphsize gwidth,gheight #r1=15 #r2 = r1 #m2 = m1 #x1 = 15 #y1 = floor(gheight/2) #x2 = gwidth - 15 #y2 = y1 #vx1 = 5 #vx2 = -vx1 #vy1 = 0 #vy2 = 0 ################################### kollision = 0 # do we have a collision (1 yes, 0 no) loopz: c = key if c = 16777220 then goto ende clg gosub zeichne refresh gosub iskollision if kollision = 0 then goto m1 gosub getkollision gosub getnewpos m1: gosub wandball1 gosub wandball2 m2: gosub getnewpos goto loopz getnewpos: x1 = x1 + vx1 y1 = y1 + vy1 x2 = x2 + vx2 y2 = y2 + vy2 return iskollision: kollision = 0 if sqr((x1 - x2) * (x1 - x2) + (y1 - y2) * (y1 - y2)) < r1 + r2 then kollision = 1 : sound 400,2 return wandball1: if ( x1 > gwidth - r1 and vx1 > 0 ) or ( x1 < r1 and vx1 < 0 ) then vx1 = -vx1 if ( y1 > gheight - r1 and vy1 > 0 ) or ( y1 < r1 and vy1 < 0 ) then vy1 = -vy1 return wandball2: if ( x2 > gwidth - r2 and vx2 > 0 ) or ( x2 < r2 and vx2 < 0 ) then vx2 = -vx2 if ( y2 > gheight - r2 and vy2 > 0 ) or ( y2 < r2 and vy2 < 0 ) then vy2 = -vy2 return getkollision: #normal vector un = unx, uny sq = sqr((x1-x2)*(x1-x2) + (y1-y2)*(y1-y2)) unx = (x2 - x1) / sq uny = (y2 -y1) / sq #tangential vector ut utx = -uny : uty = unx #tangential velocities vt1, vt2 (skalar) vt1 = utx*vx1 + uty*vy1 vt2 = utx*vx2 + uty*vy2 #normal velocities vn1, vn2 (skalar) vn1 = unx*vx1 + uny*vy1 vn2 = unx*vx2 + uny*vy2 # 1-dimensional collision formulas for the normal # velocities after collision vn1n, vn2n # the tangential component of the velcities does not change vn1n =( (m1-m2)*vn1 + 2*m2*vn2 ) / (m1+m2) vn2n =( (m2-m1)*vn2 + 2*m1*vn1 ) / (m1+m2) # vectors after collision: tangential (vt1n,vt2n) and normal (vt1n,vt2n) vn1nx = unx * vn1n : vn1ny = uny * vn1n vn2nx = unx * vn2n : vn2ny = uny * vn2n vt1nx = utx * vt1 : vt1ny = uty * vt1 vt2nx = utx * vt2 : vt2ny = uty * vt2 # tangential and normal vector add to resulting velocities vx1 = vt1nx + vn1nx : vy1 = vt1ny + vn1ny vx2 = vt2nx + vn2nx : vy2 = vt2ny + vn2ny return zeichne: color black rect 0,0,gwidth,gheight color clear rect 1,1,gwidth-2,gheight-2 color red circle x1,y1,r1 color blue circle x2,y2,r2 return ende: print "Bye!" endExamples/ring_01.kbs0000664000175000017500000000045111675357447012741 0ustar jimjimrem Ring example thanks to Joel Kahn clg fastgraphics rm=0.0 st=0.0251 imx=3.281 imy=3.095 bm=0.2 x=135.0 y=2.0 ring: rm=rm+st x=x+imx*cos(rm) y=y+imy*sin(rm) q=y*bm color clear rect x,y,q,q color black ex=x+q ey=y+q line x,y,ex,y line x,y,x,ey line ex,ey,ex,y line ex,ey,x,ey refresh goto ring Examples/testing/0000775000175000017500000000000011675357446012455 5ustar jimjimExamples/testing/explodetest.kbs0000664000175000017500000000211611675357446015516 0ustar jimjim# explodetest.jbs 2011-01-05 j.m.reneau # for version 0.9.6.56 # explode on spaces a$ = "We all live in a yellow submarine, yellow submarine, yellow, submarine." w$ = explode(a$," ") for t = 0 to w$[?]-1 print "w$["+t+"]=" + w$[t] next t # explode on A or a a$ = "klj;lkjalkjAlkj;al;kjAoiupAoiupouApoiupoiapoiupoaoiupoaoiupoaaaoiuAAAoiu" w$ = explode(a$,"A",true) for t = 0 to w$[?]-1 print "w$["+t+"]=" + w$[t] next t # explode on regex //[,]* // a$ = "We all live in a yellow submarine, yellow submarine, yellow, submarine." w$ = explodex(a$,"[,]* ") for t = 0 to w$[?]-1 print "w$["+t+"]=" + w$[t] next t # explode numbers on comma a$="1,2,3,4,5,6,77,,foo,888,9.987,6.45" n = explode(a$,",") for t = 0 to n[?]-1 print "n["+t+"]=" + n[t] next t # explode numbers with words a$="1 and 2 AND 3 and 5 aND 99 AND 8.88 aNd 6.45" n = explode(a$,"and",true) for t = 0 to n[?]-1 print "n["+t+"]=" + n[t] next t # explode on regex //[Aa][Nn][Dd]// a$="1 and 2 AND 3 and 5 aND 99 AND 8.88 aNd 6.45" n = explodex(a$,"[Aa][Nn][Dd]") for t = 0 to n[?]-1 print "n["+t+"]=" + n[t] next t Examples/testing/foo.txt0000664000175000017500000000022011675357446013773 0ustar jimjimData file line 1. Data file line 2. Data file line 3. Data file line 4. Data file line 5. Data file line 6. Data file line 7. Data file line 8. Examples/testing/input_numeric_test.kbs0000664000175000017500000000146511675357446017104 0ustar jimjim# test numeric input # 2009-11-01 j.m.reneau print "input with prompt to numeric variable" loop: input "input a number (>100 stops) ", a print "You entered " + a if a < 100 then goto loop # print "input with prompt to numeric array" dim b(10) loop2: input "input an index 1--10 ", i if i < 1 or i > 10 then goto loop2 input "input a number (>100 stops) ", b[i] print "You entered " + b[i] if b[i] < 100 then goto loop2 # print "input without prompt to numeric variable" loop3: print "input a number (>100 stops) " input a print "You entered " + a if a < 100 then goto loop3 # print "input without prompt to numeric variable" loop4: input "input an index 1--10 ", i if i < 1 or i > 10 then goto loop4 print "input a number (>100 stops) " input b[i] print "You entered " + b[i] if b[i] < 100 then goto loop4 # print "done"Examples/testing/README.txt0000664000175000017500000000014511675357446014153 0ustar jimjimThis folder contains programs used to test various modifications during development and refinement. Examples/testing/testimagesave.kbs0000664000175000017500000000057611675357446016027 0ustar jimjimfor t = 0 to 100 color rand()*256, rand()* 256, rand()*256 rect rand()*graphwidth, rand()*graphheight,rand()*graphwidth, rand()*graphheight next t imgsave "testimgsave1.png" imgsave "testimgsave2.png", "png" imgsave "testimgsave3.jpg", "jpg" imgsave("testimgsave4.png") imgsave("testimgsave5.png", "png") imgsave("testimgsave6.jpg", "jpg") imgsave("testimgsave7.gif", "gif") Examples/testing/testlineio.kbs0000664000175000017500000000046211675357446015337 0ustar jimjim# testlineio.kbs - test readline, writeline, and eof # 2008-08-29 jmr open "foo.txt" reset for l = 1 to 8 writeline "Data file line " + l + "." next l l = 0 donext: if eof then goto done l = l + 1 a$ = readline print "line " + l + "=" + a$ goto donext done: print "total of " + l + " lines." close endExamples/testing/testmath.kbs0000664000175000017500000000632511675357446015015 0ustar jimjim# testmath.kbs - used to test math, comparison, and logical computation # tests for accuracy and order of precidence # 2009-12-26 j.m.reneau # countpass = 0 countfail = 0 # print "Assignment" a = 1 : val = 1 : stmt$ = "a = 1" : gosub testnum a$ = "hi" : val$ = "hi" : stmt$ = "a$ = 'hi'" : gosub teststring # print "MDAS" a = 1+2 : val = 3 : stmt$ = "a = 1+2" : gosub testnum a = 2-1 : val = 1 : stmt$ = "a = 2-1" : gosub testnum a = 1*2 : val = 2 : stmt$ = "a = 1*2" : gosub testnum a = 10/2 : val = 5 : stmt$ = "a = 10/2" : gosub testnum a = 1+10/2 : val = 6 : stmt$ = "a = 1+10/2" : gosub testnum a = (2+10)/2 : val = 6 : stmt$ = "a = (2+10)/2" : gosub testnum a = 1-10*2 : val = -19 : stmt$ = "a = 1-10*2" : gosub testnum a = (2-10)*2 : val = -16 : stmt$ = "a = (2-10)*2" : gosub testnum a = 1-2+3 : val = 2 : stmt$ = "a = 1-2+3" : gosub testnum # print "Simple Compare Integer" a = 1=1 : val = true : stmt$ = "a = 1=1" : gosub testnum a = 1=2 : val = false : stmt$ = "a = 1=2" : gosub testnum a = 1<>2 : val = true : stmt$ = "a = 1<>2" : gosub testnum a = 2<>2 : val = false : stmt$ = "a = 2<>2" : gosub testnum a = 2<3 : val = true : stmt$ = "a = 2<3" : gosub testnum a = 3<2 : val = false : stmt$ = "a = 3<2" : gosub testnum a = 3>2 : val = true : stmt$ = "a = 3>2" : gosub testnum a = 2>3 : val = false : stmt$ = "a = 2>3" : gosub testnum a = 2<=3 : val = true : stmt$ = "a = 2<=3" : gosub testnum a = 2<=2 : val = true : stmt$ = "a = 2<=2" : gosub testnum a = 3<=2 : val = false : stmt$ = "a = 3<=2" : gosub testnum a = 3>=2 : val = true : stmt$ = "a = 3>=2" : gosub testnum a = 3>=3 : val = true : stmt$ = "a = 3>=3" : gosub testnum a = 2>=3 : val = false : stmt$ = "a = 2>=3" : gosub testnum # print "Simple Compare Float" a = 1.1=1.1 : val = true : stmt$ = "a = 1.1=1.1" : gosub testnum a = 1.66=2.77 : val = false : stmt$ = "a = 1.66=2.77" : gosub testnum a = 1.99<>2.01 : val = true : stmt$ = "a = 1.99<>2.01" : gosub testnum a = 2.22<>2.22 : val = false : stmt$ = "a = 2.22<>2.22" : gosub testnum a = 2.9<3.1 : val = true : stmt$ = "a = 2.9<3.1" : gosub testnum a = 3.7<2.9 : val = false : stmt$ = "a = 3.7<2.9" : gosub testnum a = 3.1>2.9 : val = true : stmt$ = "a = 3.1>2.9" : gosub testnum a = 2.77>3.22 : val = false : stmt$ = "a = 2.77>3.22" : gosub testnum a = 2.89<=3.98 : val = true : stmt$ = "a = 2.89<=3.98" : gosub testnum a = 2.5<=2.5 : val = true : stmt$ = "a = 2.5<=2.5" : gosub testnum a = 3.4<=2.4 : val = false : stmt$ = "a = 3.4<=2.4" : gosub testnum a = 3.7>=2.7 : val = true : stmt$ = "a = 3.7>=2.7" : gosub testnum a = 3.88>=3.88 : val = true : stmt$ = "a = 3.88>=3.88" : gosub testnum a = 2.05>=3.05 : val = false : stmt$ = "a = 2.05>=3.05" : gosub testnum # print "Simple Compare String" a = "aa" = "aa" : val = true : stmt$ = "a$ = 'aa' = 'aa'" : gosub testnum a = "aa" <> "zz" : val = true : stmt$ = "a$ = 'aa' <> 'zz'" : gosub testnum print "passed = " + countpass print "failed = " + countfail end testnum: print stmt$ + " == " + val; if a = val then print " pass" countpass = countpass + 1 else print " fail" countfail = countfail + 1 end if return teststring: print stmt$ + " == '" + val$ + "'"; if a$ = val$ then print " pass" countpass = countpass + 1 else print " fail" countfail = countfail + 1 end if return Examples/testing/2dstrarraytest.kbs0000664000175000017500000000117611675357446016160 0ustar jimjim# test numeric 2d string array dim/redim/input/assogn # 20100417 j.m.reneau dim a$(6) a$ = {"A","B","C","D","E","F"} label$ = "array 6 1d" gosub displaya label$ = "array input [5]" print "input a$[5]?"; input a$[5] gosub displaya redim a$(5,2) label$ = "array redim 5,2" gosub displaya label$ = "array switch 0,0 0,1" b$ = a$[0,1] a$[0,1]=a$[0,0] a$[0,0] = b$ gosub displaya label$ = "array input [3,1]" print "input a$[3,1]?" input a$[3,1] gosub displaya end displaya: print print label$ for row = 0 to a$[?,]-1 for col = 0 to a$[,?]-1 print "a$["+row+","+col+"]='"+a$[row,col] + "' "; next col print next row returnExamples/testing/random_one.kbs0000664000175000017500000000067211675357446015304 0ustar jimjim#ransom_one.kbs - test random for extremes (1.00) is very bad # 2008/09/07 jmr badkount = 0 kount9 = 0 kount0 = 0 for t = 1 to 1000000 a = rand if a = 1 then print t + " " + a : badkount = badkount + 1 if int(a*1000000) = 999999 then print t + " " + a : kount9 = kount9 + 1 if int(a*1000000) = 0 then print t + " " + a : kount0 = kount0 + 1 next t print "badkount=" + badkount print "kount9=" + kount9 print "kount0=" + kount0 endExamples/testing/fontdemo.kbs0000664000175000017500000000026311675357446014772 0ustar jimjimclg color black n = 5 dim fonts$(n) fonts$ = {"Helvetica", "Times", "Courier", "System", "Symbol"} for t = 0 to n-1 font fonts$[t], 32, 50 text 10, t*50, fonts$[t] next t Examples/testing/beautifytest.kbs0000664000175000017500000000031411675357446015664 0ustar jimjimfor t = 1 to 100 if t = 0 then print "zero" else print "not zero" end if bar: ## # if t = 0 then print "zero" endif print t next t foo: print "foo block" Examples/testing/tes_oo.kbs0000664000175000017500000000102111675357446014440 0ustar jimjim# test_oo.kbs - order of operations # 2008-09-06 jmr # some samples from # http://en.wikipedia.org/wiki/Order_of_operations # print "(4+10/2)/9 = 1 -- " + ((4+10/2)/9) print "2 ^ (3 ^ 2) = 512 -- " + (2 ^ (3 ^ 2)) print "1+2*3 = 7 -- " + (1+2*3) print "3 * 1 / 2 = 1.5 -- " + (3 * 1 / 2) print "3 * 1 % 2 = 1 -- " + (3 * 1 % 2) print "1 / 2 * 3 = 1.5 -- " + (1 / 2 * 3) print "1 % 2 * 3 = 3 -- " + (1 % 2 * 3) print "3 % 2 * 5 = 5 -- " + (3 % 2 * 5) print "3 + 1 % 2 = 4 -- " + (3 + 1 % 2) print "3 % 2 + 5 = 6 -- " + (3 % 2 + 5)Examples/testing/instrtest.kbs0000664000175000017500000000143011675357446015213 0ustar jimjim# instrtest.kbs 2011-01-05 j.m.reneau # for 0.9.6.56 and later a$ = "Now is the time for all good men to come to the Aid of Their party." print "location of men = " + instr(a$,"men") print "location of aid = " + instr(a$,"aid") print "location of aid (ignore case) = " + instr(a$,"aid",1,true) # print "locations of all spaces" l = instr(a$," ") while l <> 0 print l + " "; l = instr(a$," ",l+1) end while print # print "print words" oldl = 1 l = instr(a$," ") k = 0 while l <> 0 k = k + 1 print k + " '" + mid(a$,oldl, l-oldl) + "'" oldl = l + 1 l = instr(a$," ",l+1) end while k = k + 1 print k + " '" + mid(a$,oldl, 99999) + "'" # print "location of regex [Aa]id = " + instrx(a$,"[Aa]id") print "location of regex [Hh][Ee] starting at 50 = " + instrx(a$,"[Hh][Ee]",50) Examples/testing/arraylistassign.kbs0000664000175000017500000000053711675357446016402 0ustar jimjim# array list assign # allow assigning an array to redim or initially dim an array # 2011-01-03 j.m.reneau 0.9.6.55 a = {1,2,3,4} print a[a[?]-1] a = {1,2,3,4,5,6,7,8} print a[a[?]-1] a = {1,2,3} print a[a[?]-1] a = 10 print a b$ = {"a","b","c"} print b$[b$[?]-1] b$ = {"a","b","c","d","e","f"} print b$[b$[?]-1] b$ = {"a","b","c"} print b$[b$[?]-1] Examples/testing/test_while_loops.kbs0000664000175000017500000000025311675357446016541 0ustar jimjim#test_while_loops.kbs t = 0 print "before while" while t < 10 u = 0 while u < 10 print t*10 + u + " " ; u = u + 1 endwhile t = t + 1 endwhile print "done"Examples/testing/2darraytest.kbs0000664000175000017500000000113011675357446015415 0ustar jimjim# test numeric 2d array dim/redim/input/assogn # 20100417 j.m.reneau dim a(6) a = {1,2,3,4,5,6} label$ = "array 6 1d" gosub displaya label$ = "array input [5]" print "input a[5]?"; input a[5] gosub displaya redim a(5,2) label$ = "array redim 5,2" gosub displaya label$ = "array switch 0,0 0,1" b = a[0,1] a[0,1]=a[0,0] a[0,0] = b gosub displaya label$ = "array input [3,1]" print "input a[3,1]?" input a[3,1] gosub displaya end displaya: print print label$ for row = 0 to a[?,]-1 for col = 0 to a[,?]-1 print "a["+row+","+col+"]="+a[row,col] + " "; next col print next row returnExamples/testing/uaarray.kbs0000664000175000017500000000077011675357446014626 0ustar jimjim# uaarray.kbs - code that caused access violation errors # fixed 2008-08-29 jmr # example one - list assigning a non exist variable # both with float and string a = {1, 2, 3, 4} b$ = {"foo", "bar", "foobar"} # example 2 - list assigning a non array variable g = 99 g = {1, 2, 3, 4} # h$ = "hi mom" h$ = {"foo", "bar", "foobar"} # sample 3 - index assignment with non exist variable c[88] = 9 d$[22] = "foo" # sample 4 - index assign of a non array variable e = 7 e[3] = 9 # f$ = "bar" f$[7] = "crap"Examples/testing/counttest.kbs0000664000175000017500000000062311675357446015207 0ustar jimjim# counttest.jbs 2011-01-05 j.m.reneau # for version 0.9.6.56 a$ = "We all live in a yellow submarine, yellow submarine, yellow, submarine." print a$ print "count of w = " + count(a$,"w") print "count of W = " + count(a$,"W") print "count of YeLlOw (ignore case) = " + count(a$,"YeLlOw",true) print "count of W (ignore case) = " + count(a$,"W",true) print "count of regex [Ww] = " + countx(a$,"[Ww]") Examples/testing/replacetest.kbs0000664000175000017500000000067511675357446015501 0ustar jimjim# replacetest.jbs 2011-01-05 j.m.reneau # for version 0.9.6.56 a$ = "We all live in a yellow submarine, yellow submarine, yellow, submarine." print a$ print "Change yellow to blue." print Replace(a$,"yellow","blue") print "Change we to Aliens." print Replace(a$,"we","Aliens") print "Change we (case insensitive) to Beatles." print Replace(a$, "we", "Beatles", true) print "Change regex y.*, to regular." print Replacex(a$, "y.*,", "regular") Examples/testing/testtextfont.kbs0000664000175000017500000000032611675357446015732 0ustar jimjimclg for t = 1 to 100 font "tahoma", int(rand*100), int(rand*100) color int(rand*255), int(rand*255), int(rand*255) text(int(rand*300),int(rand*300),"foo") text(int(rand*300),int(rand*300),"bar") next t # #Examples/testing/test_multiline_if.kbs0000664000175000017500000000034011675357446016672 0ustar jimjimi = 1 j = 1 if i = 1 then print "i is one" if j = 1 then print "j is one" print "j is really one" endif print "i really one" else print "i is not one" print "i is really not one" endif print i + " " + jExamples/testing/input_string_test.kbs0000664000175000017500000000145511675357446016747 0ustar jimjim# test string input # 2009-11-01 j.m.reneau print "test input with string and prompt" loop: input "input a string ('stop' stops) ", a$ print "You entered " + a$ if a$ <> "stop" then goto loop # print "test input with string and array" dim b$(10) loop2: input "input an index 1--10 ", i input "input a string ('stop' stops) ", b$[i] print "You entered " + b$[i] if b$[i] <> "stop" then goto loop2 # print "test input with string and whthout prompt" loop3: print "input a string ('stop' stops) " input a$ print "You entered " + a$ if a$ <> "stop" then goto loop3 # print "test input with string and array" loop4: print "input an index 1--10 " input i if i < 1 or i > 10 then goto loop4 print "input a string ('stop' stops) " input b$[i] print "You entered " + b$[i] if b$[i] <> "stop" then goto loop4 # print "done"Examples/testing/KalRGB.kbs0000664000175000017500000000117511675357446014224 0ustar jimjim rem Kalidescope cls print "Press Q to stop." clg screenx = 300 screeny = 300 maxsize = 100 fastgraphics draw: x = int(rand * screenx) y = int(rand * screeny) z = int(rand * maxsize) # size of box to draw on screen colornumber = int(rand * 18) gosub SETCOLOR rect x, y, z, z rect screenx - x - z, y, z, z # draw mirror reflection on x axis rect x, screeny - y - z, z, z # draw mirror reflection on y axis rect screenx - x - z, screeny - y - z, z, z # draw mirror reflestion on both refresh if key = asc("Q") then end # if user presses q then end goto draw end SETCOLOR: color int(rand*256), int(rand*256), int(rand*256) return Examples/testing/test_logicalops.kbs0000664000175000017500000000141311675357446016350 0ustar jimjim# test_logicalops.kbs # test program to check the logical operations print "test integers" print 1 = 1; print 0 < 1; print 1 > 0; print 0 <= 1; print 1 >= 0; print 1 <= 1; print 1 >= 1; print 1 <> 0; print # print "test integers and floats" print 1 = 1.0; print 0 < 1.1; print 1 > 0.1; print 0 <= 1.1; print 1 >= 0.1; print 1 <= 1.1; print 1 >= .9; print 1 <> 0.1; print # print "test floats and integers" print 1.0 = 1; print 0.1 < 1; print 1.1 > 0; print 0.1 <= 1; print 1.1 >= 0; print 0.9 <= 1; print 1.1 >= 1; print 1.1 <> 0; print # print "test strings" print "apple" = "apple"; print "apple" < "applex"; print "applex" > "apple"; print "apple" <= "applex"; print "applex" >= "apple"; print "apple" <= "apple"; print "apple" >= "apple"; print "apple" <> "applex"; print # Examples/testing/testmodulo.kbs0000664000175000017500000000035411675357446015357 0ustar jimjim# testmodulo.kbs - modulo calculation # 2008-08-29 jmr print "6 % 4 = 2 -> " + 6 % 4 print "10 % 3 = 1 -> " + 10 % 3 print "1024 % 3 = 1 -> " + 1024 % 3 # mod casts floats to int to do it anyway print "55.7777 % 4 = 3 -> " + 55.7777 % 4Examples/testing/test_slice.kbs0000664000175000017500000000164311675357446015320 0ustar jimjim# test_slice.kbs # 2010-05-08 j.m.reneau # test functionality of getslice and putslice color black rect 0,0,300,300 for x = 10 to 300 step 10 for y = 0 to 300 step 10 color rgb(rand*256, rand*256, rand*256) rect x,y,10,10 next y next x k$ = getslice(0,0,25,25) print length(k$) print k$ l$ = getslice(50,50,100,75) print length(l$) w$ = getslice(0, 0, graphwidth, graphheight) print length(w$) print "test with no transparent color" input "press return", a$ color green rect 0,0,300,300 putslice 50,50,l$ for t = 1 to 100 putslice rand*280, rand*280,k$ next t pause .5 rect 0,0,100,100 print "now test with a black transparent color" input "press return", a$ color red rect 0,0,300,300 putslice 50,50,l$, black for t = 1 to 100 putslice rand*280, rand*280,k$,black next t pause .5 rect 0,0,100,100 print "now restore screen" input "press return", a$ rect 0,0,300,300 putslice 0, 0, w$ print "end"Examples/testing/testchr.kbs0000664000175000017500000000055011675357446014632 0ustar jimjim# testchr.kbs - test readline, writeline, and eof # 2008-08-29 jmr for t = asc("a") to asc("z") print chr(t); next t print for t = asc("A") to asc("Z") print chr(asc(chr(t))); next t print print "press any key" loop: a = key if a = 0 then goto loop print "You Pressed " + chr(a) + " with value of " + string(a) + " = " + string(asc(chr(a))) goto loopExamples/testing/testtime.kbs0000664000175000017500000000013611675357446015014 0ustar jimjimtop: print year + "-" + month + "-" + day + " " + hour + ":" + minute + ":" + second goto top Examples/testing/test_dountil.kbs0000664000175000017500000000016311675357446015673 0ustar jimjimprint "click the center mouse button to stop" clickclear do print clickb pause .1 until clickb = 4 print "stop"Examples/paddle.kbs0000664000175000017500000000056411675357447012740 0ustar jimjimprint "Use the J and K keys to move the paddle" fastgraphics x = 30 y = 280 xinc = 5 loop1: a = key if a = 75 then x = x + 30 if a = 74 then x = x - 30 if x < 0 then x = 0 if x > 200 then x = 200 gosub drawpaddle goto loop1 drawpaddle: color gray rect 0,0,300,300 color darkblue rect x,y,100,10 color blue rect x+1,y+1,98,8 refresh returnExamples/poly.kbs0000664000175000017500000000011411675357447012461 0ustar jimjimdim a(6) a[0] = 10 a[1] = 10 a[2] = 20 a[3] = 20 a[4] = 15 a[5] = 10 poly a Examples/db_quote.kbs0000664000175000017500000000034111675357447013302 0ustar jimjimdbfile$ = "db_quote.sqlite3" e = exist(dbfile$) dbopen dbfile$ if not e then # create table and a few entries if file does not exist dbexecute "create table quote (id integer primary key, saying text, author text);" end Examples/checkerboard.kbs0000664000175000017500000000031711675357447014117 0ustar jimjim color clear rect 0,0,400,400 color black for h = 10 to 150 step 40 for i = 10 to 150 step 40 rect i,h,19,19 next i next h for h = 30 to 150 step 40 for i = 30 to 150 step 40 rect i,h,19,19 next i next h Examples/ballaccel.kbs0000664000175000017500000000135111675357447013404 0ustar jimjimprint "Using Newton's laws to make the ball bounce realistically" rem set up initial ball position and speed x = 20 y = 100 r = 10 yvel = -1.0 xvel = 1.10 yacc = .0098 fastgraphics loop1: clg rem change the downward velocity according to the acceleration yvel = yvel + yacc rem calculate new position y = y + yvel x = x + xvel rem check for collisions if y > 289 then yvel = -0.9 * yvel : y = 289 : xvel = xvel * 0.9 if x > 285 then xvel = -xvel : x = 285 if x < 10 then xvel = -xvel : x = 10 rem draw the ball color darkblue rect 0,0,300,300 gosub drawBall if xvel * xvel < 0.0001 then end goto loop1 drawBall: color darkgray circle x, y, r color gray circle x, y, r - 2 refresh return Examples/arrays.kbs0000664000175000017500000000047511675357447013011 0ustar jimjimrem Array example dim myarray(10) myarray = {1,2,3,4,5,6,7,8,9,10} myarray[0] = 42 myarray[3] = 42 myarray[5] = 42 for i = 0 to 9 print "Myarray at index "; print i; print " = "; print myarray[i] next i dim i$(10) i$ = {"Welcome", " ", "to", "Basic-256!"} print i$[0] + i$[1] + i$[2] + i$[1] + i$[3]Examples/hangman.kbs0000664000175000017500000000077711675357447013126 0ustar jimjimclg gosub gallows gosub head gosub body gosub armr gosub arml gosub legr gosub legl gosub rip end gallows: color darkorange rect 0,250,200,50 rect 50,0,25,250 rect 75,0,75,25 return head: color blue circle 150,50,25 return body: color green rect 137,75,25,75 return armr: color red rect 162,100,50,25 return arml: color red rect 87,100,50,25 return legr: color yellow rect 112,150,25,50 return legl: color yellow rect 162,150,25,50 return rip: color black font "Tahoma",24,100 text 100,100,"RIP" returnExamples/dice/0000775000175000017500000000000011675357447011705 5ustar jimjimExamples/dice/dice.kbs0000664000175000017500000000271111675357447013313 0ustar jimjim# dice.kbs - graphical dice 2009-10-31 j.m.reneau # doll dice and make a rolling noise while we do it. clg cls # draw initial screen color black rect 1,1,graphwidth,graphheight # Sound file from freesound.org # contributed by Freegle - Sample 44061 wavplay "dicewood.wav" for t = 1 to 6 gosub roll pause rand * .2 next t print "You Rolled " + total pause 1 # let the sound finish end roll: color white for die = 1 to 2 # set x and y to the top corner of the die gosub setdie rect x,y,100,100 next die total = 0 for die = 1 to 2 # set x and y to the top corner of the die gosub setdie roll = int(rand * 6) + 1 total = total + roll if roll = 1 then gosub drawone if roll = 2 then gosub drawtwo if roll = 3 then gosub drawthree if roll = 4 then gosub drawfour if roll = 5 then gosub drawfive if roll = 6 then gosub drawsix next die refresh return setdie: x = 40 y = 40 if die = 2 then x = 160 if die = 2 then y = 160 if die = 3 then x = 40 if die = 2 then y = 160 if die = 2 then x = 160 if die = 4 then y = 40 return drawone: color red rect x + 40, y + 40, 20, 20 return drawtwo: color black rect x + 10, y + 10, 20, 20 rect x + 70, y + 70, 20, 20 return drawthree: gosub drawtwo gosub drawone return drawfour: gosub drawtwo color black rect x + 10, y + 70, 20, 20 rect x + 70, y + 10, 20, 20 return drawfive: gosub drawfour gosub drawone return drawsix: gosub drawfour color black rect x + 10, y + 40, 20, 20 rect x + 70, y + 40, 20, 20 return Examples/dice/dicewood.wav0000664000175000017500000054405411675357447014235 0ustar jimjimRIFF$WAVEfmt DXdata%!%%(),+(( $"$ !"&!          #'$')0277+053-'$#'     #%,9<A8435+*&$%#       "*''$+-+.042,-46428<<?=7:B=96-+1.+44045==@?H=E533*1,,*.),*271-11-.(+)$,,0+504422/2/-+'-%)!"$$*'"&             # $##%!&''"%"      ~~}w{{~pp{|zx~                                    {y~z|{~{~~rzsxntsvywrtvtztuqv|w|u|xyz}|~z~xxrzpgiomqsnptmijjipebccflufxrwxzsu~|{|vuvw}~?Gys?)NtR"Yv'u <x?}rynd" ZCUmdW}e;X~NO SabqcCU}igiEMdap{ffy|z}~/=8Z'+y}/]Zl+}VT(2+ 15   #!  UU?LU9\!@}/p+~t)  (9.*!1D_`YJYo!>FEAHN`s~wv^O?8%{mT1mM| TmFl)U5$ %5@=DVMTj"5IJ6*%,8?9./3APX]WZejrqks| ")2FRit22)&09@8i&+2rv)Bg`Wdv~tqaMB9;/"~vvrfU9%xwYTGA5  zM ^D+Mqg10LVVZ_y (8PNFGG_p~|$'-<BA=59HISWVH@JG\_jg_fvuaabmyxl]d`lseYUWLC@=SYaVVG>EDD<**+-+.0/$"' ' !$#'$+1)(/4<60:3=BA>9EG@DJNJINWWMMUUXec\]]ZI>FZdge\OTTSX\u|\Xt~vg_\la^jlchvplsiWQLXhoos`VUeuldOQM\XQGDJD?77.4+% "-'     !+/$"+*!"! $$#%#"!$*'230*523543041.043-!"%2/*!*5,+#&'(.,0-227396,3/:CA7/&.)")!0$%&$"$-A:,&,-:AECBD:303<:35/,+%,4-(#"&,*-'*/6),('+'&.(30)'*169;B:FPNMG:AAF?=;:438<:GA@B@=DFABHJB?7.52:95(#%.0;728A>?AD<5.65?57./45951743,*(,<0-,.,'-,,%!%&!(59B8/-:EBA5&%.3=<42=?>@9<6BLIEB:8AEB>1)1AGL;.0%*0.'#%(::47DEHG:9?ELVVWUNOIT]WID?GBLKKHB96>:><28.64:35A?</% -/2<3701:60,..1-+'1:@C;66:AGF>6FEI8*)29@6/(0.B>BF466/.671,."     !"!!      (('-!#%()  "!$$&#" !     '.+'*2:55'$-(<:<-**+.","%*1(-)#$" $#5.48;9=54869::;::;93,,'640+"!7695?/80&.&5&*!                %  )& !$"* "$#!!1;88113635725@:DJFE?:<CCPROFDFKQQYORRgc`YXXcbfibbfac]jcbRQR\hj_VJLFGKOKJGNKPIWQLVNJE>GLMQRYSPLZU\WZQK@GLJOMD@MNVXQNLKQE82+33?A>0*!-33236) )3*.%&#*%(*)8@>AC<;56<@;;2/:9@FFFJRVQTHGJTY\bRSQT]_\\RS[Xbbcfgfjjjdjjrz~uxqvv}|wwqvmonllgnkeekimrpojff\T[^T^POM]\d^^]^bgkXYX^X[babahfaV_UTMRIKSMLNLJOOPI@;DDB@A7766490.158=/+./6/3/43(&',/*2&,%+"$-0.//137=7*72<<73151393.0,/.185136=@=12',8<<:)012943,(-/1++72++*.121.0217()%#*' "#,59:7?5;@A;<;:=:78?BEC@A=?EM@E>HFGLQMDNJB;34:>;>>=A?CLKTPKJG9<;B@8:9AH?A??CDAF@@<7;:@C:=6EKNTXQTTTT][PSTUPQLKOMFHSJIEEGDRRG@99:D7>418*)-.$)+&)+*)$&2/,'*"'#%+(+&##%%.+*+,+).*001,8*41,14348;816+-,)*-1*..14262##%' "!% *,'$'%(.621-=?G8BA=@@LIQ[YHNMORJEQKOPWZUaWWTTZPNIFNFAEH=@BB<:;798;.007532-#$!'(% &#$".67*+"%!            "!'/ &%%!''#$!#"  &*)./+/49B@A?>>?GMPUXXPXTOPPKJMQQURVOKHCE>C691368>=9;A;>:;CCEFDIHJD?IHTTUZTTQGGPR@F?>DEI>BBA@E?<<4884>7?C>:2942'(-05832<:27/./2/11+&&'%&&('()*'0//)(.%%+',(('!(,&+8,/;7>>98AFHFA@@GHIEB>:<;=A08:=CDFI@CGIMEKAKLLTXSSQWWSRUPSPTWXVUSL]dhne_\hblcc^\_\Y`liuvsulwpqlfbfotoslrukhf^V^Y^_]c`\^kfglgj]UZ[_^]b^ahfglwtpxuxuwmjkphkgnp}|U'f&E+dch_X?6Yzr~xszwyx|~znuriustotki`kjhZ]gfop``\jikadea]fimjcdfdmmnadadkgm`jd\e`fglhablpkmmssvt{tqhnu~||{xvszwznllwwyrjkmnjn]\[TQRLPLSUbgngktty|uupuwtuumqoqhpsppqtqzxqljpmlj][bkcgdiht{wxzopqovtqpjonsgYchssjfe_gddgce`fkdkhd^g]bbb`_bdnmkoqvrrmkpslgkjliwrtowtqnntnswv|yvyxruuvwv{vxtppkpmkqy{~{||{y|zyrtsvnwprjmlgdaahaehdcc\[QSOOPFOLHBD??CEFDMSTRPMUXX[WYWaZ]TXYNJNIKNORUROLRJKLJLIQMNIE?9978111)$%!! #"$%!  !   ~B)R{am=},.hh-3fjB vZ35ONVd&e2xy}hz h /P'^(&Eb rF3?k=4pd7F  &)"%%     'G]T*          iD|{  !-$  '$$ "#-6>FF?ABL\STUWfs|xx{{~yqwlZWKD8,}x~|t_POILNSJPGDFFHD<=IPND?MTSLHMSb^Zervy| qRUHbisZm?'4*' /=A6 $AJI>HHO`Y`coji_`nvw~qnx{~v|{~~}~sstvvjVPLPQVPOPD:-//0-&!    % "*3*!!*+-082?774./327.0,11/<3945ABGCC@=B@4:A9:0'&-,00&#!$   !    !%#)%  !"*3950/<<?F@E<=BHL@81@DJIGIINMHLFEC?CHF<85;EJH:5)),8=5=88:C@GJIHOKC>;7<<<387<9C;4-+)!%# $#!  \cu51a-E9 z0MJEP*#s@VgG"",1 n}}{|srt{thdnrr\TO]ea^YTT\ZZOVRZQQA:CTXVC,+8.,+03/%$# #(0*!#  #2&   ' -(%#;;/"%&:;-$0E=9.+?EG@=@BKB<9EKMO@76DIBEEA@>HMTNRLBuHh/!<])Nnu,905?+sA{,""G(Pc$~6H)X&3E$$>@*2fs9aGcf;5><F(S]7%{l(6J)"OusL-)=2 =EA )&07702MT+:R< %:+" /DYE *?FC) &LPC-#5FJP;#Fo{k=6L`dZL@C]`[CFJQYPduvhdT^qspxxx|{hYx.$J0SJ, y*.j?F                1"  0.'    !  "*&'%!.*/1('+<C6%(4D;2-)-91,..*0@;7!'24>/#1F9(!-/'*/%/3& ("% "                     *.+  +)#$ $!#"&-,)&"#    !%(! !!"%%('"+0)% !!%'-+ *67'&#)79;647@C?G8+'/.9**%%*3,+'#);6'72!,,,% (/"               "/#,$)%#       #$"#%*,.(347;5-(3=GGE7:468;%"%%,4<6/297532)&$"    '*+$$40+*,16/-(-,2648/38>KLIH@ETWXRPQROPEE@A3<DHFFBA8783->BA915<CGCCHHELONPJPSPUMPZ^`i`dba]``YP\U\RJCAEPJHBFFMJ@8032+1-4,,&(//9@<56D?;&18HFB=9A8;=:5)# $/(!##()(#*+%52))! +2)*)1-,,* %  !                      & **'1%**/31-,$$$ & ! ##               $$"&        "$('  ')             &'!"$!"%$%#" !"!!&$$%+,       "$# "*+ "###")$-'4<E?43456483%4-B:787=:=2/3;?CGBBKOPKA>HNUOMKJLRYSLFOMWVVQVWY`__XUXUWUXVKJGNRPSXV[\^KHKLJQJINTHVJZ]Y^Xc\hig`hpo`miilakootic_gel_f\eZVSS[ZRYRQTMNKMSJNJ@;EAE:?9AEJG@ELIP]ZVNTV`bb\]ljoniihdbeZ[VU\NWOMILFBIDD<71(520##!'"&*+#!()!                     '"$ #*-(( %"(%!%"''/34882(-,,,00-369:??G;>BCJGKMHIIOOLQPRZZ^c`^b]``^ZUSTRPOJJMPJKTORIWYWZYRUURYRKIRMCGENXacggdjmkrtsslfceeefkimkmpelmia__d]`U[XX_\a\ied`ZZXPV[\_\[]bciipmmmopxnogmullshlomtxp}uw|xw|z~{{~}oeYUWY[]PKPKWHKHCD=;;20:>BD;999;IGH@H:><4,994:;07<FGMIBAC;F@B=<@FEE>@<A@H8.-)+6/((''%''#-'&&/0-:5=<BGFF=E?<BEEIBAIFKFHAEOJNOGBGELI>@===59:?3:/.+'" "(%+-*+979:<::9;24//1081))67;24/0,;:82020:<051.*-1,)+&# (00;0/'220232635@;>5=69;@?8?>HLHGIRRTSYRONHGFCC@NPMPOKMSXW`YVX[^[XOPSSSWSWZPKG@JFILH<CBCGHA=DHLKHIT[V^`]aafjfknhkmehdbnqsvsmyutpmme`[Za`cdijnfj]aa_Va\YXb^]_]VTYVX\XZ`c`h`^]V]_d[bb^^_kokvtyvqusvtonlbbed`d[\]e[WRPOKNGKGKOB?KHBF=5?53:586<D@6;63@?=C:?@9;=:8:900-'$$(&'&"$! % &  !$$&"&$%, !! !&" !%4.<51-A=E?825943,.),-)-.,++),-)-1.7.0.=?=;;<AAEDGEFFRKLHMEVNFGIHEJ@KB?HOLXXUN]\Z]\[d`]dac]`Y`[ZXYYYZ`Yc][bY]^YWUSVOSXTQRRSWa[[V[X`^^agngfemnlR[5J$  C`&_u-a1)>XVu7NLh~7f$jwQ!<C)5Sk5/ls< @ersW 57Q#`k:1UW65;5Dsr0:K&8E#'@0!1* !                !)+'+*)'*..'$277367EKLDPWMRHGRLH84:@A@GIKPNWMA41-3393)++"#45@844:@AB55++489;HDF87@PM{DN>#Zx#z) -=i FAW!{ 0A<&"%-"",5 9I.)O@"5;" ,&4UD4G' 6:3'2BJK3 $          ! $!''(#"%!-146-++2678;;;1   !%!,0)&"+.,"!,-341-+-9<@544789<68::MNDGNMSQLSQVILNJDCOLKP=3,0:7><BA4.%&("(+-(),0(/*-//,) %,(15:GIMJ:<EID==4<'%$+3<42-591*$)0.* %$""!'$ ')1(*#(3*&! "$+2)&#&,141166?:8I;20+9BF=/',4(-!+08:3*'(/987*1:@=)"$    %%+04/1(*8?68+964A>48<2=881-',.45110*'&)-4-,1.0.*3.,*14<1215=56=><><;GDC?-58>>84>CIEC9DO\\bT\SOQTYZ^dbZVSZ[eg\LMVY]VPEHIVTIEDITTTHA<GKRLELRe`RLUVXZUVYbc[ZZVPX]bd`_chpwynidmxuy{upqhnxsz||{zqhsxzwon]e^]c`b_d\ged_\[PPWdfhgbhry~twljjv|uwrpx{~|{~zxssxyywpwlmmqq{~}}{ot|qzsgodijglpy|wonhjry|}{ltunwnjibfivlj\\dkysa][ehaPMQNT[UMRQ^aXYOD=>GHEMHIH<<<5<C858:/#(+*/./9@=>?56;;C309<EBIS\^SUOJKE8675=531/,6@<.'&).$#""(  ',-"(,42/./324*)+*47:3($-:<6&*23;..0267+/)'.*&+(4+.:EG9*'38>I@::ADH@KFA>:;7687;:=@?D;C8<8BDF?FE:B@=FAE:;@760/62>900:=B@:=7ENQXRH6;C><5:@E<662BC<@;)354112564354)'1;/02@GHJFBBNJJ@=5>CLKE==>7EJNLKFDDACAGJKMF@BDGTNRWX[]WU^ZTUQQVWa_YSXYW[b^]SNV\WJPTW\^^ed^ZdbceWQRNTJG<<BFHA:01;DB42.15/4/7<FJA76<;:1'"4=8/**1>E72<9AA?=72608=>87)0/!!$            tt9Yy) fH:m6P9!Ac+fe$xq}|vyzw{oj`cppllbf^glw|qqsju}}uyssyw{}}xz|svvxwuvw~y|wpnsw|}w}{  |   &"$""*-1/*&$"       " $# "  !                   #(*)"   %!''%,/*)1:A89@@LJDFBHCHGCCDD=@;;@=4;;<EGLGBHH?t9F_~f9=8F'3*=rHQ~ YDGPH8( *0A]U.SeL ,<J9 0( (1."%.4B<2)0;<14CMZWE%,=HD79@D6,/6;, (% !& (<HLTLCCCB>;<CE@>DRUV][TKHTFNA7,+'205,(%&&(& '"   +-#""&#      %(*,.-1774.)((*68699;:678-,//-,' %#$!    "+)&$$*60'-(1*($*!,'!/,'&!!#!    &*' "!!*.+.,# !!#)+#)%+$ %' %   %                       ""+,38,+*!"    "!)..%,,32..).82?=ACKFIIEENMLQGDBCCBEC>B7:6337560./)).<8/3:>@;@?@5BEAEIDBJIDHHBBA@GHSTQSOOROW[W]X`[SNPQ_fej\bcillorZ_^fjhicmtuy}qw}}z{|}sw}~~~{v~{{}~|votrre__fjgcbedba]Z^YYXYc_\deddgeihpm^cckos}z}|~{wyu{~|t{woopovrogfljrngihopopkmhghhb]aaaahmpttmwslxmwoops{wwx~prmgebd_aeaijlrpu{v{uuunqn{|}z~zzvvowqYT @L-_Uq02/cqepscG*nDoc{Z6v\UZuPES&)5'uR*JfVzwbGUs]o_PNigj\Upyine_Xa`b\OAG{qSQtsZIRTntggksxk]cwxN>b{l\Ya{wUZzuVBBQluc]oVcrt|wmWgwjE@QwjBB^yujZeda]RWXXHAT^YD*'?JSD% 0GdfA'"<O\<<>SbcTB7/A<=4).APOIMXbUFHKGA=;:>7**7JG5#%(5:AIHTFMC975<B</;2C=0Ay} m [PKG? l nw{2\y$0{T1?uw5'k{B*,87!uf,\ SxPG{uP(1EGC)9ba4!KT< %99/FJ8&.HK4 7>3!";@MPbi[LQ[ZA/)7<5"/QSC53=0-'/0+)AB5.@=-"#/6"/1$5AB.  #+:G;$ "!$!1;& () $-) -& &(  -4& *&      !       $  !*'!%)*%$%!'.-!*,1751'! !6<91$)0)'%,44,$&*& (,7.*-*'"#(&!6D* (0& #&2,$%  "$"%#   "-" '# "(1@7&'?KC;.*361:9?@0,1--6920.1'6EE=6(,$#4-$59*#!-0,% '-*%,+!-11(&$,,2$!+3&        #$ %# #$   !"$   $#  ##(#       $#$".3-(#$ (*(42$ ,' 1$$('&-0,;A>-.-6=KJOG>>FROPHEHNSICD???@@GB2"'..- .)0*%'*%%! %! ""&"!$# #&+**,4-# "/*$*'!!(!+/'  $(..$##+8>10#&.1&!%2.*,0451+(+*"%$(#"++=BK?6,--488/047980# ,- "%%# %+/0# #'#%#$                 !&"%+!  +-0) # "% '%)$)%"!%-3 (.5,0%+#!#!$!!)$+'-.*+* %/(&$,$.-3)'&22)###-8720'$1222-'+& ! -/5./#-&'+*'*/998.,4196-)#!&-;=:.,($!#      !!$  "-- $! $!"_z r`Rj$~Z7]Lf'Cadb*Ukhe; js2.D =+)cBRTSbff%  ,F9:ATI)10ON&&CR31"$JK+" !$$1A:9/), 0%%(''-9 $$%   pT#>.O%^swFO4tMTR)A0|(mY ^|}|      "&+ $77/#).5945;E<) &0=;/)5CE<12616-*/8AH?BCC@BE7886<:.$$<>5/+9?1'#%$(($#" Q$z>d J&Xd2cwJyB % !Mwp<Isi'tm ;WI;baA JJ$EI%<q?DD%#QY!0=_di?.5RYQgCW>foN 5!%%          '4:*$*22('!!#& "#$"(/kBA6MMT>-i>8Pf2M"VkodbS>(&*3CG7DAGJ@-AVM)5L< -EJ#3%         }{zrnxztxyxw}xrk`aahaZadijhf`c^urxutuvrtwu~pv|y~qonzsxnshlfhkhgilpsuvyfkehVQOQUTZOHJHTMOIOJOPNU_^g\Ybpjnl[_hnronkjrtstouru|~z}z{~~{}z|w}xwy{}~~zywwqminrlksck[_bd`fe]ek[a_ollgajmrrrkp{zutyz{x||lkgrqidZfc]dkgahf`jjiqpu}uwv{|}}yBL!F;.$ &    !  !          &#!         (//1,15676;8893485.53.2)# '&+''+1217639:5+3231397649<<<=C<DFE>;?JRNB==BCOGGFKEIJLGEHAMKJHJDGJDD<;;463483/0.+23'312344:95:7=<>C?53167;?:@CEDFD8BHIIJOOJEKTSNUSYW]ebh_TLLOLDD@;AIAG553334-(%)%!#(+2)66<BNRJQPRU_]b^^b_[g`b\VWVV\\\ROVSYMFKB?9=<1-405<48/101753.,(115*1,209852(&$&($,5:778@8=F<:?><EAHD?C?A=:?;6-/0/43-/*,+# '&    +)+'$++).'.5:=6ECEHQLLOVGUWNOPGAGRHMKLLN>D9EDADDE>>844697579=9<654;49/1>==6C9?GMKMMOVX[a\d``aiieci_bh`kg\j`_]XVUQJUSUQRSSMURPQTJKRV[[VXU[begjchmafdgennrlqt{y~}]"2jo~r`A'$9rifypky}}~~zxsz}qibkififdhpjeZXekp`ZTZY\\WW]_YUWY\_`WZVXY`[]Y\aab^TTWcaZQICD?F@CCHNAC21'1?A?H;<9@>==CGCPHLOPHHGB>DALKNH;A<G><JBGJFFECGUNJFJDKRGDEB@ABB<;<5BB@@@;A421//.,+,/1.*,,3*++./370A858;3/<7131+/0+.'+/.+.;<<BB@E9CMKPCFIIA=ABC@H;57086966:975;A=?<4530/,596CA><HIGGOPQORRPNII;??::@>?FBDC>BBAE@<A@CFC@??=<>@:??IJEHLII?@992,'! "% #''&-*""&&% &))60..+,*3)*# $)"$"$%" $!!#$            Vqj z H ^3XPy{3x/O@( 0gNuLT*O@DXmp!b7A2O4#[t^adwykGe^@cy8 Qv=#AbV<Vt)~62eN6MWOybCB[kghppM=?:?b{jWgvr[EMo~U>7[{m\kyfH\q__YOV_wac|lo}|lgVUloels{wqdmpidpefQBMbp{{mXGN[WZlrnXdWNIY\Uhz_SZ\?B]gihYF;DMVL=799?:,7LM6 2D4 *-212530/)(+7924<;;IG*),@=:A_b> $CMA,%&A\_4!*BV[M; /A>(HB/&2)-=K-%13+JG+'&7TS' ,?@4:5 :B/  $         |@Pr^:$<7ysB&<3  5B/ $4-           "%          (&   $    &8   %+' #/(*/48(4N@$*:F8% %?LK==1$JQ='+6:?@2!*;JD2 #5;7,#)!,5&" +,(&(" ,%,/81$/;:></&*3:3#8;1510>8734;:1'&**&#03#,%"0=7%')889$$,<D=ABJ=DBC94AFPNY^ZKLDGPTB.8?B5( 4JNA)08AHGHEDLPSe[TSVOIX]N9=PdTB<KZb[=09<@DLE@EC1+17AHSC4./% :_G$xL`t' =}s1Oh7 (2+!'.#Kd6#8! 5UGMO5  #&(     7-)(("23& %14/.=;*#6B#(1,,''8112-)+"$$.""%115.#+?>:5-5;2:18;9/6/*36;666<=5 #)"./*#$+*.1>A?01@SLC>3207B=9854BEMRRNFH]XKIHAFU\SK@?J\\WNPXgkgTLLQVcngWUU]YlaYW_kxtqoidgndmrkl\asxphkork_`nib^eg[NYjptljvnfee`[X[Xab]IO[iqqlacghgaec^fdeji^PFI>N[cXILTZJ>:AEI@9<5./2252/&)5FC8:?FFHCKHDCR[VF;??ETV\`YYWblgbfT^Yab^ZTNQO]b][ZZZXW]YMLRO^UBIQSMOLBD?=7/3FKLF=;71>MCLKJAENERX`WTOOPTRQKJCQUOCLBEQVI'&2:B@A6=A7+988?;002+*)*#$-()" #+/80.2;GD:2>GEH@@79>JIGQKACTeeZJMR^^aSP_]]iwnhmkmjvwytrrwxttv|{totkszugenoqkdiqg_s~{x|y~}}xuymqdg`ZbiiaYYV][`T]akjk`gotlgv}psoknrxnhiekptuo]USdkk___ehjcbb]d^`\hjlgc]cfeiginhca^dlkpltlm^aiojd^_lmod[^fip_ghlehlspogjb_db[bde`WWOKHJLQQWIKGHGG8*18AOVG=457@C1)+4?<55647858:4,&0<7) (+%                                        "$& '          $!"#&#"&)!%&('           sJ7+1qc\9bx!^j9+.S~E<d[XtTpJ)0jws5G*/fx?.w3= gPnhbTdK.]H?rUl`~r   "-  %..@8$ '970,7FD/)?KK8%%8=7*$/OdgF>]R/ /FC<J: .DG?, 1JF*!. "A;1NdJ IbN#<hf3'fK%XbL1 AUG)#5?8# FaX,!??8''ANA- &/00$"+@C4.1/4+' )18*)ZlV5(<G1! -.('.50#   $%         '  %%  ')       &'+& )!+(*",8DIKB4(('07:/!9<:4  $2,*#)##+3!.7;1&*.@::9:>;>87==9::GKC/!'2JMC9)/BNH=(&:GVXA4.AXXK7*1<:0#(0F5$$7B@8-(3;@C57>JG;'):STB'.DG4:H=83&35;A<>BCB?<D<+17=;732B3'* "3$+3.,++998(():F>-'#).7C/ =, !.0$  &&    !%2( "   yxvr|zuxy~}xvu{lZjnholqiktygbcly|nb`h|u}hk{{}uep|pdjmnvwyu{y~{{~|ocdlvwxomxt|{~vxy|wruwxlptddmvypa`WcUV\dggX\eje_jlospikpuji|vwzzyww~z{{      }xEE= WI  wCWsgR=XM8) /sdj~2#U an_s\)4k2Vb)@xnoml]h|gv~`Nc}zu]izhJYu{}zrmdpqfowwdgq`wlmtxylkr}~}{t~uq|{sz~y{|x~   &%"'"#+11)"(08>50)&+97@CBBCEIELYaJG>BI;0*'5A<D5<5?FJEHECJT]]PKR__[RQJY[aROEGSQSUVGC?INRHKDPT\cXU\ffi`^aevxtlntsyh^eabg^UU[QWW^YXZ_[`a^ZVgghe^djritruqs}~{sqy|{xyz{z}oqmovpd^VSSSQKH><=<=>GA;765497425/8;/0)&)-73&!.76122.,+-  $. %     ! #     (#  !$   %&-*54.6BGI3/0:@;<3:9??C?D>>>468@BIJ?508IIA)'*>C;+&1=A86CRIPDBFFITUQWX`Y`moytrmnzumpmn~utgomsjaSYbdgnpsmmbiwnhfWa][dk]WS[[_QVMOVYRPP[ltshhpyz{rr}~}vjihmursijighd`[SMF>?72:9A>B<97++2<JHECGEMNPSPLVOMMJHF@?JSJHHGCDMI=BOQQLDGIOOKICJFFAD63187* $**&! "3,(#))1-5612021-320+3)&!   $&! %03&)(0>6/1/66;0,%/462=8;>=46DFD7&!,7:-''-0,!"(.**0433)*"(%*03*4:A;679GCF6++04CB>>>>G9<@EGPGHKWYSGF@D@87*(,15/%" *2,0.*%  $///9<?;5-485/64GLPKJWfjf][XY`iff\[agow|wx{y~ypu{zpa`]ace_TU[bksooos{xgmptr{ryxwsx}|zyvz~xz{zvllitvyxtmkpmpf_inuuqjhkkljp|vrooqtz|t|wxt~xxuvyzvownywqoghxloph|ptuqvtx}sqvqyllrvxvuqyy~zzqttytokde]]RR_Z_[TPQTPLNMLNGDPV_ZMABEFMRVNGQUTTNWYc[ae\[YXc_`gfb^cbhmkbY\W^aZ^ie`[XTVUTUYQSNWX`aZF01 FTZF}TDO%<d q!OGHq;z:'Tb1{O0O |h.D} C;o? Wa_l.%Ytaa|Z*4n~hS))IbQPyiH?~iO^{xJ&0rJ3h~ZKdqoeiwg]\4'=h\9LhX4+VibI?HMLWtxU87P\^L$)GY][@'AWV=.:I<:=VZH8??JSM,!/?UP.8>F3(+7721&"3IC@./)+20* 0LQ<' (54-/780.! #-! ).    )+ ") !&,#   ,0,0 +82+54!  !! -' )<>" )&$ %& #-%)(4'   $  '#&%"$  *7.%/"#" $  ! %  &%#%,).61!&?9! !#)#'&0@;/.0@@:22+5>AD>?8+26868785-*315$+*-5>9-'.;KI26EF<1)'!((2+'9?;.#,3EF>AA?F@B=<DSLI;175:."*&0-,&*%1/0..1%$& .)+' (( '#& '(% %$$!% & $1/%6B:022+!%120!) #&!     +''# 8*"04*(''/+! ,3*$&+&(&!,$ $& # ''/4/")$ %3#7) +,!!$ &., &( '1-(!+*1(-77%$&$(0)&720$$.( -1% (. #*4'!$   #"&'&%((1$      #                    !!!"153,(.9A:10+(23,"  %    "&'" &(" #!  *           #!!*'#(!%''*.012911)&$% "#',"!".+"        ##  *          (%' $ %+!$('-')+"*#%!$(.%  ##1=58;BD@B=B:935=.20/*(4))*'%$(+(+$).5,47=7?B?B:?5;=@GHKAEMJOQF874+$!! & !!#$,(+$%%")+-()23+..'(*+03%)&$"'+'(!"        #     "                 !'$ # $! "".03)'(24/)#$*"%(+(+)%'" !$+,)!# '"'!%            !    }x}tspwqvyv}|   "'" !&%(#$"!0/+(-+81<>;<58=<?@>HEHD?==@G?FLIKME@DAF=;>54:3-'(#"-,51',-038451/..(,$"$% !(,2+&#%&'($%     " &+&*((4/00)+''*$$    ~~{]30.$2D\VMLNZT11SopF4>`_?&.GfcN22Cdjpdlhomrmhqnh_MTmjr{w\Sfxtz|e^nofv|}vmtqfeuu~p{{z~}|{wxqus~{s||{uhmt{|}|~}{w}|          !   $ #(.3**,'#(($).12,))"((,3.222229=77<9<8:41&)).$%#)&$!#2,/+&'&..<:@657?C=2,-+*.406<?=.2/--&)&),//3-.)'"$"%'*0/* $" ""!!& #('*.,$%),*34473/67;AAC<512494735254-,13)  "!#"#)'.,/.(-10:368>C8?/07;,!%"*+$  &$ (,6-*-(243-/12./.-3843+-2.*%%(02.%2'-/44/ !!+.(+01/668::??JLDHPW_b_ZWWV[TGEBAC=9:;:7CDIGCEEA@NKKHDDCHD@BAPH?@;:;=8;>>JGACHP\XSP8O si![ ntb )\FHZ0\C3kaHFUqN >YA*e8DWQM72BT\Q*Ea36ID-wtuoVE*1IYs\ ,N=+?3  (5O@S]$++#FebQB,,%"/II1/#'8/-E>' "" K|j9eLo yOnXJ^UQO%\8j#sqb/WuqX`h3Xi>Y~nGszbou7*xc6/itmfam{hTtop @_5 Su)UWS[Qvs" #?WXJ,,ZzsT84+877?H[njxr|~oJFQ~|lq~zzml}uhhqx|zvqmsvifs|}~g[_xzqwsyplmr_YY[cjaTOPKLACIBLQYK<2BYgjfZG5:HT]]XXXWG45CMJ3 "($'+/1+         +**&$$*%-(8FLICGMSVUSVT]XYNKIVRWSH?BMYc\YRUUSXWcdb^aakkkmfhhdX]SZ]aaqkg^ecksosu|yongix}y}wytwvjaksyru~rminz|~~~zvhgozsid}~|xzytt|zjgfeedlrxk``]YUOEGY\bSCAGW\[EGPTVOJLD69BKRI:1/FNMA+**.25=8597B%)X~M$&$  #           !(!'&!##(5.(& -2/%'-'!(+-(#('2(>D@0"&540$##-(&(35322=<7<AEDKPE;:;=0*57:6/+(&+7C43-.3-$)40!"!&'/(! ,+ =Zla72FD2+.6EKKH?-)&))8A?2.8:2216>A><:>GEWVRUQL@=?AFAHNA;ANPUM948HLG??C>-319DFEFBD>=IH:D;;A==9?9;38BEI:78(!$ $( "" '  #  9VRM@ew   '$" $,(%&'+#"&(/0-!fi[p9P3'3AH9#4>@5+),3*:DI>303273.1+-/0)&*.-4*(,(/+=6@=::I>7159<-.(=HHIJJMLJK@32478;66;++,6CNM>.43 .MrmM$;`gia]eok^WZa^VID8;=NNSRNMI<D=C=64<>CE>EC@/0/;?626@?DD@A==:9&*-0,40'8,'.0/"+2259@99-'!$+88>0.)/103637<=;+ # !)7AC<+%)4250520*&(16=4.'2A<8+&,0, #+-!(,.0)'$&,.3,0+-%#+--1"#,&#!224778@1-     *% &"+(('#!!  #&' &&"&%!#3BAA92,&#&$ '.+/630)"#(!)')"&((2.1//$ $,4?@;76/5-,#*5463+++/31,2-?;:<?CAEEFGCE><?8>JNWSUNQVTFFLGHA:;=<DKHIA:9;=92*405+-0/5./-+*9A?A600(#(-2726501-+1+/1=?FGOA5:7:6296;25-33=9<7<===::-'%)$0*40387977495%-4/:71%""'          #""         (#{z}|vlmuokmb^SVOIFDFFTLFFHDA?6&"%"    $'""$..5/9BCAGEJECMJUQOGIC6?+ (0;  |zxx{ux}wxwvshge^XSQKHDB@BA:BE51+("'$# c/gDoY    hX 0GK?BOL83;Pdb@1ISO?&",8@;4. %"&' & ".7;@9A@B>AEQ\GC6A<DG=DDFE=?;>;0)$ /,6,((!""$" #&"((#!*004-3,242>;44'(1+' !"&%$35455<;783671376<+*!/734&"#!!      !$#%&#(*$#!%/)%'%&!#! @P\R)    "&'$',*-346*//()+)066?=61/&)"$ $#"012166=78?;5440/)*28655>:9<;576+++1(+(0)&#+;>A589454<5=41.2.1.262),$%#"$"$""$'&("'$'!'(##%)265=:<?75;58:758915;7;?BF>@GDG>HBGA@DJNMJK>87;B:6<?BLE?<:/87838--,/33<=AB::97;<A;2:5;59>EBDE@A@CB>82<<=68EJFH@FC??576-7/20/.'2..20#*-3-/*,7371.%+.5*060253=@BHE?DIHAHAAAA;<8<?;>EA@AGHKA@<<<76.)($% .`_.+%#!   %  &$     $!'/&'!!( '" #$"'&&*)(47>/,''-.+&&#" "!!#(1,%'+,2077126-0+522,10&&++--%.12'"##!$,'!   )5;=833/0)% $'.1633./-1145+))&.-,35978=>A992)/0/187<@;.6/0/*.23.213;@B=D<53;:B?845382@49-(+$%!'    !!*,3/.,$$#'(( "0./0.43./*)/*'%,1372)!"&%&) #"!& %"%*$&'+*/'08?7@/989<;.'/,+&(+16973/70705=>A61132:<>8667;ADD<KHGKCEKLLEDDA?FAGDLHLKNJMBOOPQJFKIPJOLJQOUJMFJGIBCEEIKOLFD?F<CBCHPHGIDHCJOVTSW]TPPRE>CMWUSRXQYQ]`agjmqni_]WamptlbYRPOZT_f`^hU^VVKD=1*(,--.297;76D?404*(*37=7:8:+359@KVRWSGDC<,!     )*,0.&"-+6>BIK@<E;BDJJ@E>>BCA>:?6<?4=BFA<E>HECELJGMJ@PXZ`Z]XXQUc`[[VUWUSRW^bdihacekoknlinmbb`kptnskihlfjgedfiighdffcc]\RV[^YVVYX^RTUZUQWOVURPYY\`_db\SMIIA>8>1>>@F<C<:4GMSLHEFESXRKJOMHDE9:<3.("$&                  "(!)#$-,%+0,/&(!)#!&!"!(0+-653/1670532:2/,'&%3<>@B>BEG?6531-&(%*236194651'"(#-)./862/+('( vxsp|{w{|x{z{xv|x}}y|yoljesumkoeb\TRRMA4131(,4?=HLOPYe`]mknsuy|{}s|{y}vynnpnolnkgd_S[RTT^hjanv{v|xyz|{~ ## " % $ ($!('$       #($""    ~tz{zuptnvyxrkpoqxvu{|prmkd]d_fa^^eejonrqotsrxyx~z~w~svnqniffecgffvqqz{z}      }||zy  ''"+")$% !""'$!*+'+,&)'/$('$$&&&/4777;8=99/..$"$ '#%)$!      '#$)%,/+',(+*-(++*,*-00/*,3)+,-'$((*&&#$"! !$$ !   !       $%%(%    ! '&+/.+-.+-0=9A=>D@CEAEC>B=66=6@A4B?8<<73.-,$&$$'0*-1-5,//--/20670035*0(#'           "%{o"(${qKM>w@A}|Wm;nj%tqsdf !'6xP^ mF_ }'n)*P7MZB7 r 3`?f?7X<@ 'N 3h5pmOgnp E} 6qWd]  L ow.MvlK D@ z r) bIWcH~t;_Ef Fx#O5 z Q # o # ^*sei Ac S v-N]r cb8[bx fsSgk,?-!f*CK OssOSZel (oHtqWb ;Z-o fKb5"M@{!GP6CTn3qf`bTS V\} V .GW1R <q,j25UBIn2GF1U9=Kk\pP$ 3;bm\tR0 XsYc9t N!*G=B,hOYg[?8U8QWR}@wP*t$s ^VpOnVh K%9:a 4j9Zykckpl_YQG5|9(s1v/n;/.DXZizyA+^6Keb zKLl?V<qMA^!t w23`O!IuI  4#LFclHi/@ikq8Hzi$B?B 1U;*`]p~F&8tkn$?Zuxlp-qn3DENND GxMKM[8 *G `z;CO[PI p T$'` v&s<:$McgcQBv/Cx7yDSA7tw/>g= C/1B_X\|PMn# 1}{D]}$1:8cH7?rJ|'*@V "QpE{m{LGI);g=?FE0u+]Ez"F"de2MZgHEi,;X Iv9.[63Y+zNY2nY3| #?^S-r{_.wxcF?VWWMZ mfQ QG@d1I0d7C8Z*&1qdJyw]3$kxpfnG$0a&Bm65BkV?,#fd wye}N0R_C dzRP<~/Xi>yV6TP\C=I_puF l:.z;JL@imcI5s `%cJ7qe=c4I9pdQn-+'lKab1UE'+/7UEo36,QTHkUKIxu0Te8arg $MdY+O=WyK W"64 v8#FdHwE}G]$\u"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0.9?BMNNFGJ>BFV]c\VSH=96DS]dgk^U;*-.--,/0/33=CGUeqyzyykZH6)%-/.) *;Ljv{l\IDEEN\jw{tuw~xme`TOCIKROE<45;GQeqwrsbXFDDC==?52."+*09GD;0 8:R`i_UK>751558($      '283%    ##)/<8440! 09<BDLXicbdYL6& %2ES_fjjmo^WH:/,)!&**.8DKL\bhinpmh[JFA?GOJVV]a^RWY[aZ]\UOJJKRMMQUcggpwkcWG9*()3?91306-.5?@ICC<@376;AIScnwtwts]djmqtph`SJG@D7@==<779647528;9398=461710-!/$(/419GST^dkuqtpgli_RNMLHTXPVcemovsd^f[MRJJGC?<7.+#+,$&+($',+.*.2',+#"!%,11,1+($#$065B:/(!#*!   )/&(% "##"  ')26529.(%,23.+*#")9GIRXD>5-!)&)06DJHNNE99,)#  06;H<.- ))0::<EMMQQLNKHII?BHLQVVIM@9==:?DMMWc__\OQINLFOTVYbce^W[VRPNMPSeiuvvyqrtrpmjimotyy{{z{xxwvww}yrztwz~|qhVW]QY\huyyzsonkjgnwwokgbdaYIG@>D?GOUUUYX\ZXZYOONVTJG:8A5750<BITJOJJH?7+1-35;9964&,)''&(!)#"!'&58@DC<>>773*#$ &%( $476924,' !$""         &&  "/7@@BA7,  ##.-1:2(" $-($*0297BHGGGED:;7./,-((&(*2;<9C7:5=;BKT_bbYZH@;630+301;FHRYU\aWXTQHFHHTWV_abcZNE>61>ILYTgadmiZ^SNED9=JFTV\[JA21./),79:>?>87G<BDBA9;49:MY_be`c]VYTKIC@<65453>:7;;FKNC;0##+33:..'/,$#% & #"*15<9A<:74)! "!            "-/2/3,%$&$/65>>>2:+-,,.9;@?EPLGJ@=:5573@EEJPZRBBCHOKNJHNGLBLKMJJLKPPPT[\dichjistqqmkgoss|rsl^][UNMQMNU\_^efoutz}}{}wjhdhhfnx}x||uukggfqvx|{v~ynqlqr~~idb\^\_bdkmifjsstuvyurtpijpmk^dkiea]a]_lgquorfmcmloujqwz~ukaTTQ_^mmtqoidZSIDD@BACDPNOMJFA:00%%'"%0878:58??=A:847:260,1+&!$("   -6=:50(%!   %$*69785:=3746+3859A<::;8>191<<@>FKIPQMUMOXNPK?DCGOLRVVZbfnrtruuxrqjwvvsrlme^\^X^bcghmmfffYPGCGNSU`][XRNNFICHDB><552617?CHPPRMKG8?;;@LSYZ^TRUPRXQPQSUKCFCGMPS_XVWMMDGMGOX\bfhhb\\RMJIHMYdgpnrnronqfkcb_]VS[`W[W]VSSNTX]TSSNHCB@<?CEFBIIIIQVPTUWVWW\WRLE<:45=@=?/$!"!%677:-&$#"%))2/2( (1-20%!&        !      '%   "#+1003413.+'713?A:F@IC8@>>7HLQ\begswnlhgacc_aYXRR]V^fbbddaZSOLSV\WR_VVVVNU[SOGMB9:588=3>6==D:BADHCJFPLQMQVPJI@95*%11/7:7542+*.0068;DKB?A8=7:3//,$('$").8<9A772*(,(&*,)+% & /060,$$$(-34?<5566<=DIHHEHGE?BE>=:=CFHQRBM=;&$% #(&,*$     $**-44011**(*%*$"#'$&)(*-$          % +/3:;>?8:<2/2,57=/,.',)%&!"# ! ( " #%##)&&'*$-)-/5.2?4-'/(+4+-0'1-*8%$"  #"&(%$%$%'+.7126;=GLGFCGIFI?HDSKPSYUc^cbabivvyvurgkhcY[VQJOIIEFF>@F256-31.:@?CDB=6..3.-01>;EA=A?GF>MKLNQQNMOHXUVQSWSdd_gdcdXWUJAKGGQOQQKRINIPPMOUSQTQXYeikiqoghhhnjupqmtqimcf_^\XV\ZTSLYZNMEQOJGIH85731/012.48155:2.0&-.'" " " %'#  ! !!"% (+1./$ *,(/+5),,+/88BJD:A><0+(& & !'&#%$     !#")1153233>ACGIQLPLLA=:@<0:39;<A@==51$ !$    %+$*!   !(,.135242(%!%%((+4)//-#/($*&,0-5;:7:88>:287;543D<758476.1316<96=6=42629>?>?LKOZX\ficfeeb]ZSMEJAGDJLGPPONVJQMH@FGK@?GBFJIOOWSXQYPZRVUTUUZ`_cg\^]bWV[TURKRUQNEMCKMIIRMOUQMFLHFFLI=ABEHACHHQQNOKEDA=?:<>;706555:7?=>?9341+,()&,('*."/040449,.'#)#,'10+2*'(&(!$"!"""!$"((1(&#)&%!$($-()"!              %$'$ $! !(#"!($      ! %#$% &+!)%!$%%!!&%##!     %#! !$&2,.5..-*$) '%%++"$')#.-*()%-+-+.5B==CJAD<:?;=;?<;A@?@@E;>>9@;::6::4;@=EEFNGFLGJBJEAICFKEDE=6.-'-/()0+(*4/*(&"         " %(&*$-$4('$# !! *((37=:B:>B=>6::>;AJCBFB>;=:<8=<376,/,/2::488<A@<A?9>@:759;@;612;709D=EDMMLSTPSRSQPUQRVYW___fcdffgZcX\Q\UPHNGKRIECF>?;89C?:C=GCI?AGCG?<>?CB?=9?441/-'-%$-(&$,)*3+-4.5-11/53)&-%&'')$" $)/'(+."#! # '#(.4608892285;257ECF@GBDIIFHHE@BMKMNF?>>=;:?447...'/)*/"!        $+09856><8:A;31'%(,8011<8?A;?;:1418-20++!"'$ !+.-&*.//03061,/% -19IX\ljpsmkxtrpwnjdVJB3)0-2JVbdm^]TOGPU\]]_VPCB<;9:87>?BENT[\daaa^^bYVTWQU\Vafeg]UKN<53/5215---.4$"'29?EIF>=6.1-%.$"'  !,17<A:6%$   }}w~}wm_db^Zaaeeroopnkprrpvyypjeg_knrruoli[[bppstpillgjdfhltuvy~~||vqquwtu}y~ !"# %###(!!&+675>30*!'%    |   "+("   "+05*533:1+"''"$'/24119;CI<>-* '"$*4=B3)!"7?BAFBLKPRQKF<8-*$26<@<4("&%)$     ! /@_nu~}riVD>1 ' $# /4;BM\YRTQNMLELNPKMBIC?FFJKTHC8:<;GMUTVSVOQNJB?2-'&$$#/;DXcskne_]]^_]bb]ZabaUUJLSUQ\_b`b\YLFAICGNYc_cb\_ZXKBKG?MGINHEKHKONONSRVXQMCGCDA@FO\YSXVSMIOLVHHJAI>::"-$"---#,###,(10%#      &*&!!  5LTYQ@<%&&(-?F=A91"&*$149577+,).:@CG=F:<- #%)*+/0!    %&.8;2)/$ #$05BKDDA;993.."%'34:62-  $8@ADB=6/! $+5A2-( "$'+++737./<ED4)&&!&&,,,)+%%        !!!#&.3388:??=782,,./...959@==;<:26,. &!  &%!!%2;81;3-:=<DCELE@?80+),-! ! $&('('1=CIHRUWaWVMMSQUQR[`gjmtsvonoqosmldkrnipppinil`d[_^ntnwuvrprrhfe`VRORUNVWQKROJJLHHNHE@=;?69;9:4-('-(464759@78<<?DSWTPOSOYOUTSW[\XZaZLRTOKDCB92.0,$!!(""%'!(     ")-.21()(*-/*,$(,('&'/0+..#&&(!   $-3)*#!        &%%*#)$,.27<7E@BCHCG@CM=20000.6422,+2&)'+('!%(&%#(+-//-/.79::9:976<9?AB>DGED?<A11-$(+*0..,*+*($*(0.&(--.74,6/100264838.,+#&%'*'*!&&( -+'))82/-0(.'(("$     !&%#!  #'$"')*%!% *&$.*).08:ECG?NRT^\cc^_[[[aX^XcXXUWZ[cbZ[[UV^b\YPROMNJMDJ@>=8:679<>?EABD=;75535>?EBJEJJHFHCAEFD<AEAFAFOMLQV]U]\f]^\X]V\XOVZVULOSMKQSRVSPYPLLPJJRAH?<84*.',#$+.11-40.14231.&1*++!"    !*!%##('". $&&'")1*484+--&+2-.56=>@GLJKRUHKOKSMWURXKNHN=A=9;25+2*'&(&./&,# $%"*(*))+-/164483354859>;EBC?C?=<50+*&*#$#!#$*+*(000(*00-922+/121..,'"#     #  "&$""&&#'!,$%( #     " !%"*"&(((/&(%%("*,&',))#%0(.*-/1+/(+'&(..0020-*"$      !*$*+,2).4+' "&''),$$*&)("&'*(+*.095-6;314442>8<>;5>AFDCJFBED@BCAED@OKMGGEGGHFEAA:.70-473514/40.-/,/,&'++)-)"('%!"!""              # $'$,&)//1527863::642:65768159:6.-3-/-46?8?C;?8-10318@=E<>E@>A754>9=<=988<96147:;;<B;<66=5858776676:=@<@?H>>;>733/-%()1,%-+2,.29:9DELGTIQPQUO\WQTVNMTKFGOW`]Xb[VUVRSNKHKGAMIG:>IA;>?BF?87>7-'%'!## $(""!       #$*1741568;:;7>B79B8562492/---)*(%&##!%)'&*+#1//13)*/+'*,,.,)')')* !!   ""     !!$($#()/3.+-$'#$)&!    '         %"#(*.-&&''&  "&$!$&./0/.5+770>641+9*.133-6*,1.&*,0-0..04+*$+(#%'),"&'*,6/0/,17:><=;358634EGEGOQPWW^\V[]^^`Zfa_a^ffd^f\b`XW_`]PSKMJF>>6.14221/1/.,,& #!!!*(-*!.*))# &*%'(".-#*"$)&!$     #              #%'"& %(%"*-*,),,"'$$!%#     '!(#'+%&$&$$#$    !$& $*'+$.,2,7825+-($$!$  !"#"%.*,),"-#$#!$!+#(&#"#! %('++$-,-,)/)(!&)'((      ()#,+,1/2.4:985:AB?LQPOT`Z`]bZS[VUZ[ZVbbbhjfmmjnrjkgfc][[ZUUPVVTS___b\c^`c]d_hZ[YZXbVZ\]ZUOLNKUZYY\_`iihkhlgoogpjsmuwswtuqvrimdjjm`beecbepojqptsqrjrjojpkmpmrxxqwuvvmnvrlkhmikkkmhi`efiiovqohpnoeqpummultpprqvwtzws}pyw|yxwmvgtkkfghib`cUUTXSUZSVTZXQPUJFBGB>DA>48(/111341/60+0.48211873>1./()%$%1,+%,*$*+#!   !*%%+&1,42/.*+%&$!)*!'3'.%*+)+%%!## $ $#!'#!&+%*003,.1465456247??HLQRNSIOGMTSS[\Z_a`ghbggbccac`_a[UU`ZRSYPQRXUUQKUMUOTSRMGLSOLVSV_W[]`Za^]kjmpzxww|y}|vzz}zmx|stswpqqqjqrynkkvnuzroopx{|vx|}|y{~|yunwhijbNUNGBB8683/+*)) yqppe__^b]`_bsjr|/=N]j~ spj\ZOMEG<.'! y}xqogfrjwxrtqr{wwmrywuxu|~        !# $%**&#(!$#&*+*05866;682<<9;EBENPSVSNLHDJMBJPDKPHEBJMJMGIIDFLFHGCFE>AD=?EC=<644/414+;=ABCA@A=:@9@:C:A63+(         Examples/basic256_icon.kbs0000664000175000017500000000160211675357447014027 0ustar jimjimprint "Generate BASIC256 icon" graphsize 512, 512 rem set up initial ball position and speed x = 20 * graphheight / 300 y = 100 * graphheight / 300 r = 20 rw = 3 yvel = -1.0 * graphheight / 300 xvel = 1.10 * graphwidth / 300 yacc = .0098 * graphwidth / 300 fastgraphics color darkblue rect 0,0,graphwidth, graphheight loop1: rem change the downward velocity according to the acceleration yvel = yvel + yacc rem calculate new position y = y + yvel x = x + xvel rem check for collisions if y > graphheight - r - 1 then yvel = -0.9 * yvel : y = graphheight - r - 1 : xvel = xvel * 0.9 if x > graphwidth - r - 1 then xvel = -xvel : x = graphwidth - r - 1 if x < r then xvel = -xvel : x = r rem draw the ball gosub drawBall if xvel * xvel < 0.0001 then refresh end end if goto loop1 drawBall: color darkgray circle x, y, r color gray circle x, y, r - rw if rand < .01 then refresh return Examples/sprites/0000775000175000017500000000000011675357446012471 5ustar jimjimExamples/sprites/bounce.kbs0000664000175000017500000000111211675357446014440 0ustar jimjim# ball bounce program # 2010-06-13 j.m.reneau print "use mouse to bounce ball on paddle." color black rect 0,0,300,300 dx = 1 dy = 1 spritedim 2 spriteload 0, "ball.png" spriteplace 0,10,10 spriteshow 0 spriteload 1, "paddle" spriteplace 1,150,270 spriteshow 1 while spritey(0) < 295 spriteplace 1, mousex, 270 if spritex(0) < 5 or spritex(0) > 295 then dx = dx * -1 if spritey(0) < 5 then dy = dy * -1 spritemove 0, dx, dy if spritecollide(0,1) then dx = (dx + (spritex(1)-spritex(0)) * .05) * -1 dy = dy * -1.05 end if end while print "you missed."Examples/sprites/4359__NoiseCollector__PongBlipF4.wav0000664000175000017500000001325611675357446021111 0ustar jimjimRIFFWAVEfmt DXfactdata0 r  3wdw:1`:hDrsʇƟs1\Ҧs|SȮukVNQg7᲻ʱճK^~Oj?ѳhҴmԳMѴ<-w[! e^ж۶9' GԸ0!9JDl޹ǹϹ̹ H7o6ὡREU}~#b`FF\XplY1MyUOfNk_QQ_>hdcVQYcd[SMU^b{^_V&TY__YYUV\_A["VIULY\[W;U6WZ[XUUXtZXYV'UVXXVT`UXW8X!WSUT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n=".f.RIU%clukoU6CGbT7]#(>#GO8"G['0IB5.IR0107*d[<%<M^36cY?I**- +1;CT2'Lo9(5,,;5qe[A'8B8_JA_AW ?&.AY&.WHN;k222L- 67YC(09=5=9 +6 ="&8D2 *.2;%->%OC>X(  S169S+58A+3 &"D2&H.?U<1. -1LGf6##156"9" %.!&   2 =6  &+2.!  - &&N+<M!?(,,  +!-L #  x ia~qlb x~}rg^Z\@RaL:6smpl<X< Examples/sprites/3062__SpeedY__bleep.wav0000664000175000017500000002541411675357446016526 0ustar jimjimRIFF+WAVEfmt DXdata*a:۷`G™@ϳ1/+6 W1XAޠ N#L~>յPUl6EwʟiT^"O m#*j1i7}@ۻގ /dg :dBL g&4u"dCz" I >r7VD4Rv|Q I iU| T  O Sed;lxe]j];|D*z5Fq -g R,#2&(*,4..\/w/.p.-,+)W(&j$",x Tc6U rڀذט1Qrܽ{|SXJK q#H'+O/3n6p9t<7?n@BBCAA?<;8652 .*%!oR& E^أ0=ͬȾư!PԽ ¾TpQCr׽0q R="1).49:J?CGJMORST%UT8SnQNK=GB=Z82.'h" _[ޤReΌUɻǷֱ殜(0\tdݦ¨tշ](|`9 8)"),0p7>EgKuZ Ez"))/T5X:j>3BGJENYQS UxUUTkRfQNfL/HEA=j94.P("` Wnc^Q:y1Q«cN㱛UɹN/.^!Н~܀Dk 86(Fi$+R16;?;DG(KNuRTV XYX@X\VU~Q_O/MJ:GaC?:50*$V- n,߬ڢվxϾPګDتǪX ޫD 5ɭCۭGi  !'h-:27<#AdEJMQ/U}WYrZZTZcYOYhXVbUNTR7OYK~HmC=93.($>s Z*+[c՚ƖAŷMr@L- MR襲0NFwSU)Wt $+~1h8m>0D`I)O UGY] a#deeffffddcKa}_0\aXS NHB=7t1d+%1'ߠʭӾ:Z񫋥q֑^DkoOb廝6-?ޏ G_t'.6o=wDOK SZ_Jeqim pqrtuLuauuusKqmjod^{XRLE>8{1(U o)PNԟkI9)\#3iDdˍhڠ\vSΐ/- \%5-6>HFNvW/_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» \&Y՜ٽݰߚ(own2C p$%),.3~37+8;<=??A?A7AAo?;;6 607.^*%"Um Aq9ڏh%d<ƈBhŵs#Qv#/RT{L.~n Qx n%&,E.f1(358g9<<)?????a@=+=:97&5}2x.$-|(%c! 3 L}`&*k=і˺RŠ`RV`F$ǣvHg?L *~s!%w'&,)-1~3J578Y<;==??j>?M>w>;9763Y.,(?& 8NF Q-lq3:~ΠȞ8=ѿ5 K\ɘjϤLQrR~ T "&(*/0459;<==@1>A?=^O|xml ؒ֫ԁэы}y.&Һѓ?փJۧ*CiMM +edA_!w!#%&&&(')-'(^(E&%#p$p!K! h$(Kai T2p]BJ+94[fhHld|HL* 2Y \ OfDnM\8; E 04<+b}'!*'TV0{(`XL) f=|m4j v p s Y 2 gD&v%8?[u]f%%u^ f)qe+ eUGkIlq66@R  *}hLdoP[ P= x 7 `>iZ '0?bc{+g8M`/(z2N~gB-K x m^ 3 7 &(^#=$ 'd!.6$AXh2S/2ZHd 8*pW[$S+Hj & ?q/WOg heC4egEu([_+*CNOXM  X E P R-AH a s @ F 3xcmBC3mCV]m\aA `  MkUh& 7ncDh,pTxV pLy+k`3]R[Eav~1/J95; $ aute*[1! Y3Wp7PojW+=^oZduvB i5'91x_^;7]rx'1~X n&* h%Rd$y7@EA*xt+C=A\=u;4 F2<IFi0U)=^+Gk!F:U pDYwe3"~a~{iRE0 d .lsZ@9/3/aCck!6=M4/s!Dz 3Xs:MX{zq4 Z:KV&`EpMJh@uyntxQ#rQLG&$ 4r^<SCDL49:lUHW9C*9JB4|~]=+ Wciw5 VP6yK{YUyGktJ@$56x 5-(11gaGCxzjvqp{qmkL)#SuB,4!,$K -D,H>DUjib}  !|p &=D K@$^XGRRT?KOFZQZZegV[V@CVqjYfn_dc{ujnz  & ,:8 ),*--,67>B>?;:H 0 spriteplace paddle, mousex, spritey(paddle) if spritex(ball) < 5 or spritex(ball) > 295 then dx = dx * -1 wavplay "4361__NoiseCollector__pongblipA_3.wav" end if if spritey(ball) < 5 then dy = dy * -1 wavplay "4361__NoiseCollector__pongblipA_3.wav" end if if spritecollide(ball, paddle) then # bounce back and speed up the falling a bit dy = (dy + speedup) * -1 dx = dx + ((spritex(ball)-spritex(paddle))/(spritew(paddle/2))) wavplay "3062__SpeedY__bleep.wav" end if spritemove ball, dx, dy blocksleft = 0 for block = 0 to blocks - 1 if spritev(block) then blocksleft = blocksleft + 1 if spritecollide(block, ball) then # hide blocks that the ball hit and send the ball bouncing back spritehide(block) dx = dx * -1 dy = dy * -1 wavplay "4359__NoiseCollector__PongBlipF4.wav" end if end if next block end while print "game over."Examples/sprites/spriteslice.kbs0000664000175000017500000000244311675357446015523 0ustar jimjim# spriteslice.kbs - draw something on the screen and capture (slice) it # into a sprite # 2010-06-14 j.m.reneau spritedim 4 dim dx(4) dim dy(4) # clear screen draw balls then slice out sprites clg # ball one - blue with square hole color blue circle 100,100,20 color clear rect 90,90,20,20 # ball 2 - green with hole color green circle 100,200,20 color clear circle 100,200,10 # ball 3 - red color red circle 200,100,20 # fourth is a square with a triangle cut out color black rect 200,200,35,35 color clear poly {217,205,205,230,230,230} # make sprites spriteslice 0,80,80,41,41 spriteslice 1,180,80,41,41 spriteslice 2,80,180,41,41 spriteslice 3,200,200,35,35 print "sprites made" pause 1 # layout screen color yellow rect 0,0,300,300 # move sprites to initial location and show spritemove 0,100,100 spriteshow 0 pause .5 spritemove 1,200,200 spriteshow 1 pause .5 spritemove 2,100,200 spriteshow 2 pause .5 spritemove 3,200,100 spriteshow 3 pause .5 for i = 0 to 3 dx[i] = rand * 5 dy[i] = rand * 5 next i while true for i = 0 to 3 if spritex(i) + spritew(i) / 2 >= 300 or spritex(i) - spritew(i) / 2 <= 0 then dx[i] = dx[i] * -1 if spritey(i) + spriteh(i) / 2 >= 300 or spritey(i) - spriteh(i) / 2 <= 0 then dy[i] = dy[i] * -1 spritemove i, dx[i], dy[i] next i end while Examples/sprites/spritetest1.kbs0000664000175000017500000000060611675357446015463 0ustar jimjim# spritetest1.kbs - move three sprites # 2020-06-13 j.m.reneau rect 0,0,300,300 fastgraphics spritedim 3 spriteload 0, "help.png" spriteplace 0,100,100 spriteshow 0 spriteload 1, "help.png" spriteplace 1,100,100 spriteshow 1 spriteload 2, "help.png" spriteplace 2,100,100 spriteshow 2 for t = 1 to 100 spritemove 0, 1, 0 spritemove 1, 0, 1 spritemove 2, 1, 1 refresh next t Examples/sprites/paddle.png0000664000175000017500000000061511675357446014432 0ustar jimjimPNG  IHDRW sRGBgAMA a pHYsodbKGDtIME 8*}xtEXtCommentCreated with The GIMPd%nIDATXGM@0-rXW $ ۵ VE&hEpS\'AB a(\H$5"R~Yhj2_Drp.ng pCJAБ́8f$YR~np)`!:z1BK|qx}-NДW hP\JCv)vUi`0IENDB`Examples/sprites/test.bmp0000664000175000017500000102343611675357446014161 0ustar jimjimBM'6(--&6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/$$$$$$$$$$$6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/$$$$$$$$$$$$$$$$$$6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/$$$$$$$$$$$$$$$$$$$$6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/$$$$$$$$$$$$$$$$$$$$$$$$6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/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^𿣶⺗F˸ۿʾZ­7λ!vyMǽ'Ծ༞>,ǽj7dc­$ºX—7 i1’^ë¼KÿÄIÈ`[į|5ĀĿH#[ŁŪœŋśźŻI}^Gcƻxhbǂǣ!$CabȈșȗȜȻ,DɿXn$̪{z\GiLhP<=oP^ZJ2BIVYPEFPWUSrIELS@TLFHOPSOIGKYPOUJ GHMNJF~FIKtJGSEF)IqIFDDcFGXFC3C!DEGECAMBmCCB2A@CAAAA@d??3@?@S?]>)>|>> > =<<<<;};S;`;l;:):9999 98R8@86877666b65}55Z5*54_44343.322b2A21r1?1"100h0//m/0//.o. .--X--,,7,,++s++**G*)))<)9)((a(('' '{&%$%$$<"*G~аaB)ֶZG՛Q/!ޢqۂ%U2ݽPߊ߉&<e.%pUy{Q~nWu1 &KKIymYcv(jR2K$(Q7{+SM&r%FR)bBm O=vt5 ~i;;8(!=A.5' ;7*U0!DDODV#D ! =0$    ~oruun{ei~}rynXCB-X[nP :S6Z>K5KRd8kck\QM?;E4B76E)+ 3]/1hC??4*4&G3),6E(/626'd*9J?PW-W-( 6((:/CN<- "B?4:)( ' 9#"%0(E$9$2* 5L0 4 '#$  *   [FC10"",%#( " xjm`qw{qn|[~t_}qe~{~z{zvuk}j;Txcjm{ftZappk\u^~lh~ZlbldddkY~`}gU,xp{WaL{a[On]H]G]=&lYG1<#n\jXbI[fPL=)PW7SLDShhzVV\GYZYuf15bMDkCjTupi[3bteW;6]ohnh@.<YY.C.1\[;f__QI1BMm46eSP!=O6:S:G++K'R`gU@NUN8?)1M#XPWb??QZOP>H: 2 6$*/@)114;"07$A,%KHZ:OKD=OR2D5K`dJkF7[?,,?-Fq>,P9PEL!+H=R]aHQgD9 IT&"&<u1C"/= $!# .< ""-)3"$ (!$H2CU2@# "#  4  (' .(1* %,4((:9=  5  #.*CN-, !:S0=6S9  9#;)&   'qixqveQ[p~{zwt]khLcVSMTK)smpl<X<% Examples/sprites/help.png0000664000175000017500000000065511675357446014135 0ustar jimjimPNG  IHDRw=sRGBbKGD pHYs  tIME 8*}xtEXtCommentCreated with The GIMPd%nIDATHǽ;0 ?G1q .K1X S-Xx t0CCmKTmNGKhM@0-ڂmOA\ԗө J9`^ aQEjK7`RsGozsˉ>jUL nY~ kl[lzм )>.Ya?D5l|& ZGL Hbk8ˮi\V=JQF(Cg Ǒ55YNIENDB`Examples/trig.kbs0000664000175000017500000000045411675357447012452 0ustar jimjimclg fastgraphics for x = 1 to 4 * 3.14159 step 0.05 y = sin(x) plot int(20*x), 150 + int(30*y) next x refresh for x = 1 to 4 * 3.14159 step 0.05 y = cos(x) plot int(20*x), 150 + int(30*y) next x refresh for x = 1 to 4 * 3.14159 step 0.01 y = tan(x) plot int(20*x), 150 + int(30*y) next x refreshExamples/ping.kbs0000664000175000017500000000201311675357447012433 0ustar jimjimprint "Use the J and K keys to move the paddle" fastgraphics x = 30 y = 280 ballx = 30 bally = 0 ballxinc = 5 ballyinc = 5 xinc = 5 speed = .04 ## make speed smaller to play faster loop1: a = key if a = 75 then x = x + 30 if a = 74 then x = x - 30 if x < 0 then x = 0 if x > 200 then x = 200 gosub drawpaddle gosub moveball gosub drawball refresh goto loop1 drawpaddle: color gray rect 0,0,300,300 color darkblue rect x,y,100,10 color blue rect x+1,y+1,98,8 return moveball: ballx = ballx + ballxinc bally = bally + ballyinc if bally > 270 then gosub checkball if bally < 5 then ballyinc = -ballyinc if ballx > 295 then ballxinc = -ballxinc if ballx < 5 then ballxinc = -ballxinc pause speed return checkball: if ballx < x - 3 then goto missed if ballx > (x + 103) then goto missed ballyinc = -ballyinc ballxinc = ((ballx - x) - 50) / 10 return missed: print "You Missed!!" bally = 10 return drawball: color black circle ballx, bally, 5 color white circle ballx, bally, 4 return Examples/errortrapping.kbs0000664000175000017500000000065011675357447014401 0ustar jimjim# test error trapping onerror nicetrap print 1 next haha print 2 open 999, "bogus.file" print "Runs Anyway" # test error trapping off and fail at any error (default) offerror print 3 next hoho print "never get here" end nicetrap: # this is the nice error handler print "trap and run - error on line " + lasterrorline + " - error number " + lasterror + " message " + lasterrormessage + " (" + lasterrorextra + ")" return Examples/15puzzle.kbs0000664000175000017500000000535111675357447013205 0ustar jimjim# 15puzzle.kbs - slide the tiles to get them back in order # 2010-01-14 j.m.reneau fastgraphics nx = 4 # number of boxes in a row ny = 4 # number of boxes in a column bw = 5 # border width xw = (graphwidth - ((nx+1)*bw)) / nx # calculate size of a box yw = (graphheight - ((ny+1)*bw)) / ny zx = 0 # position of the empty tile zy = 0 dim board(nx, ny) font "Tahoma", 120/nx, 100 print "slide puzzle" print "click on tile to slide. try to get all tiles in order." print "shufflle..." gosub initialboard gosub shuffle gosub drawboard clickclear moves = 0 print "click tile to move" do gosub getclick gosub makemove gosub drawboard gosub isdone until done print "Game Over - You solved it in "+ moves +"." end shuffle: # for t = 1 to nx * ny * 10 cx = zx cy = zy r = int(rand*4) if r = 0 and cx > 0 then cx = cx - 1 if r = 1 and cx < nx-1 then cx = cx + 1 if r = 2 and cy > 0 then cy = cy - 1 if r = 3 and cy < ny-1 then cy = cy + 1 if cx<>zx or cy<> zy then board[zx, zy] = board[cx, cy] board[cx, cy] = 0 zx = cx zy = cy end if gosub drawboard pause .01 next t return makemove: # # shift cells if (zx = cx) or (zy = cy) then moves = moves + 1 if zx<>cx then # row shift if cx>zx then dx = 1 dy = 0 else dx = -1 dy = 0 end if else # column shift if cy>zy then dx = 0 dy = 1 else dx = 0 dy = -1 end if end if # do shift while zx <> cx or zy <> cy board[zx, zy] = board[zx+dx, zy+dy] board[zx+dx, zy+dy] = 0 zx = zx + dx zy = zy + dy end while endif return getclick: # # return cx and cy for where the user clicked the board while clickb = 0 pause .01 end while cx = int(clickx/(xw+bw)) if cx >= nx then cx = nx-1 cy = int(clicky/(yw+bw)) if cy >= ny then cy = ny-1 clickclear return initialboard: # # setup the initial board array for x= 0 to nx-1 for y = 0 to ny-1 board[x, y] = (y*nx+x+1) next y next x zx = nx-1 zy = ny-1 board[zx, zy] = 0 return isdone: # # return the variable done if we have solved the puzzle done = true for x= 0 to nx-1 for y = 0 to ny-1 if board[x, y] <> (y*nx+x+1) and (x <> zx or y <> zy) then done = false return end if next y next x return drawboard: # clg color black rect 0, 0, graphwidth, graphheight for y = 0 to ny-1 for x = 0 to nx-1 b = board[x, y] color white rect (x+1)*bw+x*xw, (y+1)*bw+y*yw ,xw, yw if b <> 0 then if zx = x or zy = y then color blue else color darkblue endif text (x+1)*bw+x*xw, (y+1)*bw+y*yw, b end if next x next y refresh return Examples/stamp.kbs0000664000175000017500000000076711675357447012640 0ustar jimjimclg dim a(6) a[0] = 0 a[1] = 0 a[2] = 20 a[3] = 20 a[4] = 15 a[5] = 10 color black for x = 0 to 200 step 20 for y = 0 to 200 step 20 s = rand * 5 stamp x, y, s, a next y next x color blue for x = 0 to 200 step 20 for y = 0 to 200 step 20 s = rand * 5 color green stamp x, y, 5, {0,0,20,20,15,10} color yellow stamp x, y, {0,0,20,20,15,10} color blue stamp x, y, 5, rand * 2 * pi, {0,0,20,20,15,10} next y next x Examples/card_suites.kbs0000664000175000017500000000117711675357447014015 0ustar jimjim# 2009-12-20 j.m.reneau # draw an animation of the four card suites # # shapes of the card suits dim diamond(8) diamond = {0, 2.5, 2, 0, 4, 2.5, 2, 5} dim heart(12) heart = {0, 1, 1, 0, 2, 1, 3, 0, 4, 1, 2, 5} dim spade(18) spade = {0, 3, 2, 0, 4, 3, 4, 4, 2, 3, 3, 5, 1, 5, 2, 3, 0, 4} dim club(30) club = {0, 1, 1, 0, 2, 1, 3, 0, 4, 1, 3, 2, 4, 3, 3, 4, 2, 3, 3, 5, 1, 5, 2, 3, 1, 4, 0, 3, 1, 2} fastgraphics for i = 0 to 200 z = i / 10 r = 2 * pi * i / 100 clg color red stamp 50,50,z,r,diamond stamp 150,150,z,r,heart color black stamp 150,50,z,r,spade stamp 50,150,z,r,club refresh pause .001 next i Examples/databasefoo.kbs0000664000175000017500000000144611675357447013757 0ustar jimjim#database foo - create a database, populate a table, open a recordset and read data from table. # create a new database file or open it dbopen "dbtest.sqlite3" # delete old foo table - trap error if new database onerror errortrap dbexecute "drop table foo;" offerror # create and populate dbexecute "create table foo (id integer, words text, value decimal);" dbexecute "insert into foo values (1,'one',3.14);" dbexecute "insert into foo values (2,'two',6.28);" dbexecute "insert into foo values (3,'three',9.43);" # open a recordset and loop through the rows of data dbopenset "select * from foo order by words;" while dbrow() print dbint(0) + dbstring(1) + dbfloat(2) end while dbcloseset # wrap everything up dbclose end errortrap: # accept error - display nothing - return to next statement returnExamples/snowflakes.kbs0000664000175000017500000000263511675357447013664 0ustar jimjim# Snowflakes # for BASIC-256 on the basis of the program Ted Felix # by Sergey Irupin (lamp@altlinux.org), 10-dec-2010 # Like real snowflakes, each one is unique XCenter = graphwidth() / 2 YCenter = graphheight() / 2 Pi3 = pi / 3 # 60 degrees RLimit = YCenter fastgraphics do # clear graphics window color darkblue rect 0,0,graphheight(),graphwidth() color white # get the number of lines in the snowflake Total = rand * 15 + 5 # for each line for Cnt = 1 to Total # Pick two random points in polar coordinates r1 = rand * RLimit t1 = rand * Pi3 r2 = rand * RLimit t2 = rand * Pi3 # compute the mirror image of those points in the 60 degree sector mt1 = Pi3 - t1 mt2 = Pi3 - t2 # for each 60 degree sector around the circle for I = 0 to 5 # draw the line t1i = t1 + (I * Pi3) t2i = t2 + (I * Pi3) x1 = r1*cos(t1i) y1 = r1*sin(t1i) x2 = r2*cos(t2i) y2 = r2*sin(t2i) line (x1+XCenter, y1+YCenter, x2+XCenter, y2+YCenter) # draw the mirror image line within the 60 degree sector mt1i = mt1 + (I * Pi3) mt2i = mt2 + (I * Pi3) x1 = r1*cos(mt1i) y1 = r1*sin(mt1i) x2 = r2*cos(mt2i) y2 = r2*sin(mt2i) line (x1+XCenter, y1+YCenter, x2+XCenter, y2+YCenter) next I next Cnt refresh pause 1 until falseExamples/mandelbrot.kbs0000664000175000017500000000135311675357447013633 0ustar jimjimrem Mandelbrot example thanks to Joel Kahn fastgraphics editvisible false outputvisible false graphsize 800,800 refresh kt=50:m=4.0 xmin=2.1:xmax=-0.6:ymin=-1.5:ymax=1.5 dx=(xmax-xmin)/graphwidth:dy=(ymax-ymin)/graphheight for x=0 to graphwidth jx=xmin+x*dx for y=0 to graphheight jy=ymin+y*dy k=0:wx=0.0:wy=0.0 MainCalculation: tx=wx*wx-(wy*wy+jx) ty=2.0*wx*wy+jy wx=tx wy=ty r=wx*wx+wy*wy k=k+1 if r<=m and k 5 then color darkblue if k > 10 then color blue if k > 15 then color darkgreen if k > 20 then color green if k > 25 then color darkred if k > 30 then color red if k > 35 then color darkpurple if k > 40 then color purple if k > 45 then color black plot x,y next y refresh next x Examples/uniformRV.kbs0000664000175000017500000000024111675357447013426 0ustar jimjimdim nums(301) for i = 1 to 1000000 x = int(rand * 300) nums[x] = nums[x] + 1 next i fastgraphics clg for x = 0 to 300 plot x, 60 + nums[x] / 100 next x refreshExamples/hello.kbs0000664000175000017500000000002611675357447012603 0ustar jimjim print "Hello World" Examples/plot.kbs0000664000175000017500000000033211675357447012456 0ustar jimjim for a = 1 to 100 plot a, a plot 21,a plot 27,a plot 18,a plot 14,a plot a, 21 plot a, 21 plot a, 27 plot a, 33 plot a, 18 plot a, 35 plot a, 37 plot a, 14 plot a, 33 plot a, 18 plot a, 35 plot a, 37 plot a, 14 next a Examples/polytest.kbs0000664000175000017500000000074511675357447013373 0ustar jimjim# polytest.kbs # draw polygons using arrays and direct lists clg color gray dim a(6) a[0] = 10 a[1] = 30 a[2] = 25 a[3] = 40 circle (5,5,15) color blue poly a # draw red one on top of the blue one pause 1 color red poly {10,30,24,40,0,0} pause 1 color blue for x = 45 to 55 step 5 poly {1/x, 2 * x, x-40, x + 30, 7, 8} next x # pause and overlay immediate with same polygon from array pause 1 color red a[0] = 1/x a[1] = 2 * x a[2] = x-40 a[3] = x + 30 a[4] = 7 a[5] = 8 poly a Examples/collision3.kbs0000664000175000017500000001036211675357447013562 0ustar jimjim# Collision # 3 "balls" reflect on the walls and can collide # see http://www.geocities.com/vobarian print "The return key ends the program." clg fastgraphics # graphics window size gwidth = 300 gheight = 300 graphsize gwidth,gheight # feel free to change the radius of the balls and their masses # radius r1 = 15 r2 = 15 r3 = 15 # masses m1 = r1*r1*r1 m2 = r2*r2*r2 m3 = r3*r3*r3 # initial positions and velocities x1 = rand * (gwidth - 2*r1) + r1 : y1 = r1 vx1 = 10*rand - 5 : vy1 = 3*rand x2 = rand * (gwidth - 2*r2) + r2 : y2 = gheight - r2 vx2 = 10*rand - 5 : vy2 = -3*rand x3 = rand * (gwidth - 2*r3) + r3 : y3 = gheight - r3*2 vx3 = 10*rand - 5 : vy3 = 6*rand kollision = 0 # do we have a collision (1 yes, 0 no) loopz: c = key() if c = 16777220 then goto ende clg gosub zeichne refresh #pause .01 gosub iskollision if kollision = 0 then goto m1 gosub getkollision gosub getnewpos m1: gosub wandball1 gosub wandball2 gosub wandball3 m2: gosub getnewpos goto loopz getnewpos: x1 = x1 + vx1 y1 = y1 + vy1 x2 = x2 + vx2 y2 = y2 + vy2 x3 = x3 + vx3 y3 = y3 + vy3 return iskollision: kollision = 0 if sqrt((x1 - x2) * (x1 - x2) + (y1 - y2) * (y1 - y2)) < r1 + r2 then kollision = 1 : sound 400,2 if sqrt((x1 - x3) * (x1 - x3) + (y1 - y3) * (y1 - y3)) < r1 + r3 then kollision = 2 : sound 400,2 if sqrt ((x2 - x3) * (x2 - x3) + (y2 - y3) * (y2 - y3)) < r2 + r3 then kollision = 3 : sound 400,2 return wandball1: if ( x1 > gwidth - r1 and vx1 > 0 ) or ( x1 < r1 and vx1 < 0 ) then vx1 = -vx1 if ( y1 > gheight - r1 and vy1 > 0 ) or ( y1 < r1 and vy1 < 0 ) then vy1 = -vy1 return wandball2: if ( x2 > gwidth - r2 and vx2 > 0 ) or ( x2 < r2 and vx2 < 0 ) then vx2 = -vx2 if ( y2 > gheight - r2 and vy2 > 0 ) or ( y2 < r2 and vy2 < 0 ) then vy2 = -vy2 return wandball3: if ( x3 > gwidth - r3 and vx3 > 0 ) or ( x3 < r3 and vx3 < 0 ) then vx3 = -vx3 if ( y3 > gheight - r3 and vy3 > 0 ) or ( y3 < r3 and vy3 < 0 ) then vy3 = -vy3 return getkollision: #normal vector un = unx, uny if kollision = 1 then s = sqr((x1-x2)*(x1-x2) + (y1-y2)*(y1-y2)) unx = (x2 - x1) / s uny = (y2 -y1) / s endif if kollision = 2 then s = sqr((x1-x3)*(x1-x3) + (y1-y3)*(y1-y3)) unx = (x3 - x1) / s uny = (y3 -y1) / s endif if kollision = 3 then s = sqr((x2-x3)*(x2-x3) + (y2-y3)*(y2-y3)) unx = (x3 - x2) / s uny = (y3 -y2) / s endif #tangential vector ut utx = -uny : uty = unx if kollision = 1 then #tangential velocities vt1, vt2 (skalar) vt1 = utx*vx1 + uty*vy1 vt2 = utx*vx2 + uty*vy2 #normal velocities vn1, vn2 (skalar) vn1 = unx*vx1 + uny*vy1 vn2 = unx*vx2 + uny*vy2 endif if kollision = 2 then #tangential velocities vt1, vt2 (skalar) vt1 = utx*vx1 + uty*vy1 vt2 = utx*vx3 + uty*vy3 #normal velocities vn1, vn2 (skalar) vn1 = unx*vx1 + uny*vy1 vn2 = unx*vx3 + uny*vy3 endif if kollision = 3 then #tangential velocities vt1, vt2 (skalar) vt1 = utx*vx2 + uty*vy2 vt2 = utx*vx3 + uty*vy3 #normal velocities vn1, vn2 (skalar) vn1 = unx*vx2 + uny*vy2 vn2 = unx*vx3 + uny*vy3 endif # 1-dimensional collision formulas for the normal # velocities after collision vn1n, vn2n # the tangential component of the velcities does not change vn1n =( (m1-m2)*vn1 + 2*m2*vn2 ) / (m1+m2) vn2n =( (m2-m1)*vn2 + 2*m1*vn1 ) / (m1+m2) # vectors after collision: tangential (vt1n,vt2n) and normal (vt1n,vt2n) vn1nx = unx * vn1n : vn1ny = uny * vn1n vn2nx = unx * vn2n : vn2ny = uny * vn2n vt1nx = utx * vt1 : vt1ny = uty * vt1 vt2nx = utx * vt2 : vt2ny = uty * vt2 # tangential and normal vector add to resulting velocities if kollision = 1 then vx1 = vt1nx + vn1nx : vy1 = vt1ny + vn1ny vx2 = vt2nx + vn2nx : vy2 = vt2ny + vn2ny endif if kollision = 2 then vx1 = vt1nx + vn1nx : vy1 = vt1ny + vn1ny vx3 = vt2nx + vn2nx : vy3 = vt2ny + vn2ny endif if kollision = 3 then vx2 = vt1nx + vn1nx : vy2 = vt1ny + vn1ny vx3 = vt2nx + vn2nx : vy3 = vt2ny + vn2ny endif return zeichne: color black rect 0,0,gwidth,gheight color clear rect 1,1,gwidth-2,gheight-2 color red circle x1,y1,r1 color blue circle x2,y2,r2 color green circle x3,y3,r3 return ende: print "Bye!" endExamples/mousedoodle.kbs0000664000175000017500000000116411675357447014023 0ustar jimjim# mousetest.kbs - 2009-12-21 j.m.reneau # click and doodle on the graphics output cls print "doodle on the graphic output with your mouse" print "left button to draw in black" print "right button to draw in crazy colors" print "right and left button to erase" clg color white rect 0,0,graphwidth, graphheight loop: if mouseb = 1 then gosub blackline if mouseb = 2 then gosub randomline if mouseb = 3 then gosub clearline goto loop blackline: color black circle mousex, mousey, 2 return randomline: color rand*256, rand*256, rand*256 circle mousex, mousey, 2 return clearline: color clear circle mousex, mousey, 2 return Examples/ballanim.kbs0000664000175000017500000000104311675357447013257 0ustar jimjimprint "Bouncing Ball Animation" rem set up initial position for ball, and its speed x = 10 y = 10 r = 10 xinc = 5 yinc = 4 moveBall: x = x + xinc y = y + yinc rem This is where we check for collisions with the wall if y > 280 then yinc = -yinc : sound(440, 50) if x > 280 then xinc = -xinc : sound(440, 50) if x < 14 then xinc = -xinc : sound(440, 50) if y < 14 then yinc = -yinc : sound(440, 50) rem clear the screen, then draw the ball clg gosub drawBall goto moveBall drawBall: color black circle x, y, r returnExamples/imgload/0000775000175000017500000000000011675357446012414 5ustar jimjimExamples/imgload/animatedhelp.kbs0000664000175000017500000000070211675357446015547 0ustar jimjim# animatedhelp.kbs - show another use of imgload clg fastgraphics imgload 150,150,"test.bmp" x = 50 y = 50 r = 0 while true x = x + rand * 10 y = y + rand * 10 r = r + rand * .2 if x < 0 then x = graphwidth if x > graphwidth then x = 0 if y < 0 then y = graphheight if y > graphheight then y = 0 save$ = getslice(x-15,y-15,30,30) imgload x, y, 1, r, "help.png" refresh pause .05 putslice x-15,y-15,save$ end while Examples/imgload/rotate.kbs0000664000175000017500000000043411675357446014414 0ustar jimjim# rotate.kbs - show imgload statement with rotate and scale clg imgload 150,150,"test.bmp" for t = 1 to 50 imgload graphwidth*rand, graphheight*rand, 1 + t/10, "help.png" next t a = 0 for t = 0 to 50 imgload 150, 150, t / 5 , 2 * pi / (t / 50), "help.png" pause .01 next t Examples/imgload/imgload.kbs0000664000175000017500000000041511675357446014531 0ustar jimjim# imgload.kbs - show basic use of the imgload statement clg imgload 150,150,"test.bmp" for t = 1 to 10 imgload graphwidth*rand, graphheight*rand, "help.png" next t # scale by zero - no display imgload 100,100,0, "help.png" # this will error imgload 0,0,"crap.gif" Examples/imgload/test.bmp0000664000175000017500000102343611675357446014104 0ustar jimjimBM'6(--&6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/$$$$$$$$$$$6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/$$$$$$$$$$$$$$$$$$6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/$$$$$$$$$$$$$$$$$$$$6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/6/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L"L"L"L"L"L"L"L"L"L"L"L"L"L"L"L"L"L"L"L"L"L"L"L"L"L"L"L"L"L"L"L"jUL nY~ kl[lzм )>.Ya?D5l|& ZGL Hbk8ˮi\V=JQF(Cg Ǒ55YNIENDB`Examples/moving_squares.kbs0000664000175000017500000000107311675357447014545 0ustar jimjimrem Moving Squares thanks to Joel Kahn clg x1=150 y1=150 q=0.055 m=0.0 SquaresLoop: m=m+q x1=x1+4.0*cos(m) y1=y1+4.0*sin(m) x2=300-x1 y2=300-y1 x3=x1/2.0 y3=y1/2.0 x4=300-x3 y4=300-y3 color purple line x1,y1,x2,y1 color orange line x1,y1,x1,y2 color darkpurple line x1,y2,x2,y2 color darkorange line x2,y1,x2,y2 color blue line x3,y3,x1,y1 color darkblue line x2,y2,x4,y4 color cyan line x3,y4,x1,y2 color darkcyan line x2,y1,x4,y3 color green line x3,y3,x3,y4 color red line x3,y3,x4,y3 color darkgreen line x4,y3,x4,y4 color darkred line x3,y4,x4,y4 goto SquaresLoop Examples/tictactoe.kbs0000664000175000017500000000403711675357447013465 0ustar jimjim# tictactoe - simple tic tac toe board # 2009-12-23 - j.m.reneau # requires BACIC256 0.9.4f or better # 0=empty 1=x, 2=0 fastgraphics dim board(9) board = {0,0,0,0,0,0,0,0,0} gosub drawboard player = 1 playerloop: print "player "; if player = 1 then print "X"; if player = 2 then print "O"; print " please click on cell." clickclear playerwaitclick: pause .1 if clickb = 0 then goto playerwaitclick # what cell did they click on i = int(clickx/100) + int(clicky/100)*3 # if it is not empty then wait again if board[i] <> 0 then goto playerloop # set cell and display board[i] = player gosub drawboard # see if there is a winner and if not go to next player and wait gosub iswinner player = player + 1 if player > 2 then player = 1 if winner = 0 then goto playerloop # we must have a winner print "The winner was "; if winner = -1 then print "cat" if winner = 1 then print "X" if winner = 2 then print "O" end iswinner: # # is there a winner = return winner - 0 if ther game continues # winner = 1 for X, winner=2 for Y, winner=-1 for cat for winner = 1 to 2 # check columns for t = 0 to 2 if board[0+t] = winner and board[3+t] = winner and board[6+t] = winner then return next t # check rows for t = 0 to 2 if board[3*t] = winner and board[3*t+1] = winner and board[3*t+2] = winner then return next t # check diagonals if board[0] = winner and board[4] = winner and board[8] = winner then return if board[2] = winner and board[4] = winner and board[6] = winner then return next winner # check for empty square winner = 0 for t = 0 to 8 if board[t]=0 then return next t # must be a cat winner = -1 return drawboard: # clg color black rect 0,95,300,10 rect 0,195,300,10 rect 95,0,10,300 rect 195,0,10,300 # font "Tahoma",50,100 # draw X and O for t = 0 to 8 if board[t]=1 then text ((t % 3)*100)+25, (int(t/3)*100)+10, "X" if board[t]=2 then text ((t % 3)*100)+25, (int(t/3)*100)+10, "O" next t refresh return Examples/stamp_flower.kbs0000664000175000017500000000057711675357447014215 0ustar jimjimclg dim a(6) a[0] = 0 a[1] = 0 a[2] = 20 a[3] = 20 a[4] = 15 a[5] = 10 color yellow for r = 0 to (2 * pi) step (pi/32) stamp graphwidth/2, graphheight/2, 5, r, a next r color blue for r = 0 to (2 * pi) step (pi/16) stamp graphwidth/2, graphheight/2, 3, r, a next r color red for r = 0 to (2 * pi) step (pi/8) stamp graphwidth/2, graphheight/2, 1, r, a next r Examples/rainbow.kbs0000664000175000017500000000107411675357447013145 0ustar jimjimrem Rainbow example thanks to Joel Kahn clg fastgraphics m=-1.57:x1=1:y1=301 q=0.00101:gx=0.15:gy=0.3 for e=1 to 3107 m=m+q x1=x1+gx*cos(m):y1=y1+gy*sin(m) x2=(x1+150)/2:y2=(y1+300)/2 x3=(x1+x2)/2:y3=(y1+y2)/2 x4=(x2+150)/2:y4=(y2+300)/2 x5=(x1+x3)/2:y5=(y1+y3)/2 x6=(x2+x3)/2:y6=(y2+y3)/2 x7=(x2+x4)/2:y7=(y2+y4)/2 x8=(x4+150)/2:y8=(y4+300)/2 color red line x1,y1,x5,y5 color orange line x5,y5,x3,y3 color yellow line x3,y3,x6,y6 color green line x6,y6,x2,y2 color blue line x2,y2,x7,y7 color darkblue line x7,y7,x4,y4 color darkpurple line x4,y4,x8,y8 refresh next e Examples/quotations.kbs0000664000175000017500000000620211675357447013710 0ustar jimjim#quotations - create a database of quotations # create a new database file or open it or create it with a few good quotes dbfile$ = "quotations.sqlite3" e = exists(dbfile$) dbopen dbfile$ if (not e) then gosub createtable gosub getlastquote print "Database has " + lastquote + " quotes." menu: print "1 - view a random quote ** "; print "2 - list all quotes ** "; print "3 - add a quote ** "; print "0 - quit" input ">", choice if choice = 1 then gosub showquote if choice = 2 then gosub showall if choice = 3 then gosub addquote if choice <> 0 then goto menu # wrap everything up print "Good bye." dbclose end showquote: #### quote = 1 + int(rand * lastquote) dbopenset "select author, saying from quotes where id = " + quote + ";" while dbrow() print dbstring(1) print " - " + dbstring(0) end while dbcloseset return showall: #### dbopenset "select id, author, saying from quotes order by id;" while dbrow() print dbint(0) + " " + dbstring(2) + " (" + dbstring(1) + ")" end while dbcloseset return addquote: #### input "Quote>", quote$ input "Author>", author$ if quote$ = "" or author$ = "" then print "You must supply both a quote and an author to add." return end if lastquote = lastquote + 1 dbexecute "insert into quotes values (" + lastquote + ",'" + author$ + "','" + quote$ + "');" print "Quote " + lastquote + " added." return getlastquote: ###### # find the last quote number and set the variable lastquote lastquote = 0 dbopenset "select max(id) from quotes" while dbrow() lastquote = dbint(0) end while dbcloseset return createtable: ######## dbexecute "create table quotes (id integer primary key, author text, saying text);" dbexecute "insert into quotes values (1,'Abraham Lincoln (1809 - 1865)','Most folks are about as happy as they make up their minds to be.');" dbexecute "insert into quotes values (2,'George Burns (1896 - 1996)','Happiness is having a large, loving, caring, close-knit family in another city.');" dbexecute "insert into quotes values (3,'Jean Houston','At the height of laughter, the universe is flung into a kaleidoscope of new possibilities.');" dbexecute "insert into quotes values (4,'Doug Larson', 'Home computers are being called upon to perform many new functions, including the consumption of homework formerly eaten by the dog.');" dbexecute "insert into quotes values (5, 'Isaac Asimov', 'I do not fear computers. I fear the lack of them.');" dbexecute "insert into quotes values (6, 'Pierre Gallois', 'If you put tomfoolery into a computer, nothing comes out of it but tomfoolery. But this tomfoolery, having passed through a very expensive machine, is somehow ennobled and no-one dares criticize it.');" dbexecute "insert into quotes values (7, 'Robert Orben', 'To err is human--and to blame it on a computer is even more so.');" dbexecute "insert into quotes values (8, 'Herm Albright (1876 - 1944)', 'A positive attitude may not solve all your problems, but it will annoy enough people to make it worth the effort.');" dbexecute "insert into quotes values (9, 'William James (1842 - 1910)', 'The greatest discovery of my generation is that a human being can alter his life by altering his attitudes of mind.');" returnFindWin.cpp0000664000175000017500000000611411675357462011264 0ustar jimjim/** Copyright (C) 2010, J.M.Reneau ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License along ** with this program; if not, write to the Free Software Foundation, Inc., ** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. **/ #include using namespace std; #include "FindWin.h" #include "Settings.h" #include "MainWindow.h" #include "md5.h" FindWin::FindWin (QWidget * parent) { // parent must be basicedit be = (BasicEdit *) parent; // position where it was last on screen QSettings settings(SETTINGSORG, SETTINGSAPP); move(settings.value(SETTINGSFINDPOS, QPoint(200, 200)).toPoint()); setWindowTitle(tr("BASIC-256 Find")); QGridLayout * layout = new QGridLayout(); int r=0; searchforlabel = new QLabel(tr("Search For:"),this); layout->addWidget(searchforlabel,r,1,1,1); searchforinput = new QLineEdit(settings.value(SETTINGSFINDSTRING, "").toString()); searchforinput->setMaxLength(100); connect(searchforinput, SIGNAL(textChanged(QString)), this, SLOT (changeSearchForInput(QString))); layout->addWidget(searchforinput,r,2,1,2); // r++; casecheckbox = new QCheckBox(tr("Case Sensitive"),this); casecheckbox->setChecked(settings.value(SETTINGSFINDCASE, SETTINGSFINDCASEDEFAULT).toBool()); layout->addWidget(casecheckbox,r,2,1,2); // r++; backcheckbox = new QCheckBox(tr("Search Backwards"),this); backcheckbox->setChecked(settings.value(SETTINGSFINDBACK, SETTINGSFINDBACKDEFAULT).toBool()); layout->addWidget(backcheckbox,r,2,1,2); // r++; cancelbutton = new QPushButton(tr("Close"), this); connect(cancelbutton, SIGNAL(clicked()), this, SLOT (clickCancelButton())); layout->addWidget(cancelbutton,r,2,1,1); findbutton = new QPushButton(tr("Find"), this); connect(findbutton, SIGNAL(clicked()), this, SLOT (clickFindButton())); layout->addWidget(findbutton,r,3,1,1); this->setLayout(layout); this->show(); changeSearchForInput(searchforinput->text()); } void FindWin::changeSearchForInput(QString t) { findbutton->setEnabled(t.length() != 0); } void FindWin::clickCancelButton() { close(); } void FindWin::clickFindButton() { saveSettings(); be->findString(searchforinput->text(), backcheckbox->isChecked(), casecheckbox->isChecked()); } void FindWin::closeEvent(QCloseEvent *e) { saveSettings(); } void FindWin::saveSettings() { QSettings settings(SETTINGSORG, SETTINGSAPP); settings.setValue(SETTINGSFINDPOS, pos()); settings.setValue(SETTINGSFINDSTRING, searchforinput->text()); settings.setValue(SETTINGSFINDCASE, casecheckbox->isChecked()); settings.setValue(SETTINGSFINDBACK, backcheckbox->isChecked()); } FindWin.h0000664000175000017500000000301011675357462010721 0ustar jimjim/** Copyright (C) 2011, J.M.Reneau. ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License along ** with this program; if not, write to the Free Software Foundation, Inc., ** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. **/ #include #include #include #include #include #include #include #include #include #include #include #include #include #include "BasicEdit.h" #ifndef FINDWINH #define FINDWINH class FindWin : public QDialog { Q_OBJECT; public: FindWin(QWidget *); void closeEvent(QCloseEvent *); private slots: void changeSearchForInput(QString); void clickCancelButton(); void clickFindButton(); private: void saveSettings(); BasicEdit * be; QLabel *searchforlabel; QLineEdit *searchforinput; QCheckBox *casecheckbox; QCheckBox *backcheckbox; QPushButton *cancelbutton; QPushButton *findbutton; }; #endif GhostButton.cpp0000664000175000017500000000176011675357462012210 0ustar jimjim/** Copyright (C) 2006, Ian Paul Larsen. ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License along ** with this program; if not, write to the Free Software Foundation, Inc., ** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. **/ #include "GhostButton.h" GhostButton::GhostButton(QString text) : QPushButton(text) { } void GhostButton::disableButton() { setEnabled(false); } void GhostButton::enableButton() { setEnabled(true); } GhostButton.h0000664000175000017500000000200111675357462011642 0ustar jimjim/** Copyright (C) 2006, Ian Paul Larsen. ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free Software Foundation; either version 2 of the License, or ** (at your option) any later version. ** ** This program is distributed in the hope that it will be useful, ** but WITHOUT ANY WARRANTY; without even the implied warranty of ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ** GNU General Public License for more details. ** ** You should have received a copy of the GNU General Public License along ** with this program; if not, write to the Free Software Foundation, Inc., ** 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. **/ #ifndef __GHOSTBUTTON #define __GHOSTBUTTON #include class GhostButton : public QPushButton { Q_OBJECT; public: GhostButton(QString); public slots: void disableButton(); void enableButton(); }; #endif help/0000775000175000017500000000000011722477272010143 5ustar jimjimhelp/fr/0000775000175000017500000000000011675357461010556 5ustar jimjimhelp/fr/whileendwhile.html0000664000175000017500000000160411722507477014272 0ustar jimjim
whileendwhile

While / End While

Format

while booleanexpression
statement(s)
end while

Description

Execute the statement(s) inside the while loop until the booleanexpression evaluates to false. While / End While executes the statements zero or more times. The test is done before the code in the loop is executed.

See Also

Do / Until, For / Next

Example

r = 1
while r < 6
  print r
  r = r + 1
end while
will display
1
2
3
4
5

New To Version

0.9.4g help/fr/degrees.html0000664000175000017500000000125111722507500013041 0ustar jimjim
degrees

Degrees

Format

degrees ( expression )

Description

 radians.png Convertis un angle en radians en degrés.

Voir aussi

Acos, Asin, Atan, Cos, Radians, Sin, Tan help/fr/log10.html0000664000175000017500000000074211722507477012366 0ustar jimjim
log10

Log10

Format

log10 ( expression )

Description

Return the base 10 lograthim of expression.

See Also

Log

New To Version

0.9.5w help/fr/redim.html0000664000175000017500000000156211722507477012545 0ustar jimjim
redim

Redim

Format

redim numericvariable( integer )
redim stringvariable$( integer )
redim numericvariable( rows , columns )
redim stringvariable$( rows , columns )

Description

Re-sizes a previously created array, preserving data. If an array is enlarged then the new elements will be initialized with zero or the empty string. If an array is reduced in size the elements trimmed from the end are lost.

See Also

Dim

New To Version

0.9.5t help/fr/rect.html0000664000175000017500000000140511722507500012361 0ustar jimjim
rect

Rect

Format

rect x,y,width,height
rect ( x, y, width, height )

Description

Draws a width x height pixel rectangle using the current color. The top left corner is located at x,y.

Example

color white
rect 0,0,300,300
color red
rect 50,50,150,150
color blue
rect 100,100,150,150
color green
rect 10,140,280,20
draws
rect.png help/fr/netread.html0000664000175000017500000000167011722507500013052 0ustar jimjim
netread

NetRead

Format

netread
netread ( )
netread ( socket_number )

Description

Read data from the specified network connection and return it as a string. This function will wait until data is received. If socket_number is not specified socket number zero (0) will be used.

Example

See example of usage on NetConnect page.

See Also

NetClose, NetConnect, NetData, NetListen, NetWrite

New To Version

0.9.6.31 help/fr/length.html0000664000175000017500000000060711722507500012710 0ustar jimjim
length

Length

Format

length( string )

Description

Returns the number of characters in string help/fr/mouseb.html0000664000175000017500000000202111722507500012711 0ustar jimjim
mouseb

Mouseb

Format

mouseb
mouseb()

Description

Returns the buttons that currently pressed on the mouse (if over the graphic output). Returns 0 if no click has been recorded. If multiple buttons have been pressed the value is the sum of the values for all pressed buttons.
Return Values
ValueMouse Button Pressed
0None
1Left
2Right
4Center

See Also

Clickb, Clickclear, Clickx, Clicky, Mousex, Mousey

New To Version

0.9.4d help/fr/spriteplace.html0000664000175000017500000000230611722507477013755 0ustar jimjim
spriteplace

Spriteplace

Format

spriteplace spritenumber, x, y
spriteplace ( spritenumber, x, y )

Description

Place the center of a sprite at a specific location on the screen. Like Imgload sprite positioning is relative to the center of the sprite and not the top left corner as with most other graphical statements.

See Also

Spritecollide, Spritedim, Spriteh, Spritehide, Spriteload, Spritemove, Spriteshow, Spriteslice, Spritev, Spritew, Spritex, Spritey

New To Version

0.9.6n help/fr/pause.html0000664000175000017500000000100711722507500012537 0ustar jimjim
pause

Pause

Format

pause seconds
pause (seconds)

Description

Halts execution for the specified number of seconds. The seconds value may be a decimal value, so sub-second precision is possible. help/fr/poly.png0000664000175000017500000000160111722507477012242 0ustar jimjimPNG  IHDR,,"sRGB pHYs  tIMEU3tEXtCommentCreated with GIMPWIDATxՁ 1w1؎@ra8gD"D"D"D"D"D"D"D"D"D"D"D"D"D"D"D"D"D"D"D"D"D"D"D"D"D"D"D"D"D"D"D""""""""""""""""""cDCD!:D:DCDCD!:D:DCDCD!:D:DCDCD!:D:DCDCD!:D:DCDCDE!:!:DPCCDE!:!:DPCCDE!:!:DPCCDE!:!:DPCCDE!:!:DPCCDE!:!:DPCCDE!:!:DPCCDE!:$xB! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! Bx8iUpIENDB`help/fr/spritev.html0000664000175000017500000000160611722507477013140 0ustar jimjim
spritev

Spritev

Format

spritev ( spritenumber )

Description

Returns true if the sprite is visible.

See Also

Spritecollide, Spritedim, Spriteh, Spritehide, Spriteload, Spritemove, Spriteplace, Spriteshow, Spriteslice, Spritex, Spritey

New To Version

0.9.6o help/fr/graphheight.html0000664000175000017500000000106611722507500013721 0ustar jimjim
graphheight

Graphheight

Format

graphheight
graphheight()

Description

Returns the height (y dimension) of the current graphics display window.

See Also

Graphsize, Graphwidth

New To Version

0.9.3 help/fr/spritecollide.html0000664000175000017500000000227211722507500014271 0ustar jimjim
spritecollide

Spritecollide

Format

spritecollide ( sprite1, sprite2)

Description

Function returns true if the two sprites are colliding. The Spritecollide function assumes that the sprites are bounded by a rectangle the size of the loaded image. Collision is calculated by using these rectangles. For round or oddly shaped sprites this function may over detect collision.

See Also

Spritedim, Spriteh, Spritehide, Spriteload, Spritemove, Spriteplace, Spriteshow, Spriteslice, Spritev, Spritew, Spritex, Spritey

New To Version

0.9.6n help/fr/spriteload.html0000664000175000017500000000256411722507500013601 0ustar jimjim
spriteload

Spriteload

Format

spriteload spritenumber, filename
spriteload ( spritenumber, filename )

Description

Load an image or picture from a file and save it as a sprite. The sprite will be active and movable but will not display on the screen until the Spriteshow statement is executed for that sprite.
The Spriteload statement will read in most common image file formats including: BMP (Windows Bitmap), GIF (Graphic Interchange Format),JPG/JPEG (Joint Photographic Experts Group), and PNG (Portable Network Graphics).

See Also

Spritecollide, Spritedim, Spriteh, Spritehide, Spritemove, Spriteplace, Spriteshow, Spriteslice, Spritev, Spritew, Spritex, Spritey

New To Version

0.9.6n help/fr/netlisten.html0000664000175000017500000000204111722507477013443 0ustar jimjim
netlisten

NetListen

Format

netlisten port_number
netlisten ( port_number)
netlisten socket_number, port_number
netlisten ( socket_number, port_number)

Description

Open up a network connection (server) on a specific port address and wait for another program to connect. If socket_number is not specified socket number zero (0) will be used.

Example

See example of usage on NetConnect page.

See Also

NetClose, NetConnect, NetData, NetRead, NetWrite

New To Version

0.9.6.31 help/fr/lasterrorline.html0000664000175000017500000000154211722507500014313 0ustar jimjim
lasterrorline

LastErrorLine

Format

lasterrorline
lasterrorline ( )

Description

Returns the line number in the program where the runtime error happened.

Example

See example of usage on Error Codes page.

See Also

Error Codes, Lasterror, Lasterrorextra, Lasterrormessage, Offerror, Onerror

New To Version

0.9.6z help/fr/mousex.html0000664000175000017500000000130511722507477012760 0ustar jimjim
mousex

Mousex

Format

mousex
mousex()

Description

Returns the current or last mouse x location of the mouse pointer over the graphic output.

See Also

Clickb, Clickclear, Clickx, Clicky, Mouseb, Mousey

New To Version

0.9.4d help/fr/color.png0000664000175000017500000000227611722507500012371 0ustar jimjimPNG  IHDR,,"sRGBbKGD pHYs  tIME8)0v>IDATxIr0@Q|Pnb&5TV`&M~oKIR AAAAAAAAAAAAAAAAAAAAAAAA)k/oyA;YM"N=M5"®N;"#G7 EFϴHY׺wQGIzq\1#BY5$T(B!BU"R"Fu(B@Fa(B"B+QEh:}G~zuz޹yr:› Hfaf{Ȫ8S04 M?Sj:v V/-{Tf,c>4PfyUCFd5kG*B3eJ6௖oms 鳇LK~ƠIh*~QwA0lf"pDh:vG"45&a@ZLjӭQJu\0zUZB?bkwg#9"̺h;f!c忘}+Y?HY"0E1IR#*֨=D8F! դ$y{ !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!DAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA B@ B@ B@ B@ B@ B@ B@ B@ B@_XdIENDB`help/fr/netwrite.html0000664000175000017500000000173111722507477013304 0ustar jimjim
netwrite

NetWrite

Format

netwrite string
netwrite ( string )
netwrite socket_number, string
netwrite ( socket_number, string )

Description

Send a string to the specified open network connection. If socket_number is not specified socket number zero (0) will be used.

Example

See example of usage on NetConnect page.

See Also

NetClose, NetConnect, NetData, NetListen, NetRead

New To Version

0.9.6.31 help/fr/dbopenset.html0000664000175000017500000000224511722507477013427 0ustar jimjim
dbopenset

DBClose

Format

dbopenset SqlStatement
dbopenset ( SqlStatement )

Description

Perform an SQL statement and create a record set so that the program may loop through and use the results.

Example

See example of usage on DBOpen page.

See Also

DBClose, DBCloseSet, DBExecute, DBFloat, DBInt, DBOpen, DBRow, DBString

External Links

More information about databases in general and SQLite specifically can be found at SQLite Home Page and SQL at Wikipedia.

New To Version

0.9.6y help/fr/putslice.html0000664000175000017500000000127211722507500013256 0ustar jimjim
putslice

PutSlice

Format

putslice x, y, slice$
putslice x, y, slice$, transparent color

Description

Put the graphics stored in the slice string on the screen at x,y. If a transparent color is specified then do not plot points of that color in the slice.

See Also

GetSlice

New To Version

0.9.6b help/fr/fastgraphics.html0000664000175000017500000000146711722507500014112 0ustar jimjim
fastgraphics

FastGraphics

Format

fastgraphics

Description

Turns fastgraphics mode on, until the program is halted. Fastgraphics mode means that the graphics display is not updated until a REFRESH command is issued. It can be used to significantly speed up complex animations and eliminate flicker.

Note

When doing animation, it's recommended to do all of your drawing commands in subroutines and use a single REFRESH command after all drawing has been done for that frame.

See Also

Refresh help/fr/ceil.html0000664000175000017500000000111211722507500012333 0ustar jimjim
ceil

Ceil

Format

ceil ( expression )

Description

REtourne l'entier immédiatement inférieur ou égal à une expression.

Voir aussi

Floor

Exemple

print ceil(9.1)
print ceil(-5.4)
fera afficher
10
-5
help/fr/acos.html0000664000175000017500000000123611722507500012353 0ustar jimjim
acos

Acos

Format

acos ( expression )

Description

Calcule l'arc-cosinus d'expression. Les angles sont exprimés en radians (0 à 2 pi).

Voir Aussi

Asin, Atan, Cos, Degrees, Radians, Sin, Tan help/fr/readline.html0000664000175000017500000000153511722507477013230 0ustar jimjim
readline

Readline

Format

readline
readline()
readline(filenumber)

Description

Reads and returns an entire line from an open file. If the file number is not specified file number zero (0) will be used.

See Also

Close, Eof, Open, Read, Reset, Write, Writeline, Exists, Seek, Size help/fr/cir.png0000664000175000017500000000537211722507500012030 0ustar jimjimPNG  IHDR,,"sRGBgAMA a cHRMz&u0`:pQ< xIDATx^ю P?:"p KBs'c~&p ?di@P@  ׏B"m !apQ!BH@X \U A!$@ ,.\?J8D@  A ( Gi!apCV6F!?}dPjxŏ,peBo. K6 U}9.P£5l_xl pmIE+*+oPrT'K_{2Vf?g ]%re|, Ymvr !
clickb

Clickb

Format

clickb
clickb ( )

Description

Retourne quel(s) bouton(s) de la souris l'utilisateur a pressé (quand il est sur la partie graphic output). Retourne 0 si aucun clic n'a été détecté. Si plusieurs boutons ont été pressés la valeur est la somme des valeurs des boutons pressés.
Valeurs retournées
ValeurBouton pressé
0aucun
1gauche
2droit
4du centre

Voir aussi

Clickclear, Clickx, Clicky, Mouseb, Mousex, Mousey

Exemple

# réinitialise le compte des clics
clickclear
# attend que l'utilisateur clique
print "cliquez avec la souris sur la surface graphics output"
while clickb = 0
  pause .01
endwhile
# Montre où l'utilisatur a cliqué
print "L'utilisateur a cliqué le point de coordonnées (" + clickx + "," + clicky + ")"

Disponible à partir de la version

0.9.4d help/fr/floor.html0000664000175000017500000000072511722507477012566 0ustar jimjim
floor

Floor

Format

floor ( expression )

Description

Returns the greatest integer that is less than or equal to expression

See Also

Ceil help/fr/rect.png0000664000175000017500000000171611722507500012206 0ustar jimjimPNG  IHDR,,y}usRGBbKGD pHYs  tIME6E|vNIDATxA 0QSOgeOPP4d&-u,@ @, @ ,,@ @, @ ,,@ ,,@ @, @ ,,@ @,_.9ɵ#iJ[{dĆ$, @ ,,@ @,@ @X;޹/gs9= I @ ,,@ @,@ @, @ ,,@ @, @ ,,@ @rqR ,,@ @,@ @, @ ,,@ @, @ ,,@ @,@ @, @ ,xZa` @ ,,@ ,,@ @, @ ,,@ @, @ ,,@ ,,@ @, @zIENDB`help/fr/spritemove.html0000664000175000017500000000212711722507477013640 0ustar jimjim
spritemove

Spritemove

Format

spritemove spritenumber, dx, dy
spritemove ( spritenumber, dx, dy )

Description

Move a sprite from its current position by the specified number of pixels. Motion will be limited to the current screen.

See Also

Spritecollide, Spritedim, Spriteh, Spritehide, Spriteload, Spriteplace, Spriteshow, Spriteslice, Spritev, Spritew, Spritex, Spritey

New To Version

0.9.6n help/fr/getcolor.html0000664000175000017500000000145411722507477013263 0ustar jimjim
getcolor

GetColor

Format

getcolor
getcolor()

Description

Returns the RGB value of the current drawing color (last set by color statement). RGB is calculated by taking ((red * 256) + green * 256) + blue where red, green, and blue are between 0 and 255. If the drawing color has been set to CLEAR a -1 will be returned.

See Also

Color, Rgb

Example

color red
print getcolor
will print
16711680

New To Version

0.9.5m help/fr/spriteslice.html0000664000175000017500000000301511722507477013766 0ustar jimjim
spriteslice

Spriteslice

Format

spriteslice spritenumber, x, y, width, height
spriteslice ( spritenumber, x, y, width, height )

Description

Copy the rectangular region of the screen with it's top left corner represented by x and y of the specified height and width and create a sprite. The sprite will be active and movable but will not be visible until the Spriteshow statement is executed. It is recommended that you execute the Clg command before drawing and slicing the sprite. All unpainted pixels will be transparent when the sprite is drawn on the screen. Transparent pixels may also be set by drawing with the color CLEAR.

See Also

Spritecollide, Spritedim, Spriteh, Spritehide, Spritemove, Spriteplace, Spriteshow, Spritev, Spritew, Spritex, Spritey

New To Version

0.9.6o help/fr/rem.html0000664000175000017500000000077711722507477012237 0ustar jimjim
rem

Rem

Format

rem commentaire
# commentaire

Description

Ligne de commentaire pour aider à comprendre le code. Une ligne qui commence par rem ou par # est ignorée par BASIC-256. help/fr/font.html0000664000175000017500000000166011722507500012375 0ustar jimjim
font

Font

Format

font fontname, point, weight

Description

Sets the font used by the text command to fontname. Size is defined in points (1/72") Weight represents a number from 1 to 100 that defines how dark the letters will be drawn. Light=25, Normal=50, and Bold=75.

Example

color grey
rect 0,0,graphwidth,graphheight
color red
font "Times New Roman",18,50
text 10,100,"This is Times New Roman"
color darkgreen
font "Tahoma",28,100
text 10,200,"This is BOLD!"
Will draw.
fonttext.png

See Also

Text

New To Version

0.9.4 help/fr/color.html0000664000175000017500000000674111722507500012552 0ustar jimjim
color

Color

Format

color colorname
color ( colorname )
color red, blue, green
color ( red, blue, green )
color rgb_value
color ( rgb_value )

Description

Règle la couleur active comme étant la couleur appelée colorname; de composantes rouge, bleue et verte red, blue, green ; ou de valeur RGB rgb_value. Il y a une couleur spéciale appelée CLEAR, de valeur -1. Si la couleur courante est réglée sur cette valeur, les pixels ou formes dessinés effaceront les pixels sur lesquels ils passeront et les rendront transparents. C'est particulièrement utile pour créer des sprites avec la commande Spriteslice.
Noms des couleurs et leur valeur RGB
Nom de la couleurValeur RGB
black0, 0, 0~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
white255, 255, 255~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
red255, 0, 0~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
darkred128, 0, 0~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
green0, 255, 0~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
darkgreen0, 128, 0~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
blue0, 0, 255~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
darkblue0, 0, 128~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
cyan0, 255, 255~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
darkcyan0, 128, 128~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
purple255, 0, 255~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
darkpurple128, 0, 128~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
yellow255, 255, 0~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
darkyellow128, 128 ,0~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
orange255, 102, 0~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
darkorange176, 61 ,0~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
grey164, 164 ,164~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
darkgrey128, 128 ,128~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
clear-1~~SP~~

Voir aussi

Rgb, GetColor

Exemple

clg
color rgb(128,128,128)
rect 0,0,graphwidth, graphheight
color red
circle 100,100,50
color 255,160,160
circle 100,100,25
Dessinera un rectangle gris avec dedans un cercle rouge et un centre rose.
color.png

Disponible à partir de la version

0.9.5m help/fr/atan.html0000664000175000017500000000125211722507500012347 0ustar jimjim
atan

Atan

Format

atan ( expression )

Description

Calcule l'arc-tangente d'une expression. Les angles sont exprimés en radians (0 à 2pi).

Voir aussi

Acos, Asin, Cos, Degrees, Radians, Sin, Tan help/fr/rgb.html0000664000175000017500000000121511722507477012212 0ustar jimjim
rgb

Rgb

Format

rgb(red, green, blue )

Description

Returns the RGB value of the color made up of the red, green, and blue components. Legal values for red, greem, and blue are 0 to 255.

See Also

Color, GetColor, Pixel

New To Version

0.9.5m help/fr/dbexecute.html0000664000175000017500000000242511722507477013414 0ustar jimjim
dbexecute

DBExecute

Format

dbexecute SqlStatement
dbexecute ( SqlStatement )

Description

Exécute une commande SQL sur le fichier de base de données SQLite ouvert. Cette commande ne produit pas d'enregistrement.

Exemple

Voir l'exemple de la page de DBOpen.

Voir aussi

DBClose, DBCloseSet, DBFloat, DBInt, DBOpen, DBOpenSet, DBRow, DBString

Liens externes

De plus amples informations (en anglais) sur les bases de données en général et SQLite en particulier sont disponibles aux adresses suivantes : Page d'accueil de SQLite et SQL sur Wikipedia.

Disponible à partir de la version

0.9.6y help/fr/plot.html0000664000175000017500000000074411722507477012424 0ustar jimjim
plot

Plot

Format

plot x, y
plot ( x, y )

Description

Changes the pixel located at x,y in the graphics output window to the current color. help/fr/mousey.html0000664000175000017500000000130511722507477012761 0ustar jimjim
mousey

Mousey

Format

mousey
mousey()

Description

Returns the current or last mouse y location of the mouse pointer over the graphic output.

See Also

Clickb, Clickclear, Clickx, Clicky, Mouseb, Mousex

New To Version

0.9.4d help/fr/cos.html0000664000175000017500000000226011722507500012210 0ustar jimjim
cos

Cos

Format

cos ( expression )

Description

Calcule le cosinus de l'expression. L'expression doit être exprimé en radians.

Note

La fonction cos ne retourne pas un résultat exact (mais une valur approchée).

Voir aussi

Acos, Asin, Atan, Degrees, Radians, Sin, Tan

Exemple

clg
color black
# Trace une ligne à travers la fenêtre graphic output
line 0,150,300,150
# point de départ
lastx = 0
lasty = cos(0) * 50 + 150
# puis pas après pas trace la courbe du cosinus
for x = 0 to 300 step 5
   angle = x / 300 * 2 * pi
   y = cos(angle) * 50 + 150
   line lastx, lasty, x, y
   lastx = x
   lasty = y
next x
dessine
cos.jpg help/fr/anonymousarrays.html0000664000175000017500000000137311722507477014717 0ustar jimjim
anonymousarrays

Tableaux "anonymes"

Un tableau anonyme est une série de valeurs numériques ou de chaînes de caractères, séparées par des virgules, et encadrées par des accolades {}. Un tableau anonyme peut ête utilisé à la place d'une variable d'un tableau ou pour assigner une variable d'un tableau.

Exemple

dim myarray(4)
myarray = {1, 2, 3, 4}
PS : je ne suis pas sûr de la traduction de cette page. C'est ainsi que je l'ai compris, mais sans certitude. help/fr/rand.html0000664000175000017500000000117311722507500012352 0ustar jimjim
rand

Rand

Format

rand
rand()

Description

Retourne un nombre au hasard entre 0 et 1. La distribution des valeurs est uniforme.

Note

Pour faire un nombre au hasard entre d'autre nombres, il faut multiplier ou ajouter des nombres appropriés. Example: Pour generer un nombre entier entre 0 et 10, utiliser: int(rand * 10). help/fr/cls.html0000664000175000017500000000054311722507500012207 0ustar jimjim
cls

Cls

Format

cls

Description

Nettoie la fenêtre text output. help/fr/wavwait.html0000664000175000017500000000077711722507477013136 0ustar jimjim
wavwait

WAVwait

Format

wavplay

Description

Wait for the currently playing WAV file to complete.

See Also

WAVplay WAVstop

New To Version

0.9.6t help/fr/graphwidth.html0000664000175000017500000000106311722507477013602 0ustar jimjim
graphwidth

Graphwidth

Format

graphwidth
graphwidth()

Description

Returns the width (x dimension) of the current graphics display window.

See Also

Graphheight, Graphsize

New To Version

0.9.3 help/fr/sin.html0000664000175000017500000000213711722507477012235 0ustar jimjim
sin

Sin

Format

sin ( expression )

Description

Computes the sine of expression. Expression must be in radians.

Note

The sin function does not produce an exact result.

See Also

Acos, Asin, Atan, Cos, Degrees, Radians, Tan

Example

clg
color black
# draw a line across the graphic output
line 0,150,300,150
# where do we start
lastx = 0
lasty = sin(0) * 50 + 150
# now step across the line and draw
for x = 0 to 300 step 5
   angle = x / 300 * 2 * pi
   y = sin(angle) * 50 + 150
   line lastx, lasty, x, y
   lastx = x
   lasty = y
next x
Draws sin.jpg help/fr/mid.html0000664000175000017500000000125311722507500012176 0ustar jimjim
mid

Mid

Format

mid( string, start character, length)

Description

Returns a portion of the specified string, starting from the start character, and continuing for length characters.

See Also

Left, Right

Example

print mid("Hello", 2, 3)
will display
ell
help/fr/print.html0000664000175000017500000000102711722507500012560 0ustar jimjim
print

Print

Format

print expression [ ; ]

Description

Writes text to the text output window, appending a new line. If the optional semicolon is included, no new line is appended.

See Also

Decimal help/fr/string.html0000664000175000017500000000071211722507477012747 0ustar jimjim
string

String

Format

string ( expression )

Description

Returns the string representation of a number.

See Also

Decimal help/fr/errorcodes.html0000664000175000017500000001136311722507477013614 0ustar jimjim
errorcodes

Error Codes

Description

This is a list of runtime error code numbers returned by the LastError function and text error messages returned by the LastErrorMessage function.
Error #Error Description
1ERROR_NOSUCHLABEL"No such label"
2ERROR_FOR1"Illegal FOR -- start number > end number"
3ERROR_FOR2"Illegal FOR -- start number < end number"
4ERROR_NEXTNOFOR"Next without FOR"
5ERROR_FILENUMBER"Invalid File Number"
6ERROR_FILEOPEN"Unable to open file"
7ERROR_FILENOTOPEN"File not open."
8ERROR_FILEWRITE"Unable to write to file"
9ERROR_FILERESET"Unable to reset file"
10ERROR_ARRAYSIZELARGE"Array dimension too large"
11ERROR_ARRAYSIZESMALL"Array dimension too small"
12ERROR_NOSUCHVARIABLE"Unknown variable"
13ERROR_NOTARRAY"Not an array variable"
14ERROR_NOTSTRINGARRAY"Not a string array variable"
15ERROR_ARRAYINDEX"Array index out of bounds"
16ERROR_STRNEGLEN"Substring length less that zero"
17ERROR_STRSTART"Starting position less than zero"
18ERROR_STREND"String not long enough for given starting character"
19ERROR_NONNUMERIC"Non-numeric value in numeric expression"
20ERROR_RGB"RGB Color values must be in the range of 0 to 255."
21ERROR_PUTBITFORMAT"String input to putbit incorrect."
22ERROR_POLYARRAY"Argument not an array for poly()/stamp()"
23ERROR_POLYPOINTS"Not enough points in array for poly()/stamp()"
24ERROR_IMAGEFILE"Unable to load image file."
25ERROR_SPRITENUMBER"Sprite number out of range."
26ERROR_SPRITENA"Sprite has not been assigned."
27ERROR_SPRITESLICE"Unable to slice image."
28ERROR_FOLDER"Invalid directory name."
29ERROR_DECIMALMASK"Decimal mask must be in the range of 0 to 15."
30ERROR_DBOPEN"Unable to open SQLITE database."
31ERROR_DBQUERY"Database query error (message follows)."
32ERROR_DBNOTOPEN"Database must be opened first."
33ERROR_DBCOLNO"Column number out of range."
34ERROR_DBNOTSET"Record set must be opened first."
35ERROR_EXTOPBAD"Invalid Extended Op-code."
36ERROR_NETSOCK"Error opening network socket."
37ERROR_NETHOST"Error finding network host."
38ERROR_NETCONN"Unable to connect to network host."
39ERROR_NETREAD"Unable to read from network connection."
40ERROR_NETNONE"Network connection has not been opened."
41ERROR_NETWRITE"Unable to write to network connection."
42ERROR_NETSOCKOPT"Unable to set network socket options."
43ERROR_NETBIND"Unable to bind network socket."
44ERROR_NETACCEPT"Unable to accept network connection."
45ERROR_NETSOCKNUMBER"Invalid Socket Number"
9999ERROR_NOTIMPLEMENTED"Feature not implemented in this environment."

Example

# test error trapping
onerror nicetrap
print 1
next haha
print 2
open 999, "bogus.file"
print "Runs Anyway"

# test error trapping off and fail at any error (default)
offerror
print 3
next hoho
print "never get here"

end

nicetrap:
# this is the nice error handler
print "trap and run - error on line " + lasterrorline + " - error number " + lasterror + " message " + lasterrormessage + " (" + lasterrorextra + ")"
return
will display
1
trap and run - error on line 4 - error number 4 message Next without FOR ()
2
trap and run - error on line 6 - error number 5 message Invalid File Number ()
Runs Anyway
3
ERROR on line 12: Next without FOR 

See Also

Lasterror, Lasterrorextra, Lasterrorline, Lasterrormessage, Offerror, Onerror help/fr/clickclear.html0000664000175000017500000000151411722507477013536 0ustar jimjim
clickclear

Clickclear

Format

clickclear
clickclear ( )

Description

Remet ClickB, Clickx et Clicky à zéro afin de pouvoir détecter facilement un clic de la souris.

Voir aussi

Clickb, Clickx, Clicky, Mouseb, Mousex, Mousey

Exemple

Voir le programme de la page de Clickb.

Disponible à partir de la version

0.9.4d help/fr/size.html0000664000175000017500000000155711722507500012406 0ustar jimjim
size

Size

Format

size
size()
size(filenumber)

Description

Returns the length, in bytes, of an opened file. If the file number is not specified file number zero (0) will be used.

See Also

Close, Eof, Open, Read, Readline, Reset, Write, Writeline, Exists, Seek

New To Version

0.9.4 help/fr/techinformation.html0000664000175000017500000000543511722507477014641 0ustar jimjim
techinformation

Developer and Technical

Overview

BASIC-256 programs are first compiled to byte code using LEX and YACC, and then run by interpreting the byte code in a stack machine. Adding functions is a simple matter of adding a byte code, letting LEX and YACC know how to parse the syntax, and coding the appropriate instruction in the interpreter. If you've never written a compiler or interpreter, the BASIC-256 internals would provide an excellent introduction to the basics of that. Please keep in mind that BASIC-256 is a teaching language for children (target ages 7-9), so we'd like to stay away from advanced concepts as much as possible. While it would be fun to make BASIC-256 a powerful high-level language, there are already much better languages that exist to fill that need: Python, Scheme.

To do

  1. Real-time error checking in the editor (parse each line just after it's typed)

The life of a BASIC-256 program

  • BASIC program parsed into tokens by LEX
  • LEX feeds tokens to YACC
  • YACC determines if line is valid syntax. If so, it adds the appropriate byte codes to the byte-coded program
  • If no syntax errors occur, the C++ portion of the program interprets the byte code one instruction at a time, using a stack machine
  • Run time errors halt program execution and display an error message on the screen
  • Graphical Output

    All graphing functions are performed on a buffer, which is subsequently written to the screen immediately after each operation. This is intentionally inefficient. The "fast" way to do this would be to have a separate rendering thread that calls a display routine when it's done, or to do all the rendering in the display routine. This is an ideal illustration of concessions made in BASIC-256 to keep things simple. We're interested in kids being able to see their dots move across the screen without having to explain double-buffering and multi-threading. We also want to allow them to write games like Pong that test for collisions using basic geometric formulas and draw the ball and paddles in a single loop. The current approach allows for this. Note: To speed things up for children doing more advanced programs, the FASTGRAPHICS mode has been added. When in this mode, the display will only be updated when the BASIC program uses the REFRESH command. This allows kids to benefit from double-buffering without having to understand it completely. help/fr/second.html0000664000175000017500000000223511722507477012716 0ustar jimjim
    second

    Second

    Format

    second
    second()

    Description

    Returns the current system clock's second of the current minute (0-59).

    Example

    # display nice date
    dim months$(12)
    months$ = {"January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"}
    print year + "-" + months$[month] + "-" + right("0" + day, 2)
    # display pretty time
    h = hour
    if h > 12 then
    h = h - 12
    ampm$ = "PM"
    else
    ampm$ = "AM"
    end if
    if h = 0 then h = 12
    print  right("0" + h, 2) + "-" + right("0" + minute, 2) + "-" + right("0" + second, 2) + " " + ampm$
    
    Will print something like.
    2010-July-15
    10-00-02 PM
    

    See Also

    Day, Hour, Minute, Month, Year

    New To Version

    0.9.4 help/fr/instr.html0000664000175000017500000000130711722507500012564 0ustar jimjim
    instr

    Instr

    Format

    instr( string1, string2 )

    Description

    Check to see if string2 is contained in string1. If it is, then this function will return the index of starting character of the first place where string2 occurs. Otherwise, this function will return 0.

    Note

    String indices begin at 1.

    Example

    print instr("Hello", "lo")
    
    will display
    4
    
    help/fr/decimal.html0000664000175000017500000000201411722507477013034 0ustar jimjim
    decimal

    Decimal

    Format

    decimal ( expression )
    decimal expression

    Description

    Définie le nombre maximal de décimales (0-16) à convertir quand un nombre à virgule flottante est transformé en chaîne de caractères. Cela ne change pas la précision interne des calculs numériques mais seulement la manière dont ils sont affichés ou enregistrés comme chaîne. Par défaut, 6 chiffres après la virgule seront affichés.

    Exemple

    print 2/3
    decimal 10
    print 2/3
    decimal 15
    print 2/3
    affichera
    0.666667
    0.6666666667
    0.666666666666667
    

    Voir aussi

    Print, String

    Disponible à partir de la version

    0.9.6w help/fr/dim.html0000664000175000017500000000241211722507477012211 0ustar jimjim
    dim

    Dim

    Format

    dim numericvariable ( integer )
    dim stringvariable$ ( integer )
    dim numericvariable ( rows , columns )
    dim stringvariable$ ( rows , columns )

    Description

    Retourne un nouveau tableau à 1 dimension de longueur integer ou à 2 dimensions qui peut être adressé par row et column. Selon l'assignation de la variable, un tableau numérique ou de chaînes de caractères est créé.
    Le premier élément d'un tableau a l'index 0 (zéro). Les index allant ainsi de 0 à {longueur}-1.

    Voir aussi

    Redim

    Exemple

    dim z(5)
    z = {1, 2, 3, 4, 5}
    print z[0] + " " + z[4]
    
    affichera
    1 5
    

    Exemple 2

    dim c$(4)
    c$ = {"à", "bulot, "laque", "L'anneau"}
    print c$[2] + " " + c$[3] + " ";
    print c$[1] + " " + c$[0] + "!"
    
    affichera
    L'anneau laque à bulot!
    
    help/fr/lower.html0000664000175000017500000000107711722507477012576 0ustar jimjim
    lower

    Lower

    Format

    lower( string)

    Description

    Returns string with all alphabetic characters converted to lower case.

    See Also

    Upper
    print lower("BlUe!")
    
    will display
    blue!
    

    New To Version

    0.9.5e help/fr/refresh.html0000664000175000017500000000106311722507477013077 0ustar jimjim
    refresh

    Refresh

    Format

    refresh

    Description

    Updates the graphics output window to show all drawing since the previous refresh command. Refresh only works in Fastgraphics mode

    See Also

    Fastgraphics help/fr/radians.html0000664000175000017500000000124711722507500013051 0ustar jimjim
    radians

    Radians

    Format

    radians ( expression )

    Description

     radians.png Converts an angle in degrees to radians.

    See Also

    Acos, Asin, Atan, Cos, Degrees, Sin, Tan help/fr/wavplay.html0000664000175000017500000000107111722507500013106 0ustar jimjim
    wavplay

    WAVplay

    Format

    wavplay filename
    wavplay ( filename )

    Description

    Play WAV audio file asynchronously (in the background).

    See Also

    WAVstop WAVwait

    New To Version

    0.9.4 help/fr/year.html0000664000175000017500000000137311722507477012405 0ustar jimjim
    year

    Year

    Format

    year
    year ( )

    Description

    Returns the current system clock's 4 digit year.

    See Also

    Day, Hour, Minute, Month, Second

    Example

    print "today's date is ";
    print (month + 1) + "/" + day + "/" + year
    
    will display
    today's date is 11/30/2009
    

    New To Version

    0.9.4 help/fr/read.html0000664000175000017500000000165011722507500012341 0ustar jimjim
    read

    Read

    Format

    read
    read()
    read(filenumber)

    Description

    Reads and returns a token from an open file. A token is any string of characters that is separated by a space, tab, or newline character. If the file number is not specified file number zero (0) will be used.

    See Also

    Close, Eof, Open, Readline, Reset, Write, Writeline, Exists, Seek, Size help/fr/exists.html0000664000175000017500000000147111722507477012763 0ustar jimjim
    exists

    Exists

    Format

    exists ( expression )

    Description

    Returns a binary flag (true/false) that will signal if the file path specified by the expression exists.

    See Also

    Close, Eof, Open, Read, Readline, Reset, Seek, Size, Write, Writeline

    New To Version

    0.9.4 help/fr/text.html0000664000175000017500000000162311722507477012427 0ustar jimjim
    text

    Text

    Format

    text x, y, string
    text ( x, y, string )

    Description

    Paints a text string on the Graphics Output Window at x, y using the current color and font.

    Example

    color grey
    rect 0,0,graphwidth,graphheight
    color red
    font "Times New Roman",18,50
    text 10,100,"This is Times New Roman"
    color darkgreen
    font "Tahoma",28,100
    text 10,200,"This is BOLD!"
    
    Will draw.
    fonttext.png

    See Also

    Color, Font

    New To Version

    0.9.4 help/fr/volume.html0000664000175000017500000000117511722507477012754 0ustar jimjim
    volume

    Volume

    Format

    volume level
    volume ( level )

    Description

    Adjust the volume of the notes played with the Sound command. Volume levels must be numeric values from 0 to 10. The default volume is 5.

    See Also

    Sound

    New To Version

    0.9.5i help/fr/left.html0000664000175000017500000000126011722507477012372 0ustar jimjim
    left

    Left

    Format

    left( string, length)

    Description

    Returns a portion of the specified string, starting from the first character on the left and continuing for length characters.

    See Also

    Mid, Right

    Example

    print left("Hello", 2)
    
    will display
    He
    

    New To Version

    0.9.5b help/fr/reset.html0000664000175000017500000000153311722507500012550 0ustar jimjim
    reset

    Reset

    Format

    reset
    reset()
    reset(filenumber)

    Description

    Clears an open file. All data stored in the file is lost. If the file number is not specified file number zero (0) will be used.

    See Also

    Close, Eof, Open, Read, Readline, Write, Writeline, Exists, Seek, Size help/fr/dbclose.html0000664000175000017500000000223511722507477013056 0ustar jimjim
    dbclose

    DBClose

    Format

    dbclose
    dbclose ( )

    Description

    Ferme le fichier de données SQLite actuellement ouvert.

    Exemple

    Voir l'exemple de la page de DBOpen.

    Voir aussi

    DBCloseSet, DBExecute, DBFloat, DBInt, DBOpen, DBOpenSet, DBRow, DBString

    Liens externes

    De plus amples informations (en anglais) sur les bases de données en général et SQLite en particulier sont disponibles aux adresses suivantes : SQLite Home Page et SQL at Wikipedia.

    Disponible à partir de la version

    0.9.6y help/fr/abs.html0000664000175000017500000000100411722507477012201 0ustar jimjim
    abs

    Abs

    Format

    abs ( expression )

    Description

    Retourne la valeur absolue d'une expression numérique.

    Exemple

    print abs(-45)
    print abs(6.45)
    
    permet d'afficher
    45
    6.45
    
    help/fr/stamp.png0000664000175000017500000000172211722507477012407 0ustar jimjimPNG  IHDR,,"sRGB pHYs  tIME StEXtCommentCreated with GIMPW?IDATx0 A{6%d햠`  B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B!!!!!!!!!!!!!!!!!!Ŏ l%Be+l%Be+l%Be+l%Be+l%Be+l%Be+l%Be+l%Be+l%Be+l%Be+l%Be+C[mJV"t[!:ݖDm%Be+C[mJV"t[!:ݖDm%Be+C[mJV"t[!:,JnV"D[mJ{+-[vo%Be+&YOsùw
    pixel

    Pixel

    Format

    pixel (x, y )

    Description

    Returns the RGB value of the pixel at the x and y coordinate. If the pixels has not been set since the last Clg command or was drawn with the color CLEAR a -1 will be returned.

    See Also

    Rgb

    New To Version

    0.9.5m help/fr/open.html0000664000175000017500000000244111722507500012366 0ustar jimjim
    open

    Open

    Format

    open filename
    open(filename)
    open filenumber, filename
    open(filenumber, filename)

    Description

    Opens a file for reading and writing. The filename is specified as a string, and may be an absolute or relative path. If the file number is not specified file number zero (0) will be used.

    Note

    BASIC256 may have up to 8 files open at a single time. The files are numbered from 0 to 7. Opening a file to a number while another is already open to that number will close the open file.

    See Also

    Changedir, Close, Currentdir, Eof, Read, Readline, Reset, Write, Writeline, Exists, Seek, Size help/fr/lasterrorextra.html0000664000175000017500000000153311722507477014524 0ustar jimjim
    lasterrorextra

    LastErrorExtra

    Format

    lasterrorextra
    lasterrorextra ( )

    Description

    Returns statement specific "extra" information about the error.

    Example

    See example of usage on Error Codes page.

    See Also

    Error Codes, Lasterror, Lasterrorline, Lasterrormessage, Offerror, Onerror

    New To Version

    0.9.6z help/fr/graphsize.html0000664000175000017500000000112611722507477013435 0ustar jimjim
    graphsize

    Graphsize

    Format

    graphsize x_expression, y_expression

    Description

    Changes the size of the graphics display window and redraws the BASIC256 application.

    See Also

    Graphheight, Graphwidth

    New To Version

    0.9.3 help/fr/dbstring.html0000664000175000017500000000214511722507477013257 0ustar jimjim
    dbstring

    DBString

    Format

    dbstring ( ColumnNumber )

    Description

    Return a string from the specified column of the current row of the open recordset.

    Example

    See example of usage on DBOpen page.

    See Also

    DBClose, DBCloseSet, DBExecute, DBFloat, DBInt, DBOpen, DBOpenSet, DBRow

    External Links

    More information about databases in general and SQLite specifically can be found at SQLite Home Page and SQL at Wikipedia.

    New To Version

    0.9.6y help/fr/int.html0000664000175000017500000000107311722507477012234 0ustar jimjim
    int

    Int

    Format

    int ( expression )

    Description

    Convert expression to an integer (whole) number. Int will convert a string or a float to an integer value. If the expression can not be converted then a zero will be returned.

    See Also

    Float help/fr/dbrow.html0000664000175000017500000000223411722507477012557 0ustar jimjim
    dbrow

    DBRow

    Format

    dbrow
    dbrow ( )

    Description

    Function that advances the record set to the next row. Returns a true value if there is a row or false if we are at the end of the record set.

    Example

    See example of usage on DBOpen page.

    See Also

    DBClose, DBCloseSet, DBExecute, DBFloat, DBInt, DBOpen, DBOpenSet, DBString

    External Links

    More information about databases in general and SQLite specifically can be found at SQLite Home Page and SQL at Wikipedia.

    New To Version

    0.9.6y help/fr/dbfloat.html0000664000175000017500000000235711722507477013063 0ustar jimjim
    dbfloat

    DBFloat

    Format

    dbfloat ( ColumnNumber )

    Description

    Retounrne une valeur décimale (virgule flottante) de la colonne demandée de la ligne active de l'enregistrement ouvert.

    Exemple

    Voir l'exemple de la page de DBOpen.

    Voir aussi

    DBClose, DBCloseSet, DBExecute, DBInt, DBOpen, DBOpenSet, DBRow, DBString

    Liens externes

    De plus amples informations (en anglais) sur les bases de données en général et SQLite en particulier, sont disponibles aux adresses suivantes : Page d'accueil de SQLite et SQL sur Wikipedia.

    Disponible à partir de la version

    0.9.6y help/fr/operators.html0000664000175000017500000000341711722507477013464 0ustar jimjim
    operators

    Opérateurs

    Les opérateurs +, -, *, /, ^, %, et \ sont utilisés pour réaliser respectivement une addition, une soustraction, une multiplication, une division, une puissance, un modulo et une division arrondie à l'entier des opérandes. Les opérandes valides sont des constantes numériques et/ou des varaibles numériques.

    L'opérateur = est utilisé à la fois pour assigner une valeur à une varaiable et pour tester l'égalité. L'opérateur + peut être utilisé pour réaliser la concaténation (= mise bout à bout) de n'importe quelle combinaison de chaînes de constantes et de variables.string variables. L'opératuer : peut servir à séparer plusieurs instructions sur une même ligne. L'opérateur ; supprime le retour à la ligne qu'introduirait une commande PRINT. L'opérateur # est un raccourci de la commande Rem et interchangeable avec celle-ci.

    help/fr/dbcloseset.html0000664000175000017500000000215411722507477013572 0ustar jimjim
    dbcloseset

    DBCloseSet

    Format

    dbcloseset
    dbcloseset ( )

    Description

    Close the currently open record set opened by DBOpenSet.

    Example

    See example of usage on DBOpen page.

    See Also

    DBClose, DBExecute, DBFloat, DBInt, DBOpen, DBOpenSet, DBRow, DBString

    External Links

    More information about databases in general and SQLite specifically can be found at SQLite Home Page and SQL at Wikipedia.

    New To Version

    0.9.6y help/fr/sin.jpg0000664000175000017500000000714211722507477012052 0ustar jimjimJFIF``C    $.' ",#(7),01444'9=82<.342C  2!!22222222222222222222222222222222222222222222222222p-" }!1AQa"q2#BR$3br %&'()*456789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz w!1AQaq"2B #3Rbr $4%&'()*56789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz ? ( ( ( ( ( ( ( ( ( ( ( ( +}y.$SSsH.;{w@A۸(`j?G׵:1+"r(I[Cq%j)wuh8;3(H䊏;~{? w6Ͳ7zJr>eFAA6đC8*j0?e_xﬥѧ+uIr3EAe}iZ%ݍVgdH 8$gq$7W֚]Aum&vMѰppÃ#QEQEQEQEQEQEQEQEQEQEQEQEQEWM&2@,I'T bH@$[M6ﮠ@ r@k#~"W+xrğ6XMSTdZ0YiH$ U$i58 ;{x(b@TP0RQEQEQEQEd蹻}GJ RL g0oKLNˎӵneɤ Ip\FTtu+uFxg$2@u$0A$ tVEݽi˓osf8p *@'icF'@Q@Q@Q@Q@Q@Q@Q@Q@Q@Q@UMGQMY$WIˆ2M!PH'$,HPH5F6d^I$o."4A g!A"5MY T\D f`$BNӦKuI5dǐ2f  @Q@Q@Q@Q@Q@Q@^[kuH 20 T,n,K$+eBJ (,A{eoZ={|d*A!`@! ɲM/T|ݕ .*`,J,z DŽh?aG&D_UI<h^DJK8Գ#%NK>,>DO ռwʁ6 dGހ17 ' "_4h0( Ѣ/*M%CFޢ07 ' "_4h0( Ѣ/*M%CFޢ07 ' "_4h0( Ѣ/*M%CFޢ07 ' "_4h0( Ѣ/*M%CFި/omGdIH$*I(@@N' FGygRK` =7H_Wu?hPza"X.A;}⪁w/.T#*g춅 PF 1 )!A*&`o/4OEQ h?a[P&D_UKUE`o/4OEQ h?a[P&D_UKUE`o/4OEQ h?a[P&D_UKUE`o/4OEQ h?a[P&D_UKUEsW+Vh^$'@cR9 0*C A?5OZŪYjdًKV1P <n %z+x&.$尕vqfF'-4J9$}Y~|6x-Ia$l]H #IX]h]vwm3dV$Eʨ$pCni^uk&  AVXAR@"'(((((O{6DXN,ĐI$ 4^uu&ȓ IU%P $&YY\^]GTm b2R BUIB5MR=~hX0`ҐH,2H,kPEPEPEPEPEPEPEPEPEPEPEPY7Wwoiq@EcbVZjvMjB9GIbhSY7 {ev7{hLvvCಝFڂmm㷷"$ qUE8%QEQEQEQEQEQEQEQEQEQEQEQEhelp/fr/tan.html0000664000175000017500000000212711722507500012210 0ustar jimjim
    tan

    Tan

    Format

    tan ( expression )

    Description

    Computes the tangent of expression. Expression must be in radians.

    Note

    The tan function does not produce an exact result.

    See Also

    Acos, Asin, Atan, Sin, Cos, Degrees, Radians

    Example

    clg
    color black
    # draw a line across the graphic output
    line 0,150,300,150
    # where do we start
    lastx = 0
    lasty = tan(0) * 50 + 150
    # now step across the line and draw
    for x = 0 to 300 step 5
       angle = x / 300 * 2 * pi
       y = tan(angle) * 50 + 150
       line lastx, lasty, x, y
       lastx = x
       lasty = y
    next x
    
    Draws tan.jpg help/fr/lasterrormessage.html0000664000175000017500000000152511722507500015011 0ustar jimjim
    lasterrormessage

    LastErrorMessage

    Format

    lasterrormessage
    lasterrormessage ( )

    Description

    Returns a string representing the last runtime error.

    Example

    See example of usage on Error Codes page.

    See Also

    Error Codes, Lasterror, Lasterrorextra, Lasterrorline, Offerror, Onerror

    New To Version

    0.9.6z help/fr/systemrequirements.html0000664000175000017500000000133711722507477015435 0ustar jimjim
    systemrequirements

    Configuration minimale

    Windows (2000,XP,Vista,Windows 7):
    • 128MB de RAM
    • 100MB d'espace libre sur un disque dur
    • MinGW, QT 4.0, GNU Flex et Bison (si vous voulez compiler le programme)
    Unix/Linux/FreeBSD:
    • 64MB de RAM
    • 15MB d'espace libre sur un disque dur
    • les bibliothèques de développement QT 4.0 (si vous désirez compiler)
    • GNU Flex et Bison (pour compiler)
    • help/fr/log.html0000664000175000017500000000073711722507500012214 0ustar jimjim
      log

      Log

      Format

      log ( expression )

      Description

      Return the base e lograthim of expression.

      See Also

      Log10

      New To Version

      0.9.5w help/fr/sound.html0000664000175000017500000000202711722507477012572 0ustar jimjim
      sound

      Sound

      Format

      sound frequency, duration
      sound ( frequency, duration )
      sound ( array )
      sound array
      sound {frequency1, duration1, frequency2, duration2, ...}

      Description

      Play a sound from the computer's speakers.Frequency is expressed in Hz and duration is expressed in milliseconds (1000 in a second). An array or list containing frequency and durations may also be passed. This eliminates any clicking between sounds when more than one is being output sequentially. Sound support for LINUX systems was added in version 0.9.5g. Sound was changed to use the default sound device in Windows in version 0.9.5h

      See Also

      Volume help/fr/poly.html0000664000175000017500000000223011722507477012421 0ustar jimjim
      poly

      Poly

      Format

      poly numeric array variable
      poly {x1, y1, x2, y2, x3, y3 ...}

      Description

      Draws a polygon. The sides of the polygon are defined by the values stored in the array, which should be stored as x,y pairs, sequentially. The length of the array/2 will define the number of points. A polygon may also be specified using a list of x,y pairs enclosed in curly braces {}.

      Note

      The number of points in the array argument was removed from the poly statement in version 0.9.4.

      See Also

      Stamp

      Example

      color blue
      rect 0,0,300,300
      color green
      dim tri(6)
      tri = {100, 100, 200, 200, 100, 200}
      poly tri
      
      color blue
      rect 0,0,300,300
      color green
      poly {100, 100, 200, 200, 100, 200}
      
      Both programs use the poly statement to draw the following:
      poly.png help/fr/stamp.html0000664000175000017500000000365711722507477012600 0ustar jimjim
      stamp

      Stamp

      Format

      stamp x, y, array
      stamp x, y, {x1, y1, x2, y2, x3, y3 ...}
      stamp x, y, scale, array
      stamp x, y, scale, {x1, y1, x2, y2, x3, y3 ...}
      stamp x, y, scale, rotation, array
      stamp x, y, scale, rotation, {x1, y1, x2, y2, x3, y3 ...}

      Description

      Draws a polygon with top left corner (origin) at x, y. Optionally scales size of polygon by the defined scale (1=normal size). Also optionally rotates the polygon by a specified angle around the origin (clockwise in radians). The sides of the polygon are defined by the values in an array, which should be stored as x,y pairs, sequentially. The length of the array/2 will define the number of points. A stamped polygon can also be specified using a list of x,y pairs enclosed in curly braces {}.

      See Also

      Poly

      Example

      Both of the code blocks below will draw a pair of green triangles on the graphics window:
      clg
      color blue
      rect 0,0,300,300
      color green
      dim tri(6)
      tri = {0, 0, 100, 100, 0, 100}
      # stamp the triangle at 0,0 (full size)
      stamp 100, 100, tri
      # stamp the triangle at 200,100 (half size)
      stamp 200, 100, .5, tri
      
      clg
      color blue
      rect 0,0,300,300
      color green
      # stamp the triangle at 0,0 (full size)
      stamp 100, 100, {0, 0, 100, 100, 0, 100}
      # stamp the triangle at 200,100 (half size)
      stamp 200, 100, .5, {0, 0, 100, 100, 0, 100}
      
      Both programs will draw:
      stamp.png

      New To Version

      0.9.4 help/fr/right.html0000664000175000017500000000126611722507500012546 0ustar jimjim
      right

      Right

      Format

      right( string, length)

      Description

      Returns a portion of the specified string, starting from the last length characters from the right end of the of the string.

      See Also

      Mid, Left

      Example

      print right("Hello", 2)
      
      will display
      lo
      

      New To Version

      0.9.5b help/fr/changedir.html0000664000175000017500000000210211722507500013343 0ustar jimjim
      changedir

      Changedir

      Format

      changedir expression
      changedir ( expression )

      Description

      Change de répertoire de travail pour le chemin spécifié par l'expression. Pour toutes le OS (y compris Windows) un anti-slash (/) est utilisé pour séparer les répertoire au sein d'un chemin complet.

      Voir aussi

      Close, Currentdir, Eof, Open, Read, Readline, Reset, Write, Writeline, Exists, Seek, Size

      Disponible à partir de la version

      0.9.6r help/fr/netconnect.html0000664000175000017500000000471011722507477013603 0ustar jimjim
      netconnect

      NetConnect

      Format

      netconnect server_name, port_number
      netconnect ( server_name, port_number )
      netconnect socket_number, server_name, port_number
      netconnect ( socket_number, server_name, port_number )

      Description

      Open a network connection (client) to a server. The IP address or host name of a server are specified in the server_name argument, and the specific network port number in the port_number argument. If socket_number is not specified socket number zero (0) will be used.

      Example

      Open two instances of BASIC-256 on a single computer. Paste the "server" code into one and the "client" code into the other. Run the server first and the client second. You can see how the messages are sent back and forth between the two different processes.

      Server Code

      # get a message and send back success
      print "wait for connection"
      netlisten 9997
      print "got connection"
      do
         while not netdata
            pause .1
            print ".";
         end while
         n$ = netread
         print n$
         netwrite "I got '" + n$ + "'."
      until n$ = "end"
      netclose
      
      will display
      wait for connection
      got connection
      .1 Hi There
      ....2 Hi There
      ........3 Hi There
      ..........4 Hi There
      .....5 Hi There
      .......6 Hi There
      ....7 Hi There
      ..........8 Hi There
      ....9 Hi There
      .....10 Hi There
      .end
      

      Client Code

      # have the user enter a message and send it to the server
      input "enter message?", m$
      netconnect "127.0.0.1", 9997
      for t = 1 to 10
         pause rand
         netwrite t + " " + m$
         print netread
      next t
      netwrite "end"
      print netread
      netclose
      
      will display
      enter message?Hi There
      I got '1 Hi There'.
      I got '2 Hi There'.
      I got '3 Hi There'.
      I got '4 Hi There'.
      I got '5 Hi There'.
      I got '6 Hi There'.
      I got '7 Hi There'.
      I got '8 Hi There'.
      I got '9 Hi There'.
      I got '10 Hi There'.
      I got 'end'.
      

      See Also

      NetClose, NetData, NetListen, NetRead, NetWrite

      New To Version

      0.9.6.31 help/fr/day.html0000664000175000017500000000147511722507500012210 0ustar jimjim
      day

      Day

      Format

      day
      day ( )

      Description

      Retourne le jour du mois actuel (1-31) d'après l'horloge système.

      Voir aussi

      Hour, Minute, Month, Second, Year

      Exemple

      print "Aujourd'hui nous sommes le ";
      print day + "/" + (month + 1) + "/" + year
      
      affichera|
      Aujourd'hui nous sommes le 12/09/2010
      

      Disponible à partir de la version

      0.9.4 help/fr/dbint.html0000664000175000017500000000232611722507477012544 0ustar jimjim
      dbint

      DBInt

      Format

      dbint ( ColumnNumber )

      Description

      Retourne la valeur entière de la colonne demandée de la ligne active de l'enregistrement ouvert.

      Exemple

      Voir l'exemple de la page de DBOpen.

      Voir aussi

      DBClose, DBCloseSet, DBExecute, DBFloat, DBOpen, DBOpenSet, DBRow, DBString

      Liens externes

      De plus amples informations (en anglais) sur les bases de données en général et SQLite en particulier, sont disponibles aux adresses suivantes : Page d'accueil de SQLite et SQL sur Wikipedia.

      Disponible à partir de la version

      0.9.6y help/fr/line.html0000664000175000017500000000123411722507500012353 0ustar jimjim
      line

      Line

      Format

      line x0, y0, x1, y1
      line(x0, y0, x1, y1)

      Description

      Draws a line from the point x0,y0 to the point x1, y1.

      Example

      color white
      rect 0,0,300,300
      color black
      line 50,50,200,200
      line 100,200,200,200
      line 100,200,50,50
      
      draws
      line.png help/fr/numericconstants.html0000664000175000017500000000142211722507500015022 0ustar jimjim
      numericconstants

      Constantes numériques

      Les constantes numériques peuvent être n'importe quel(s) caractère(s) numérique(s), précédé ou non d'un signe moins (pour les nombres négatifs) et une éventuelle décimale (pour les nombres à virgule flottante).

      Les nombres positifs entiers peuvent aussi être exprimées en binaire (base 2), octal (base 8) et hexadécimal (base 16). Faites précéder les entrées binaires de 0b (0b1110 = 14), octales de 0o (0o177 = 127) et hexadécimales de 0x (0xff = 255). help/fr/eof.html0000664000175000017500000000161511722507500012200 0ustar jimjim
      eof

      Eof

      Format

      eof
      eof()
      eof(filenumber)

      Description

      Returns a binary flag (true/false) that will signal if we have read to the End Of File (EOF). If file number is not specified then file number zero (0) will be used.

      See Also

      Close, Exists, Open, Read, Readline, Reset, Seek, Size, Write, Writeline

      New To Version

      0.9.4 help/fr/spritedim.html0000664000175000017500000000202011722507500013416 0ustar jimjim
      spritedim

      Spritedim

      Format

      spritedim n
      spritedim ( n )

      Description

      Create n sprite placeholders in memory. Sprites are accessed in your program by a sprite number from 0 to n-1.

      See Also

      Spritecollide, Spriteh, Spritehide, Spriteload, Spritemove, Spriteplace, Spriteshow, Spriteslice, Spritev, Spritew, Spritex, Spritey

      New To Version

      0.9.6n help/fr/getslice.html0000664000175000017500000000125511722507477013243 0ustar jimjim
      getslice

      GetSlice

      Format

      getslice(x, y, width, height)

      Description

      Return a string that contains a Hexadecimal representation of the rectangle defined by the parameters. String is formatted as first 4 bytes - width, next 4 bytes - height, 6 bytes for each pixel (width * height).

      See Also

      PutSlice

      New To Version

      0.9.6b help/fr/asin.html0000664000175000017500000000123611722507477012375 0ustar jimjim
      asin

      Asin

      Format

      asin ( expression )

      Description

      Calcule l'arc-sinus d'une expression. Les angles sont exprimés en (0 à 2pi).

      Voir aussi

      Acos, Atan, Cos, Degrees, Radians, Sin, Tan help/fr/clg.html0000664000175000017500000000053611722507477012212 0ustar jimjim
      clg

      Clg

      Format

      clg

      Description

      Clears the graphics output window. help/fr/ifthen.html0000664000175000017500000000226711722507477012725 0ustar jimjim
      ifthen

      If / Then

      Format

      if booleanexpr then statement
      if booleanexpr then
      statement(s)
      end if
      if booleanexpr then
      statement(s)
      else
      statement(s)
      end if

      Description

      A single line IF evaluates booleanexpr, when true the statement(s) following the then is executed, otherwise execution continues on the next line. There are also two forms of a multi-line if statement, one with a true block and one with a true and a false block of code to execute.

      Example

      print "Guess my letter - press a key"
      # wait for the user to press a key
      do
        a = key
        pause .01
      until a <> 0
      #
      if chr(a) = "Z" then
         print "Yippie, you pressed the Z key!!!"
      else
         print "darn, you pressed something else."
      end if
      #
      end
      

      New To Version

      0.9.4g help/fr/key.html0000664000175000017500000000143611722507500012220 0ustar jimjim
      key

      Key

      Format

      key
      key()

      Description

      Immediately returns an integer value corresponding to the currently pressed keyboard key. If no key has been pressed since the last call to the key function then the number zero (0) will be returned.

      Note

      if key = 47 then print key
      
      will not display the desired results, because it's calling key twice in succession, and will return different values each time. This code will do what you want:
      a = key
      if a = 47 then print a
      
      help/fr/spriteh.html0000664000175000017500000000166611722507477013130 0ustar jimjim
      spriteh

      Spriteh

      Format

      spriteh ( spritenumber )

      Description

      Returns the height, in pixels, of a loaded sprite.

      See Also

      Spritecollide, Spritedim, Spritehide, Spriteload, Spritemove, Spriteplace, Spriteshow, Spriteslice, Spritev, Spritew, Spritex, Spritey

      New To Version

      0.9.6n help/fr/index.html0000664000175000017500000002565611722507477012566 0ustar jimjim
      start
      Cette documentation est en cours de traduction. Merci de votre compréhension, nous allons tenter d'avancer le plus vite possible. N'hésitez pas à laisser des commentaires par le formulaire en bas de page.

      Référence syntaxique de BASIC-256 0.9.6.32

      Instructions et fonctions - ordre alphabétique

      Instructions et fonctions - Par groupes

      Tableaux

      Dim, Redim

      Bases de données (SQLite)

      DBClose, DBCloseSet, DBExecute, DBFloat, DBInt, DBOpen, DBOpenSet, DBRow, DBString

      Manipulation des erreurs

      Lasterror, Lasterrorextra, Lasterrorline, Lasterrormessage, Offerror, Onerror

      Entrées / Sorties sur les fichiers

      Changedir, Close, Currentdir, Eof, Exists, Open, Read, Readline, Reset, Seek, Size, Write, Writeline

      Graphismes

      Circle, Clg, Cls, Color, FastGraphics, Font, GetColor, GetSlice, Graphheight, Graphsize, Graphwidth, Imgload, Line, Pixel, Plot, Poly, PutSlice, Rect, Refresh, Rgb, Spritecollide, Spritedim, Spriteh, Spritehide, Spriteload, Spritemove, Spriteplace, Spriteshow, Spriteslice, Spritev, Spritew, Spritex, Spritey, Stamp, Text

      Clavier et texte

      Input, Key, Print

      Mathématiques

      Abs, Acos, Asin, Atan, Ceil, Cos, Degrees, Float, Floor, Int, Log, Log10, Radians, Rand, Sin, Tan

      Souris

      Clickb, Clickclear, Clickx, Clicky, Mouseb, Mousex, Mousey,

      Communication réseau

      NetClose, NetConnect, NetData, NetListen, NetRead, NetWrite

      Contrôle de programme

      Do / Until, End, For / Next, Goto, Gosub / Return, If / Then, Pause, Rem, While / End While

      Manipulation de chaînes de caractères

      Asc, Chr, Decimal, Instr, Left, Length, Lower, Mid, Right, String, Upper

      Son

      Say, Sound, Volume, WAVplay, WAVstop, WAVwait

      Heure et date

      Day, Hour, Minute, Month, Second, Year

      Autres instructions et fonctions

      System

      Autres documentations

      • Configuration minimale
      • Informations techniques
      • Version en une seule page de la référence syntaxique et du langage
      • help/fr/say.html0000664000175000017500000000122211722507477012232 0ustar jimjim
        say

        Say

        Format

        say expression
        say ( expression )

        Description

        Utilise le moteur du système de synthèse vocale (TTS - Text to Speech) pour dire l'expression. Dans GNU/Linux, les bibliothèques FLite ou eSpeak sont nécessaires. Dans Windows, la voix SAPI par défaut actuelle sera utilisée.

        Nouveau dans la version

        0.9.4 help/fr/circle.html0000664000175000017500000000114411722507500012665 0ustar jimjim
        circle

        Circle

        Format

        circle x,y,r

        Description

        Trace un cercle dont les coordonnées du centre sont x,y et le rayon r. Le cercle étant de la couleur active.

        Exemple

        color blue
        rect 0,0,300,300
        color red
        circle 100,100,50
        
        dessine
        cir.png help/fr/clickx.html0000664000175000017500000000147711722507477012727 0ustar jimjim
        clickx

        Clickx

        Format

        clickx
        clickx ( )

        Description

        Retourne l'abscisse x du pointeur de la souris sur la surface graphic output au dernier clic.

        Voir aussi

        Clickclear, Clickb, Clicky, Mouseb, Mousex, Mousey

        Exemple

        Voir le programme de la page de Clickb.

        Disponible à partir de la version

        0.9.4d help/fr/currentdir.html0000664000175000017500000000173611722507477013631 0ustar jimjim
        currentdir

        Currentdir

        Format

        currentdir
        currentdir ( )

        Description

        Retourne le chemin complet du répertoire courant. Pour toutes les OS (y compris Windows) un anti-slash (/) sépare les répertoires du chemin.

        SeVoir aussi

        Changedir, Close, Eof, Open, Read, Readline, Reset, Write, Writeline, Exists, Seek, Size

        Disponible à partir de la version

        0.9.6r help/fr/goto.html0000664000175000017500000000107411722507477012413 0ustar jimjim
        goto

        Goto

        Format

        goto label

        Description

        Jumps to the specified label.

        See Also

        Gosub / Return

        Example

        print "I";
        goto skipit
        print " don't";
        skipit: #
        print " want cookies."
        
        will print
        I want cookies.
        
        help/fr/dountil.html0000664000175000017500000000157411722507477013126 0ustar jimjim
        dountil

        Do / Until

        Format

        do
        statement(s)
        until booleanexpression

        Description

        Execute the statement(s) inside the do loop whil the booleanexpression evaluates to false. Do / Until executes the statements one or more times. The test is done after each time the code in the loop is executed.

        See Also

        For / Next, While / End While

        Example

        t = 1
        do
          print t
          t = t + 1
        until t > 5
        
        will print
        1
        2
        3
        4
        5
        

        New To Version

        0.9.4g help/fr/asc.html0000664000175000017500000000375011722507477012214 0ustar jimjim
        asc

        Asc

        Format

        asc ( expression )

        Description

        Convertit le premier caractère d'une chaîne en sa valeur ASCII (= un nombre entier).
    Ordre des opérations
    NiveauOpérateurCatégorie/Description
    1( )Groupement
    2^Exposant
    3-Moins
    4* / \Multiplication et Division
    5%Reste entier (Mod)
    6+ -Addition, Concaténation et Soustraction
    7< <= > >= = <>Comparaison (Numérique et Chaîne)
    8NOT"Non" logique
    9AND"Et" logique
    10OR"Ou" logique
    11XOR"Ou exclusif" logique
    AscChrAscChrAscChrAscChrAscChrAscChr
    32SPACE48064@80P96`112p
    33!49165A81Q97a113q
    34"50266B82R98b114r
    35#51367C83S99c115s
    36$52468D84T100d116t
    37%53569E85U101e117u
    38&54670F86V102f118v
    39'55771G87W103g119w
    40(56872H88X104h120x
    41)57973I89Y105i121y
    42*58:74J90Z106j122z
    43+59;75K91[107k123{
    44,60<76L92\108l124|
    45-61=77M93]109m125}
    46.62>78N94^110n126~
    47/63?79O95_111o127

    Voir Aaussi

    Chr

    Exemple

    print asc("A")
    print asc("bleu")
    
    permet d'afficher
    65
    98
    

    Fonction disponible de la version

    0.9.4 help/fr/netdata.html0000664000175000017500000000176211722507477013067 0ustar jimjim
    netdata

    NetData

    Format

    netdata
    netdata ( )
    netdata socket_number
    netdata ( socket_number )

    Description

    Returns a true value (1) of there is data waiting to be read in using the NetRead function, else returns false (0). If socket_number is not specified socket number zero (0) will be used.

    Example

    See example of usage on NetConnect page.

    See Also

    NetClose, NetConnect, NetListen, NetRead, NetWrite

    New To Version

    0.9.6.31 help/fr/float.html0000664000175000017500000000115211722507500012530 0ustar jimjim
    float

    Float

    Format

    float ( expression )

    Description

    Convert expression to a floating point (decimal) number. Float will convert a string or an integer to a decimal value. If the expression can not be converted then a zero will be returned.

    See Also

    Int

    New To Version

    0.9.4 help/fr/input.html0000664000175000017500000000166411722507500012572 0ustar jimjim
    input

    Input

    Format

    input expression, stringvariable
    input expression, numericvariable
    input stringvariable
    input numericvarvariable

    Description

    Waits for the user to type a line of text into the text output window. When the user hits the enter or return key, the line is read in to stringvar or numericvariable.
    User may optionally be prompted for the input by expression.
    If a numeric variable is specified and non-numeric data is entered a zero will be assigned to the numeric variable.
    References to array elements may also be specified. help/fr/lasterror.html0000664000175000017500000000147011722507477013460 0ustar jimjim
    lasterror

    LastError

    Format

    lasterror
    lasterror ( )

    Description

    Returns the last runtime error number.

    Example

    See example of usage on Error Codes page.

    See Also

    Error Codes, Lasterrorextra, Lasterrorline, Lasterrormessage, Offerror, Onerror

    New To Version

    0.9.6z help/fr/hour.html0000664000175000017500000000223611722507477012421 0ustar jimjim
    hour

    Hour

    Format

    hour
    hour()

    Description

    Returns the current system clock's hour of the day (0-23).

    Example

    # display nice date
    dim months$(12)
    months$ = {"January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"}
    print year + "-" + months$[month] + "-" + right("0" + day, 2)
    # display pretty time
    h = hour
    if h > 12 then
    h = h - 12
    ampm$ = "PM"
    else
    ampm$ = "AM"
    end if
    if h = 0 then h = 12
    print  right("0" + h, 2) + "-" + right("0" + minute, 2) + "-" + right("0" + second, 2) + " " + ampm$
    
    Will print something like.
    2010-July-15
    10-00-02 PM
    

    See Also

    Day, Hour, Minute, Month, Second, Year

    New To Version

    0.9.4 help/fr/end.html0000664000175000017500000000070611722507500012175 0ustar jimjim
    end

    End

    Format

    end

    Description

    Halts program execution.

    Example

    print "I am done."
    end
    print "Or am I?"
    
    will print
    I am done.
    
    help/fr/cos.jpg0000664000175000017500000000721311722507500012027 0ustar jimjimJFIF``C    $.' ",#(7),01444'9=82<.342C  2!!22222222222222222222222222222222222222222222222222p-" }!1AQa"q2#BR$3br %&'()*456789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz w!1AQaq"2B #3Rbr $4%&'()*56789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz ? ( ( ( ( ( ( ( * M6ﮠ@8cGڵc(?l^5ïpLiA kZiw}ux4E$Ʋ?/ou-D6R 賅IpsXiv o%nfi11# `o'(/:ݵl}$2N3 P,-ЦEm|k4  H r mTs ռ$ʅ$E `ڱ{Agab6D jF:d + y#-SLpnK{'B|Iݴ0Rkj ( ( ( ( ( ( ( ( ( ( ( ( ( um.e֫*dGJF9rLUI3%ro$y`A XӴtv6y$甃$v 0 vZ..QdT")Hf)~cg*PEPEPEPs ռ$ʅ$E `ڱ~wߚ~Ѣ[$A^m; V^RK.ɠ:6py~bot۸P0n IRL` P-;QRi#WH˚ @C `  A R EPEPEPEPEPEPEPEPEPEPEPY7orl0. -APrR!NBVB.M CJA)PC0 ~OK[XD$$byf$XI$I.Ih,mv$+J]p2I=ɫtQ@Q@Q@Q@Q@Q@fj:tplF >\$` BItPM;QRi#WH˚ @C `  A R Y3\.2Gƛ>rDwO&8%XP@ =;QRi#WH˚ @C `  A R EPEPEPEPEP&D_UKUE`o/4OEQ h?a[P&D_UKUE`o/4OEQ h?a[P&D_Ufk= CeHK}"c䒻rC3%ro$y`A XӴtv6y$甃$v 0 [/+OK[_hg1$bXbI%$I$ Ѣ/* M%CF?7 ' "z_4h0 Ѣ/* M%CF?7 ' "z_4h0 Ѣ/* M%CF?7 ' "z_4h0 Ѣ/* M%CF?7 ' "z_4h0Gkth11ϟQGq$r`U% $ 4P5eW?$:]l{ؕсA*zA h?aV/-i&%ؐ>e O "r![qVUhVo `pU A(# Ѣ/*M%CFޢ07 ' "_4h0( Ѣ/*M%CFޢ07 ' "i:ϛY_yX>pq8?PEPEPEPY2\.*IȻpLvG&8!T\;3%ro$y`A XӴtv6y$ɧ$v 0Nӡm8G&R H@؀p-EQEQEQEQEQEQEQEQEQE{eqgv_k ]0IY@8 V h W]Zɾ'pUVTA{eqgv_k(`2 p@ ӵu+v5x䍌sA(Hd#8 !*A 袊((((M&2B$,ĐI$ 4=bϩͩIQ\ߘ$p2U<0:hv;62rߟj!$$qơU ;Pvn$? spriteshow

    Spriteshow

    Format

    spriteshow spritenumber
    spriteshow ( spritenumber )

    Description

    Show a hidden sprite.

    See Also

    Spritecollide, Spritedim, Spriteh, Spritehide, Spriteload, Spritemove, Spriteplace, Spriteslice, Spritev, Spritew, Spritex, Spritey

    New To Version

    0.9.6n help/fr/onerror.html0000664000175000017500000000172511722507500013117 0ustar jimjim
    onerror

    OnError

    Format

    onerror label

    Description

    Causes the subroutine at label to be executed when an runtime error occurs. Program control may be resumed at the next statement with a Return statement in the subroutine.

    Example

    See example of usage on Error Codes page.

    See Also

    Error Codes, Lasterror, Lasterrorextra, Lasterrorline, Lasterrormessage, Offerror

    New To Version

    0.9.6z help/fr/spritew.html0000664000175000017500000000166511722507500013131 0ustar jimjim
    spritew

    Spritew

    Format

    spritew ( spritenumber )

    Description

    Returns the width, in pixels, of a loaded sprite.

    See Also

    Spritecollide, Spritedim, Spriteh, Spritehide, Spriteload, Spritemove, Spriteplace, Spriteshow, Spriteslice, Spritev, Spritex, Spritey

    New To Version

    0.9.6n help/fr/fornext.html0000664000175000017500000000214311722507500013111 0ustar jimjim
    fornext

    For / Next

    Format

    for variable = expression1 to expression2 [ step expression3 ]
    statement(s)
    next variable

    Description

    The FOR and NEXT commands are used in conjunction to execute a command or group of commands a specified number of times. When the FOR command is first encountered, the variable is set to expresssion1.
    After each NEXT command, variable is incremented by 1 (the default), or by expression3 if the optional STEP is used, until variable is greater than or equal to expression2 for positive step values, or less than or equal to expression2 for negative step values.

    See Also

    Do / Until, While / End While help/fr/spritehide.html0000664000175000017500000000175511722507477013611 0ustar jimjim
    spritehide

    Spritehide

    Format

    spritehide spritenumber spritehide ( spritenumber )

    Description

    Hides a sprite. All image and position information is retained.

    See Also

    Spritecollide, Spritedim, Spriteh, Spriteload, Spritemove, Spriteplace, Spriteshow, Spriteslice, Spritev, Spritew, Spritex, Spritey

    New To Version

    0.9.6n help/fr/close.html0000664000175000017500000000155311722507477012552 0ustar jimjim
    close

    Close

    Format

    close
    close ( )
    close filenumber
    close ( filenumber )

    Description

    Ferme un fichier ouvert. Di aucun fichier n'est ouvert à ce numéro, la commande n'a aucun effet. Si aucun numéro de fichier n'est spécifié, le numéro de fichier utilisé sera le zéro.

    Voir aussi

    Eof, Open, Read, Readline, Reset, Write, Writeline help/fr/month.html0000664000175000017500000000155311722507477012572 0ustar jimjim
    month

    Month

    Format

    month
    month()

    Description

    Returns the current system clock's month. January is 0, February is 1... December is 11.

    See Also

    Day, Hour, Minute, Second, Year

    Example

    cls
    dim n$(12)
    n$ = {"Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"}
    print day + "-" + n$[month] + "-" + year
    
    on New Years will display
    1-Jan-2010
    

    New To Version

    0.9.4 help/fr/programsyntax.html0000664000175000017500000000067411722507500014351 0ustar jimjim
    programsyntax

    Syntaxe du programme

    Les programmes sous BASIC-256 sont formés d'une série d'instructions séparées par un retour à la ligne et qui sont exécutées dans l'ordre. help/fr/write.html0000664000175000017500000000167211722507477012601 0ustar jimjim
    write

    Write

    Format

    write string
    write ( string )
    write filenumber, string
    write ( filenumber, string )

    Description

    Writes string to the end of an open file. If the file number is not specified file number zero (0) will be used.

    See Also

    Close, Eof, Open, Read, Readline, Reset, Writeline, Exists, Seek, Size help/fr/netclose.html0000664000175000017500000000163011722507477013255 0ustar jimjim
    netclose

    NetClose

    Format

    netclose
    netclose ( )
    netclose socket_number
    netclose ( socket_number )

    Description

    Close the specified network connection (socket). If socket_number is not specified socket number zero (0) will be used.

    Example

    See example of usage on NetConnect page.

    See Also

    NetConnect, NetData, NetListen, NetRead, NetWrite

    New To Version

    0.9.6.31 help/fr/clicky.html0000664000175000017500000000150111722507477012714 0ustar jimjim
    clicky

    Clicky

    Format

    clicky
    clicky ( )

    Description

    Retourne l'ordonnée y du pointeur de la souris sur la surface graphic output au dernier clic.

    Voir aussi

    Clickclear, Clickb, Clickx, Mouseb, Mousex, Mousey

    Exemple

    Voir le programme sur la page de Clickb.

    Disponible à partir de la version

    0.9.4d help/fr/variables.html0000664000175000017500000000155211722507500013377 0ustar jimjim
    variables

    Variables

    Le nom des variables contenant des valeurs numériques doit commencer par une lettre et peut comporter n'importe quel nombre de caractères alpha-numériques. Il est sensible à la casse (on différencie majuscule et minuscule). Il peut être utilisé en alternance de constantes numériques (i.e. on peut passer de l'un à l'autre, les deux se valent).

    Le nom des variables contenant des chaînes de caractères suit les mêmes règles que celui des variables numériques, mais doit finir par un symbole dollar ($). Il peut, lui aussi, être utilisé en alternance de constantes. help/fr/singlepage.html0000664000175000017500000001440511675357461013566 0ustar jimjim
    singlepage
    ~~ODT~~

    BASIC-256 Syntax Reference

    page>programsyntax page>numericconstants page>stringconstants page>variables page>arrays page>anonymousarrays page>operators

    Statements and Functions - Alphabetic

    page>abs page>acos page>asc page>asin page>atan page>ceil page>changedir page>chr page>circle page>clickb page>clickclear page>clickx page>clicky page>clg page>close page>cls page>color page>cos page>currentdir page>day page>dbclose page>dbcloseset page>dbexecute page>dbfloat page>dbint page>dbopen page>dbopenset page>dbrow page>dbstring page>degrees page>dim page>dountil page>end page>eof page>exists page>fastgraphics page>float page>floor page>font page>fornext page>getcolor page>getslice page>goto page>gosubreturn page>graphheight page>graphsize page>graphwidth page>hour page>instr page>int page>ifthen page>imgload{{page>Input}} page>key page>lasterror page>lasterrorextra page>lasterrorline page>lasterrormessage page>left page>length page>line page>log page>log10 page>lower page>mid page>minute page>month page>mouseb page>mousex page>mousey page>netclose page>netconnect page>netdata page>netlisten page>netread page>netwrite page>open page>offerror page>onerror page>pause page>pixel page>plot page>poly page>print page>putslice page>radians page>rand page>read page>readline page>rect page>redim page>refresh page>rem page>reset page>rgb page>right page>say page>second page>seek page>sin page>size page>sound page>spritecollide page>spritedim page>spriteh page>spritehide page>spriteload page>spritemove page>spriteplace page>spriteshow page>spriteslice page>spritev page>spritew page>spritex page>spritey page>stamp page>string page>system page>tan page>text page>upper page>volume page>wavplay page>wavstop page>whileendwhile page>write{{page>Writeline}} page>year help/fr/arrays.html0000664000175000017500000000162211722507500012726 0ustar jimjim
    arrays

    Tableaux

    Les tableaux sot affectés à l'aide de la commande DIM ou redimensionnés avec Redim. Ils peuvent contenir des données numériques ou des chaînes de caractères. Pour accéder à un élément donné d'un tableau on utilise les crochets "[ et ]" autour du rang de l'élément voulu (la numérotation partant de zéro). Les tableaux peuvent aussi dimensionnés et interrogés sur 2 dimensions.
    Le taille d'un tableau peut être retournée par une des commandes suivantes : [?] [?,] ou [,?] à la fin du nom du tableau.

    Exemple

    print myarray[4]
    
    affichera à l'écran le 5eme élément du tableau 'myarray' help/fr/upper.html0000664000175000017500000000112211722507477012570 0ustar jimjim
    upper

    Upper

    Format

    upper ( string )

    Description

    Returns string with all alphabetic characters converted to upper case.

    See Also

    Lower

    Example

    print upper("BlUe!")
    
    will display
    BLUE!
    

    New To Version

    0.9.5e help/fr/stringconstants.html0000664000175000017500000000066011722507477014706 0ustar jimjim
    stringconstants

    Constantes chaînes de caractères

    Les (constantes) chaînes de caractères sont composées de zéro ou plus de caractères entourés de guillemets ("). help/fr/tan.jpg0000664000175000017500000001326311722507500012027 0ustar jimjimJFIF``C    $.' ",#(7),01444'9=82<.342C  2!!22222222222222222222222222222222222222222222222222,-" }!1AQa"q2#BR$3br %&'()*456789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz w!1AQaq"2B #3Rbr $4%&'()*56789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz ? ( ( ( ( ( qmr?)mm/zf3D tsN`/4bD:8ޢ((((((((('x0IkDQI'ެ~6iŽRw̆)ߞ2K#svoPEPEPEPEPEPEPEPEPX:_Úڿ4NQfE2IOiq2j>at'@ ` ( ( ( ( ( ( ( ( (0|GwjHf+9 _5r P+zkzoƉy|'SaH#VTGZ4=Kg@uO+mWV7lg83@袊(((((((+//\E=JfENdGaYPy$G/$F-o⅀ i#b^oQEQEQEQEQEQEQEQEQEVj!b3y?6l`V)~2&;Q*f oQEQEQEQEQEQEQEQEUMWNW/tˆuKy2u*H#8>n6CqrH[܈ D2Iٽny3i K|c{iբ7z!2Lz m@Q@Q@Q@Q@Q@Q@Q@Q@A}eoi67q1427#dr8'OEdvOO3Q]

    fR>Q@<7V[ʒ*H2AGzZyukk7(((((((()۳c/ˤJܵb[%vX TVscwmsC*n#r0!G#zU ۋ}@hmϔ[\1)Ubp)t \e5((((((((x!$TȡԌA;VN">]G$gy 3d\oPEPEPEPEPEPEPEPEPEP IM5lM6ݕ.c% 2K 5Y60dK\YY @FwƗëi+L1x#NH*ñv tQEQEQEQEQEQEQEQEG<[oqK RHPF A'ÓE%$K RO,YxfDmVB_O(ѯ6xVmpǩ ( ( ( ( ( ( ( ( ( _m_M?,W5aW%D^t1r29m/$F-o⅀ i#b^oQEQEQEQEQEQEQEQETs ռ$ʥ$E `ڤ1|+<Ϡiu+yX@Q@Q@Q@Q@Q@Q@Q@Q@`1׭$p?mnp@Ղ?g?\n

    writeline

    Writeline

    Format

    writeline string
    writeline ( string )
    writeline filenumber, string
    writeline ( filenumber, string )

    Description

    Writes string append with a newline character to the end of an open file. If the file number is not specified file number zero (0) will be used.

    See Also

    Close, Eof, Open, Read, Readline, Reset, Write, Exists, Seek, Size

    New To Version

    0.9.4 help/fr/imgload.html0000664000175000017500000000242111722507477013054 0ustar jimjim
    imgload

    Imgload

    Format

    imgload x, y, filename
    imgload x, y, scale, filename
    imgload x, y, scale, rotation, filename

    Description

    Load an image or picture from a file and paint it on the Graphics Output Window.
    The parameters x and y represent the location on the screen for the CENTER of the loaded image. This behaviour is different than all of the other graphics statements. The axis of rotation will also be this CENTER point.
    The Imgload starement will read in most common image file formats including: BMP (Windows Bitmap), GIF (Graphic Interchange Format),JPG/JPEG (Joint Photographic Experts Group), and PNG (Portable Network Graphics).
    Optionally scales size of the loaded image by the defined scale (1=normal size). Also optionally rotates the image by a specified angle around the images center (clockwise in radians).

    New To Version

    0.9.6l help/fr/fonttext.png0000664000175000017500000001635611722507500013132 0ustar jimjimPNG  IHDR,,"sRGB pHYs  tIME1+ktEXtCommentCreated with GIMPW[IDATxiXg8[DhFEhr9c3Lvslfvwdgdlٍ715Q(*rGsu]v7Ѐ`'zߢUԞ={:4BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB                    pClo_/9jǷoO,-򎦿܅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l̘.ΡԗRZ*]D4_ uZ^|r"ɢžRԷ.r1.;c,z'ki2鲍ʍVB Vn,A a>}L@ϯT*Yw\4\_gg!Jwzq2αVxu3‰m]W^q܁37ݶm̨0n3Pn#cmg:XYm^(Yѱc%%*$LRqUvkۜ2y~L >hOKoc~;QMSO5?_kz-|LX4?k0uuZv9,űda2,Id@n[i4E)~'$ŏs7^iڲ!+f3ҥmg*92de8\?uÁ}piXmTe*[y!X?^;G t{&!"_履>'f.u[h8:Vi.zl=oi߲1 [yܝL߅%U*qy-SGT{[B.u{unuu|7Ywrco NjKE(W bPY`+C c"x-1n^"Z4^^| U*^Bhcl+^@ hP2\2s PAcp3W j2!-;[۲%$Q<+z H Olx;zTׁӷm󝐸nyy<_ bcv-͇jFg>wΔd[f1- #5j! Ѳ)ŘpM|)U&_͗_|>sUPВ q1/Rc49tZ;W7BX/X.lK!ͽW򡗣_:^{3Z`+{˗.jɾY&ܾH&ONBzS@ fĴxtqz8}1p|m9r,M=(~SBH(/tY86CⲌ?{|p qSܟdo0njjX[NNo^5[g ;}2 ,qևC+e=?D4 ~<}k߲tdS愐DAb q+d~ !OS))”kK۫gr791[/"[]f~%dabb[ӿ[ AO}[x8 \e<!3P3(.{ƏKqBF#|E+ar9R'|S w}{hE"}MKpB|ڎ\&M[o{`Y1;}å?q| EExAgB}Gyx>;f5g;eka,?ɰ'Zdt{Yfm#9ᒱw5Oߎ,3zr]~{cdžBxOD}"IUh;<>;J* m6g,f#(B]%I]=&3vN~9'0uǔ)|&>'*d⟩klTl|T013Чf7
    wavstop

    WAVstop

    Format

    wavstop

    Description

    Stop playing the current asynchronous (background) WAV audio file.

    See Also

    WAVplay WAVwait

    New To Version

    0.9.4 help/fr/seek.html0000664000175000017500000000203711722507477012372 0ustar jimjim
    seek

    Seek

    Format

    seek location
    seek ( location )
    seek filenumber, location
    seek ( filenumber, location )

    Description

    Moves the read/write location to a specific location (offset in bytes from the start of the file) within an open file. If the file number is not specified file number zero (0) will be used.

    See Also

    Close, Eof, Open, Read, Readline, Reset, Write, Writeline, Exists, Size

    New To Version

    0.9.4 help/fr/line.png0000664000175000017500000000210211722507500012166 0ustar jimjimPNG  IHDR,,"sRGB pHYs  tIME'ޜtEXtCommentCreated with GIMPWIDATxֱA$AAiE4C"",uw B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B! B!'#|ǿ "! Gxw:Duu~CD|:DtCP0{&b!"ta>B"Df:D!GCDL=ui0a"*"B#!"LCD|:DtCP0{&!"t!:DltCDa!"BCDXHE=D"!"t!:D
    offerror

    OffError

    Format

    offerror

    Description

    Turns off error trapping and restores the default error behavior.

    Example

    See example of usage on Error Codes page.

    See Also

    Error Codes, Lasterror, Lasterrorextra, Lasterrorline, Lasterrormessage, Onerror

    New To Version

    0.9.6z help/fr/style.css0000664000175000017500000001445411722507500012420 0ustar jimjimhtml {padding: 5px 5px 5px 5px;font-size: medium;font: 100% Arial,Helvetica,sans-serif} h2 {font-size: x-large;} h3 {font-size: medium;color: gray} b {font-weight: bold} pre {margin: 10px 10px 10px 10px;padding: 10px 5px 10px 5px;border: 1px dashed #808080;background: #cccccc;color: #000000;} img {margin: 10px 10px 10px 10px; border: 1px dashed #808080;} html {padding: 5px 5px 5px 5px;font-size: medium;font: 100% Arial,Helvetica,sans-serif} h2 {font-size: x-large;} h3 {font-size: medium;color: gray} b {font-weight: bold} pre {margin: 10px 10px 10px 10px;padding: 10px 5px 10px 5px;border: 1px dashed #808080;background: #cccccc;color: #000000;} img {margin: 10px 10px 10px 10px; border: 1px dashed #808080;} html {padding: 5px 5px 5px 5px;font-size: medium;font: 100% Arial,Helvetica,sans-serif} h2 {font-size: x-large;} h3 {font-size: medium;color: gray} b {font-weight: bold} pre {margin: 10px 10px 10px 10px;padding: 10px 5px 10px 5px;border: 1px dashed #808080;background: #cccccc;color: #000000;} img {margin: 10px 10px 10px 10px; border: 1px dashed #808080;} html {padding: 5px 5px 5px 5px;font-size: medium;font: 100% Arial,Helvetica,sans-serif} h2 {font-size: x-large;} h3 {font-size: medium;color: gray} b {font-weight: bold} pre {margin: 10px 10px 10px 10px;padding: 10px 5px 10px 5px;border: 1px dashed #808080;background: #cccccc;color: #000000;} img {margin: 10px 10px 10px 10px; border: 1px dashed #808080;} html {padding: 5px 5px 5px 5px;font-size: medium;font: 100% Arial,Helvetica,sans-serif} h2 {font-size: x-large;} h3 {font-size: medium;color: gray} b {font-weight: bold} pre {margin: 10px 10px 10px 10px;padding: 10px 5px 10px 5px;border: 1px dashed #808080;background: #cccccc;color: #000000;} img {margin: 10px 10px 10px 10px; border: 1px dashed #808080;} html {padding: 5px 5px 5px 5px;font-size: medium;font: 100% Arial,Helvetica,sans-serif} h2 {font-size: x-large;} h3 {font-size: medium;color: gray} b {font-weight: bold} pre {margin: 10px 10px 10px 10px;padding: 10px 5px 10px 5px;border: 1px dashed #808080;background: #cccccc;color: #000000;} img {margin: 10px 10px 10px 10px; border: 1px dashed #808080;} html {padding: 5px 5px 5px 5px;font-size: medium;font: 100% Arial,Helvetica,sans-serif} h2 {font-size: x-large;} h3 {font-size: medium;color: gray} b {font-weight: bold} pre {margin: 10px 10px 10px 10px;padding: 10px 5px 10px 5px;border: 1px dashed #808080;background: #cccccc;color: #000000;} img {margin: 10px 10px 10px 10px; border: 1px dashed #808080;} html {padding: 5px 5px 5px 5px;font-size: medium;font: 100% Arial,Helvetica,sans-serif} h2 {font-size: x-large;} h3 {font-size: medium;color: gray} b {font-weight: bold} pre {margin: 10px 10px 10px 10px;padding: 10px 5px 10px 5px;border: 1px dashed #808080;background: #cccccc;color: #000000;} img {margin: 10px 10px 10px 10px; border: 1px dashed #808080;} html {padding: 5px 5px 5px 5px;font-size: medium;font: 100% Arial,Helvetica,sans-serif} h2 {font-size: x-large;} h3 {font-size: medium;color: gray} b {font-weight: bold} pre {margin: 10px 10px 10px 10px;padding: 10px 5px 10px 5px;border: 1px dashed #808080;background: #cccccc;color: #000000;} img {margin: 10px 10px 10px 10px; border: 1px dashed #808080;} html {padding: 5px 5px 5px 5px;font-size: medium;font: 100% Arial,Helvetica,sans-serif} h2 {font-size: x-large;} h3 {font-size: medium;color: gray} b {font-weight: bold} pre {margin: 10px 10px 10px 10px;padding: 10px 5px 10px 5px;border: 1px dashed #808080;background: #cccccc;color: #000000;} img {margin: 10px 10px 10px 10px; border: 1px dashed #808080;} html {padding: 5px 5px 5px 5px;font-size: medium;font: 100% Arial,Helvetica,sans-serif} h2 {font-size: x-large;} h3 {font-size: medium;color: gray} b {font-weight: bold} pre {margin: 10px 10px 10px 10px;padding: 10px 5px 10px 5px;border: 1px dashed #808080;background: #cccccc;color: #000000;} img {margin: 10px 10px 10px 10px; border: 1px dashed #808080;} html {padding: 5px 5px 5px 5px;font-size: medium;font: 100% Arial,Helvetica,sans-serif} h2 {font-size: x-large;} h3 {font-size: medium;color: gray} b {font-weight: bold} pre {margin: 10px 10px 10px 10px;padding: 10px 5px 10px 5px;border: 1px dashed #808080;background: #cccccc;color: #000000;} img {margin: 10px 10px 10px 10px; border: 1px dashed #808080;} html {padding: 5px 5px 5px 5px;font-size: medium;font: 100% Arial,Helvetica,sans-serif} h2 {font-size: x-large;} h3 {font-size: medium;color: gray} b {font-weight: bold} pre {margin: 10px 10px 10px 10px;padding: 10px 5px 10px 5px;border: 1px dashed #808080;background: #cccccc;color: #000000;} img {margin: 10px 10px 10px 10px; border: 1px dashed #808080;} html {padding: 5px 5px 5px 5px;font-size: medium;font: 100% Arial,Helvetica,sans-serif} h2 {font-size: x-large;} h3 {font-size: medium;color: gray} b {font-weight: bold} pre {margin: 10px 10px 10px 10px;padding: 10px 5px 10px 5px;border: 1px dashed #808080;background: #cccccc;color: #000000;} img {margin: 10px 10px 10px 10px; border: 1px dashed #808080;} html {padding: 5px 5px 5px 5px;font-size: medium;font: 100% Arial,Helvetica,sans-serif} h2 {font-size: x-large;} h3 {font-size: medium;color: gray} b {font-weight: bold} pre {margin: 10px 10px 10px 10px;padding: 10px 5px 10px 5px;border: 1px dashed #808080;background: #cccccc;color: #000000;} img {margin: 10px 10px 10px 10px; border: 1px dashed #808080;} html {padding: 5px 5px 5px 5px;font-size: medium;font: 100% Arial,Helvetica,sans-serif} h2 {font-size: x-large;} h3 {font-size: medium;color: gray} b {font-weight: bold} pre {margin: 10px 10px 10px 10px;padding: 10px 5px 10px 5px;border: 1px dashed #808080;background: #cccccc;color: #000000;} img {margin: 10px 10px 10px 10px; border: 1px dashed #808080;} html {padding: 5px 5px 5px 5px;font-size: medium;font: 100% Arial,Helvetica,sans-serif} h2 {font-size: x-large;} h3 {font-size: medium;color: gray} b {font-weight: bold} pre {margin: 10px 10px 10px 10px;padding: 10px 5px 10px 5px;border: 1px dashed #808080;background: #cccccc;color: #000000;} img {margin: 10px 10px 10px 10px; border: 1px dashed #808080;} html {padding: 5px 5px 5px 5px;font-size: medium;font: 100% Arial,Helvetica,sans-serif} h2 {font-size: x-large;} h3 {font-size: medium;color: gray} b {font-weight: bold} pre {margin: 10px 10px 10px 10px;padding: 10px 5px 10px 5px;border: 1px dashed #808080;background: #cccccc;color: #000000;} img {margin: 10px 10px 10px 10px; border: 1px dashed #808080;} help/fr/minute.html0000664000175000017500000000222411722507500012725 0ustar jimjim
    minute

    Minute

    Format

    minute
    minute()

    Description

    Returns the current system clock's minute of the hour (0-59).

    Example

    # display nice date
    dim months$(12)
    months$ = {"January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"}
    print year + "-" + months$[month] + "-" + right("0" + day, 2)
    # display pretty time
    h = hour
    if h > 12 then
    h = h - 12
    ampm$ = "PM"
    else
    ampm$ = "AM"
    end if
    if h = 0 then h = 12
    print  right("0" + h, 2) + "-" + right("0" + minute, 2) + "-" + right("0" + second, 2) + " " + ampm$
    
    Will print something like.
    2010-July-15
    10-00-02 PM
    

    See Also

    Day, Hour, Month, Second, Year

    New To Version

    0.9.4 help/fr/spritey.html0000664000175000017500000000162411722507477013143 0ustar jimjim
    spritey

    Spritey

    Format

    spritey ( spritenumber )

    Description

    Returns the y coordinate of the center of a loaded sprite.

    See Also

    Spritecollide, Spritedim, Spriteh, Spriteload, Spritemove, Spriteplace, Spriteshow, Spriteslice, Spritev, Spritew, Spritex

    New To Version

    0.9.6n help/fr/spritex.html0000664000175000017500000000167611722507477013151 0ustar jimjim
    spritex

    Spritex

    Format

    spritex ( spritenumber )

    Description

    Returns the x coordinate of the center of a loaded sprite.

    See Also

    Spritecollide, Spritedim, Spriteh, Spritehide, Spriteload, Spritemove, Spriteplace, Spriteshow, Spriteslice, Spritev, Spritew, Spritey

    New To Version

    0.9.6n help/fr/dbopen.html0000664000175000017500000000417211722507477012714 0ustar jimjim
    dbopen

    DBOpen

    Format

    dbopen SQLiteFile
    dbopen ( SQLiteFile )

    Description

    Ouvre un fichier de base de données SQLite. Si le fichier n'existe pas, il est créé.

    Exemple

    #database foo - crée une base de données, peuple une table, ouvre un enregistrement et lit les données de la table.
    
    # crée un nouveau fichier de base de données ou l'ouvre
    dbopen "dbtest.sqlite3"
    
    # efface l'ancienne foo table - renvoie une erreur si c'est une nouvelle base de données
    onerror errortrap
    dbexecute "drop table foo;"
    offerror
    # crée et peuple
    dbexecute "create table foo (id integer, words text, value decimal);"
    dbexecute "insert into foo values (1,'one',3.14);"
    dbexecute "insert into foo values (2,'two',6.28);"
    dbexecute "insert into foo values (3,'three',9.43);"
    
    # ouvre un enregistrement et tourne en boucle  à travers les lignes de données
    dbopenset "select * from foo order by words;"
    while dbrow()
    	print dbint(0) + dbstring(1) + dbfloat(2)
    end while
    dbcloseset
    
    # rassemble tout
    dbclose
    end
    
    errortrap:
    # accepte l'erreur - n'affiche rien - va à la prochaine commande
    return
    
    affichera
    1one3.14
    3three9.43
    2two6.28
    

    Voir aussi

    DBClose, DBCloseSet, DBExecute, DBFloat, DBInt, DBOpenSet, DBRow, DBString

    Lien externes

    De plus amples informations (en anglais) sur les bases de données en général et SQLite en particulier, sont disponibles aux adresses suivantes : Page d'accueil de SQLite et SQL sur Wikipedia.

    Disponible à partir de la version

    0.9.6y help/fr/gosubreturn.html0000664000175000017500000000116711722507477014025 0ustar jimjim
    gosubreturn

    Gosub / Return

    Format

    gosub label

    label:
    statement(s)
    return

    Description

    Jumps to the specified label. Upon encountering a RETURN command, program execution will continue at the line following the GOSUB. GOSUB commands may be nested.

    See Also

    Goto help/fr/chr.html0000664000175000017500000000132211722507477012213 0ustar jimjim
    chr

    Chr

    Format

    chr ( expression )

    Description

    Converti l'entier expression en le caractère correspondant en code ASCII. Voir la page consacrée à asc pour un tableau de converson des caractères ASCII.

    Voir aussi

    Asc

    Exemple

    print chr(66)+chr(111)+chr(111)+chr(33)
    
    affichera
    Boo!
    

    Disponible à partir de la version

    0.9.4 help/fr/system.html0000664000175000017500000000106611722507477012770 0ustar jimjim
    system

    System

    Format

    system expression
    system ( expression )

    Description

    Execute a system command in a terminal window. WARNING: This can be a very dangerous statement. Only use it if you know what you are doing.

    New To Version

    0.9.5h help/README.txt0000664000175000017500000000236311675357462011652 0ustar jimjimREADME - doc/help 2011-05-01 j.m.reneau The doc folder contains several folders folders: ./[de|en|fr|ru|es] - the html and image files that will be distributed with the windows installer these dosuments should not be edited but are generated by the wiki2html.kbs program media/[de|en|fr|ru|es] - these folders should mirror the docuwiki folders at wiki/data/media/[de|en|fr|ru] and should contain the image files used for each of the languages pages/[de|en|fr|ru|es] - these folders should mirror the docuwiki folders at wiki/data/pages/[de|en|fr|ru] and coutain the plain text source of the wiki pages writen in the docuwiki layout. To build current off-line help: 1) download from the docuwiki server 1.a) wiki/data/media/[de|en|fr|ru|es] to doc/help/media/[de|en|fr|ru|es] 1.a) wiki/data/pages/[de|en|fr|ru|es] to doc/help/pages/[de|en|fr|ru|es] 2) with BASIC256 load and run the program wiki2html.kbs. this program will translate the docuwiki formatted text files in pages into html and will copy the required image files from media to the doc/help/language folders. NOTE: Please maintain all documentation on the documentation wiki and follow this process to generate the offline documentation files. help/nl/0000775000175000017500000000000011722503650010542 5ustar jimjimhelp/nl/netaddress.html0000664000175000017500000000160311722507504013566 0ustar jimjim
    netaddress

    NetAddress

    Formaat

    netaddress
    netaddress ( )

    Beschrijving

    De Functie geeft het IPv4 address terug van deze comuter op het locale netwerk.

    Voorbeeld

    print "Mijn netwerk adress is:" + netaddress
    

    Zie ook

    NetClose, NetConnect, NetData, NetListen, NetRead, NetWrite

    Nieuw vanaf

    0.9.6.35
    Netwerk | volgende help/nl/whileendwhile.html0000664000175000017500000000212111722507504014256 0ustar jimjim
    whileendwhile

    While / End While

    Formaat

    while booleanuitdrukking
    opdracht(en)
    end while

    Beschrijving

    Voert de opdracht(en) in de lus uit tot booleanuitdrukking false is. While / End While voert de opdracht(en) nul of meerdere keren uit. De test wordt uitgevoerd voor er aan de opdrachten wordt begonnen. Dit wil zeggen dat het mogelijk is dat de opdracht(en) zelfs misschien helemaal niet worden uitgevoerd.

    Zie ook

    Do / Until, For / Next

    Voorbeeld

    r = 1
    while r < 6
      print r
      r = r + 1
    end while
    
    geeft als resultaat
    1
    2
    3
    4
    5
    

    Vanaf versie

    0.9.4g
    vorige | Programma Controle help/nl/degrees.html0000664000175000017500000000164311722507506013056 0ustar jimjim
    degrees

    Degrees

    Formaat

    degrees ( expression )

    Beschrijving

    radians.png Deze functie converteert een hoek in radianen naar graden.

    Voorbeeld

    print 2*pi print degrees(2*pi) geeft dan
    6.283185
    360
    

    Zie ook

    Acos, Asin, Atan, Cos, Radians, Sin, Tan
    vorige | Wiskundige Functies | volgende help/nl/datehour.html0000664000175000017500000000253111722507505013247 0ustar jimjim
    datehour

    Datum en Uur

    Waarom

    In een computer zit (bijna) altijd een klok. Meestal is deze klok altijd correct ( er zit een klein batterijtje in de computer zodat de klok gelijk blijft, zelfs al staat je computer uit. Een computer is ook slim genoeg om met datum en uur te kunnen werken. Vind je kloklezen een beetje moeilijk? De computer in elk geval niet. Hierna vind je de nodige commando's om iets met uur en datum te kunnen doen.

    Welke opdrachten hebben we?

    OpdrachtWat doet het
    Day de dag van 1 tot 31 <
    Month maand van 0 tot 11 :!:
    Year jaartallen in 4 getallen
    Hour het uur van 0 tot 23 <
    Minute minuten van 0 to 59 <
    Second seconden van 0 tot 59
    Millisecond millisconden 0 tot 999

    Begin help/nl/log10.html0000664000175000017500000000132011722507504012350 0ustar jimjim
    log10

    Log10

    Formaat

    log10 ( expression )

    Beschrijving

    De functie geeft de logaritme met grondtal 10 terug van expression.

    Voorbeeld

    a= 10000
    print a
    print log10(a)
    
    geeft
    10000
    4
    
    

    Zie ook

    Log

    Niew vanaf

    0.9.5w
    vorige | Wiskundige Functies | volgende help/nl/redim.html0000664000175000017500000000206211722507505012533 0ustar jimjim
    redim

    Redim

    Formaat

    redim numeriekevariable( getal )
    redim stringvariable$( getal )
    redim numeriekevariable( rijen , kolommen )
    redim stringvariable$( rijen , kolommen )

    Beschrijving

    De functie past de dimensie aan van een eerder aangemaakte tabel, mét behoud van gegevens.
    Indien de array groter wordt, dan worden de nieuwe elementen in de tabel met 0 of met '' ( lege string) geïnitialiseerd. Wordt de tabel kleiner, dan verwijnen de elementen op het einde.

    Voorbeeld

    uit te werken
    

    Zie Ook

    Dim

    Nieuw vanaf

    0.9.5t
    volgende| Tabellen help/nl/rect.html0000664000175000017500000000166511722507506012401 0ustar jimjim
    rect

    Rect

    Formaat

    rect x,y,breedte,hoogte
    rect ( x, y, breedte,hoogte )

    Bescrhijving

    De functie tekent een vierhoek van breedte x hoogte pixels met in kleur van het potlood. De Linkerhoek van de vieruhoek bevindt zich op x,y.

    Voorbeeld

    color white
    rect 0,0,300,300
    color red
    rect 50,50,150,150
    color blue
    rect 100,100,150,150
    color green
    rect 10,140,280,20
    
    geeft dan
    rect.png
    vorige | Tekenen en kleuren | volgende help/nl/netread.html0000664000175000017500000000215711722507505013062 0ustar jimjim
    netread

    NetRead

    Formaat

    netread
    netread ( )
    netread ( socket_number )

    Beschrijving

    De functie leest de data van de open netwerk connectie op socket_number en geeft die terug als string.
    De functie wacht tot er data is ontvangen. Indien er geen socket_number werd meegegeven, wordt 0 gebruikt.

    Voorbeeld

    Voorbeeld uitgewerkt op NetConnect .

    Zie ook

    NetAddress, NetClose, NetConnect, NetData, NetListen, NetWrite

    Nieuw vanaf

    0.9.6.31
    vorige | Netwerk | volgende help/nl/length.html0000664000175000017500000000137411722507506012722 0ustar jimjim
    length

    Length

    Formaat

    length( string )

    Beschrjiving

    Deze functie geeft het aantal karakters van de string string

    Voorbeel

    a$= "Hoe lang is dit zinnetje nu?"
    print a$
    print "de string a is " + length(a$) + " karakters lang."
    
    geeft dan
    Hoe lang is dit zinnetje nu?
    de string a is 28 karakters lang.
    

    vorige | Stringbewerkingen | volgende help/nl/mouseb.html0000664000175000017500000000216011722507505012724 0ustar jimjim
    mouseb

    Mouseb

    Formaat

    mouseb
    mouseb()

    Beschrijving

    De functie geeft de huidige knop weer die ingedrukt wordt, naar analogie van clickb, alleen gaat het hier over de knop die op het moment zelf wordt ingedukt.
    Resultaten
    WaardeMuisknop die wordt ingedrukt
    0Geen
    1Links
    2Rechts
    4Midden

    Zie ook

    Clickb, Clickclear, Clickx, Clicky, Mousex, Mousey

    Nieuw vanaf

    0.9.4d
    vorige | Muisbesturing | volgende help/nl/spriteplace.html0000664000175000017500000000262611722507504013753 0ustar jimjim
    spriteplace

    Spriteplace

    Formaat

    spriteplace spritenummer, x, y
    spriteplace ( spritenummer, x, y )

    Bescrhijving

    De functie zet het midden van een sprite op een specifiek plaats op het scherm.
    Naar analogie van de imgload functie, gebrukt deze functie het midden van de sprite en niet de linkerbovenhoek zoals de meeste grafische functies.

    Voorbeeld

    uit te werken
    

    Zie Ook

    Spritecollide, Spritedim, Spriteh, Spritehide, Spriteload, Spritemove, Spriteshow, Spriteslice, Spritev, Spritew, Spritex, Spritey

    Nieuw vanaf

    0.9.6n
    vorige | Tekenen en kleuren | volgende help/nl/pause.html0000664000175000017500000000152511722507505012553 0ustar jimjim
    pause

    Pause

    Formaat

    pause seconden
    pause (seconden)

    Beschrijving

    Laat de computer seconden wachten vooraleer hij de volgende opdracht uitvoert. De seconden waarden mag een decimale waarde zijn, dus je kan tot op de 100e seconde werken.

    Voorbeeld

    Print "Ik begin nu"
    pause 20
    Print "en heb nu na 20 seconden gedaan"
    
    ( pas op, het voorbeeld duurt lang)
    vorige | Programma Controle | volgende help/nl/poly.png0000664000175000017500000000251311722507504012236 0ustar jimjimPNG  IHDR52xsBITOIDATx=j]WFahi=W*H+PeO. BXQty"\|@dz^Oןx헿O't ].}B>KХO't ].}B>KХO't ].}B>KХO't ].}B>KХO't ].}B>KХO't ].}B>KХO't ].}B>KХO't ].}B>KХO't ].}B>KХO't ].}B>K ~wlLХUO}B>|6MB ]`U9kSiBOdI:>KceMp.}a49D:>KӼo ML.}r Ё ]49VgBG'tsmGτΡOgsgB'tm3ę<}B>7ڦOgґfB ]9~Lh>K1gM M't3=.}fp%P=Oٚcռz ]KTy)4EyY4ڵys4%yC4 ]< ~@.}eYsyfggUUfwGf5+x*}B>qaKϠO6)W{ ]5䚯ޟ>K\'ts;ؚ>K1?'ts F9_c;.}\lDХ2['t&|^-|.f|ܟ}LwϾKХO't ].}B>KХO't ].}B>KХO't ].}B>KХO't ].}B>KХO't ].}B>KХO't ].}B>KХO't ].}B>KХO't ].}B>KХO't ].}B>KХO't ].}B>KХO't ].}B>KХO't ].}B>KХO't ].}B>KХO't ].}B>KХO't ]_Nx ̗ϟ~ϿoG}jEIENDB`help/nl/spritev.html0000664000175000017500000000216011722507504013125 0ustar jimjim
    spritev

    Spritev

    Formaat

    spritev ( spritenummer )

    Beschrijving

    De functie geeft aan of de sprite getoond wordt of niet.

    Voorbeeld

    uit te werken
    

    Zie Ook

    Spritecollide, Spritedim, Spritehide, Spriteload, Spritemove, Spriteplace, Spriteshow, Spriteslice, Spriteh, Spritew, Spritex, Spritey

    Nieuw vanaf

    0.9.6n
    vorige | Tekenen en kleuren | volgende help/nl/graphheight.html0000664000175000017500000000264311722507505013732 0ustar jimjim
    graphheight

    Graphheight

    Formaat

    graphheight
    graphheight()

    Beschrijving

    Geeft de hoogte terug (y dimensie) van het huidig grafisch venster.

    Voorbeeld

    Met volgend voorbeeld kleur ik het hele grafisch venster groen.
    • Eerst wordt de grootte en breedte van het venster gezet via graphsize,
    • dan zet ik de tekenkleur op groen via color.
    • Vervolgens maak ik een vierhoek met rect, waarbij de hoogte overeenkomt met het grafisch venster, maar niet de breedte. Die blijft op 50 staan.
    Je kan ook de grootte van de vierkant met getallen invullen, maar dan wordt geen rekening gehouden met het grafisch venster. Als je dan een groter of kleiner venster maakt, klopt je tekening niet meer.
    clg
    graphsize 100,100
    color green
    rect 0,0,50,graphheight
    

    Zie ook

    Graphsize, Graphwidth

    Nieuw vanaf

    0.9.3
    vorige | Tekenen en kleuren | volgende help/nl/msec.html0000664000175000017500000000160511722507504012363 0ustar jimjim
    msec

    Msec

    Formaat

    msec
    msec()

    Beschrijving

    Geeft het aantal milliseconden aan sinds het huidig BASIC256 programma gewerkt heeft.

    Voorbeeld

    cls
    print "We starten nu...."
    pause 5
    print "dit programma wordt al " + msec + " milliseconden uitgevoerd."
    

    Zie ook

    Day, Hour, Minute, Month, Second, Year

    Nieuw Vanaf

    0.9.6.60
    vorige | Datum en Uur help/nl/spritecollide.html0000664000175000017500000000272311722507506014302 0ustar jimjim
    spritecollide

    Spritecollide

    Formaat

    spritecollide ( sprite1, sprite2)

    Beschrijving

    MEt deze functie kan je weten of 2 sprites tegen elkaar botsen of niet. De spritecollide functie veronderstelt dat de 2 sprites met een rechthoek verbonden zijn ter grootte van het opgeladen beeld. De botsin wordt berekend door deze rechthoeken te gebruiken. Voor ronde of rare gevormde slides kan het dus zijn dat deze functie onterechte botsingen detecteerd.

    Voorbeeld

    uit te werken
    

    Zie ook

    Spritedim, Spriteh, Spritehide, Spriteload, Spritemove, Spriteplace, Spriteshow, Spriteslice, Spritev, Spritew, Spritex, Spritey

    Nieuw vanaf

    0.9.6n
    vorige | Tekenen en kleuren | volgende help/nl/spriteload.html0000664000175000017500000000312011722507506013576 0ustar jimjim
    spriteload

    Spriteload

    Formaat

    spriteload spritenumber, filename
    spriteload ( spritenumber, filename )

    Bescrhijving

    De functie laadt een beeld uit een bestand op en bewaart het als sprit. De sprite is dan actief en beweegbaar, maar zal niet op het scherm te zien zijn tot de spriteshow opdracht werd gegeven.
    Spriteload leest de meest gangbare formaten :
    • BMP (Windows Bitmap)
    • GIF (Graphic Interchange Format)
    • JPG/JPEG (Joint Photographic Experts Group)
    • PNG (Portable Network Graphics).

    Voorbeeld

    uit te werken
    

    Zie Ook

    Spritecollide, Spritedim, Spriteh, Spritehide, Spritemove, Spriteplace, Spriteshow, Spriteslice, Spritev, Spritew, Spritex, Spritey

    Nieuw vanaf

    0.9.6n
    vorige | Tekenen en kleuren | volgende help/nl/sqr.html0000664000175000017500000000145611722507504012245 0ustar jimjim
    sqr

    Sqr of Sqrt

    Formaat

    sqr ( expression )
    sqrt ( expression )

    Beschijving

    Geeft de viekantswortel terug van expression((dat een getal moet zijn))

    Voorbeeld

    print sqr(16)
    print sqrt(100)
    print sqr(2)
    
    toont
    4
    10
    1.414214
    

    Nieuw vanaf

    0.9.6.51
    vorige | Wiskundige Functies | volgende help/nl/netlisten.html0000664000175000017500000000230311722507504013435 0ustar jimjim
    netlisten

    NetListen

    Formaat

    netlisten port_number
    netlisten ( port_number)
    netlisten socket_number, port_number
    netlisten ( socket_number, port_number)

    Beschrijving

    De functie opent een netwerk connectie (server) op een specifieke poort en wacht dat een andere programma zich connecteert. Als de socket_number niet gespecifieerd is,wordt 0 gebruikt.

    Voorbeeld

    Voorbeeld uitgewerkt op NetConnect.

    Zie ook

    NetAddress, NetClose, NetConnect, NetData, NetRead, NetWrite

    Nieuw vanaf

    0.9.6.31
    vorige | Netwerk | volgende help/nl/lasterrorline.html0000664000175000017500000000200711722507506014320 0ustar jimjim
    lasterrorline

    LastErrorLine

    Formaat

    lasterrorline
    lasterrorline ( )

    Beschrijving

    Geeft het lijnnummer weer van de lijn in het programma waar de fout zich voordeed.

    Voorbeeld

    Volg het voorbeeld van de foutboodschappen lijst

    Zie Ook

    Error Codes, Lasterror, Lasterrorline, Lasterrormessage, Offerror, Onerror

    Nieuw vanaf

    0.9.6z
    vorige | Foutafhandeling | volgende help/nl/mousex.html0000664000175000017500000000172511722507504012757 0ustar jimjim
    mousex

    MouseX

    Formaat

    mousex
    mousex ( )

    Beschrijving

    De functie geeft de x-coördinaat terug van de plaats waar u nu met de muis staat of waar u het laatst in het grafisch venster hebt geklikt. De x-coördinaat is de horizontale as van links naar rechts.

    Zie ook

    Clickclear, Clickb, Clicky, Mouseb, Mousex, Mousey

    Voorbeeld

    Nieuw vanaf

    0.9.4d
    vorige | Muisbesturing | volgende help/nl/netwrite.html0000664000175000017500000000214011722507504013270 0ustar jimjim
    netwrite

    NetWrite

    Formaat

    netwrite string
    netwrite ( string )
    netwrite socket_number, string
    netwrite ( socket_number, string )

    Beschrijving

    De functie stuurt de string naar het opgegeven socket_number ( open netwerk connectie). Als dit nummer niet is opgegeven, wordt 0 gebruikt.

    Voorbeeld

    Uitgewerkt voorbeeld op NetConnect.

    Zie ook

    NetAddress, NetClose, NetConnect, NetData, NetListen, NetRead

    Nieuw vanaf

    0.9.6.31
    vorige | Netwerk help/nl/dbopenset.html0000664000175000017500000000210111722507504013407 0ustar jimjim
    dbopenset

    DBOpenset

    Formaat

    dbopenset SqlOpdracht
    dbopenset ( SqlOpdracht )

    Beschrijving

    De functie voert een SQLOpdracht uit op de open database en maakt een recordset aan zodat het programma door het resultaat kan.

    Voorbeeld

    Uitgewerkt voorbeeld terug te vinden op DBOpen.

    Zie ook

    DBClose, DBCloseSet, DBExecute, DBFloat, DBInt, DBOpen, DBRow, DBString

    Nieuw vanaf

    0.9.6y
    vorige | Databank | volgende help/nl/glossary.html0000664000175000017500000000211011722507504013267 0ustar jimjim
    glossary

    Moeilijke woorden

    Hierna vind je de lijst van moeilijke of nieuwe woorden die in deze documentatie worden gebruikt. help/nl/putslice.html0000664000175000017500000000172211722507506013266 0ustar jimjim
    putslice

    PutSlice

    Formaat

    putslicex, y, slice$
    putslicex, y, slice$, doorichtige kleur

    Beschrijving

    Met deze functie toon je de tekening die je in een vorge stap in een slice string hebt gezet. Als je transparent meegeeft als kleur, dan worden die punten met die kleur ook niet getoond.

    Voorbeeld

    clg a$= getslice(0,5,10,5) print a$ putslice(10,10,a$)

    Zie Ook

    GetSlice

    Nieuw vanaf

    0.9.6b
    vorige | Tekenen en kleuren | volgende help/nl/fastgraphics.html0000664000175000017500000000216111722507505014111 0ustar jimjim
    fastgraphics

    FastGraphics

    Formaat

    fastgraphics

    Beschrijving

    Met deze functie activeer je de fastgraphics mode tot je Basic-256 verlaat. Met de fastgrpahics mode gaat Basic-256 de grafische output of het grafisch venster, enkel aanpassen wanneer het [refresh]] commando wordt meegegeven. Dit zorgt ervoor dat bij moeilijke en zware animaties het scherm niet begint te flikkeren.

    Opmerking

    Indien je met iets maakt met animatie, is het beter dat je de tekenopdreachten in een subroutine plaatst en een refrech uitvoert nadat al het tekenwerk is gebeurd voor dat frame.

    Voorbeeld

    nog uit te werken
    

    Zie Ook

    Refresh
    vorige | Tekenen en kleuren | volgende help/nl/ceil.html0000664000175000017500000000201611722507505012346 0ustar jimjim
    ceil

    Ceil

    Formaat

    ceil ( uitdrukking )

    Beschrijving

    Afronden naar boven (ceil is het Engelse woord voor Plafond).
    Het getal van de uitdrukking wordt daarbij afgerond naar het laagste gehele getal dat groter is dan of gelijk is aan het oorspronkelijke getal.
    • Voor positieve getallen is het dus 3,14 → 4 en 5,85 → 6.
    • Voor negatieve getallen wordt dezelfde regel toegepast: −4,24 → −4.

    Zie ook

    Floor

    Voorbeeld

    print ceil(9.1)
    print ceil(-5.4)
    
    geeft dan
    10
    -5
    

    vorige | Wiskundige Functies | volgende help/nl/array.png0000664000175000017500000001062411722507505012374 0ustar jimjimPNG  IHDRcL̡sBITOLIDATxyX3 WD i嵛^i;JU*"J(y]pMԲԔܗJTT@Q10Js5MaX~=4:{sTYyQC#)!)!)Gq)&ceRTD]fD (+&{vEԸhR(iQҰ3ƻRS.FEN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cMi16ȊrwRycF|V7%9!ju:|=!9vbXFVv壅)ɺћ7o\*[֜}Mi3:֮]M1cf{V:S3B)*]4BHJ%G !jZ]z~=43(<:+O]6UkJW} gwB̻{5M-xJe!n,S-VkԨ!ȿwOʴY%1"*,Q,E(#z23̼+Q-27leO+ӰQsgΝmԨq6$Xsɗ.گFfW?zy1bhmUXG !^ysssϛ;荷lR4%kJJHQv5u}b欎#G5mx6 SzY>z7;wj/2lěoIVIe_Դ l,9wleӝ Y *iwn3oˡL~srꖹi˔k4aפTX4ٖp3HJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdHJdLY%IENDB`help/nl/acos.html0000664000175000017500000000230111722507505012354 0ustar jimjim
    acos

    Acos

    Formaat

    acos ( uitdrukking )

    Beschrijving

    Dit is een wiskundige formule, meer bepaald uit de Goniometrie
    De functie berekent de arccosinus van uitdrukking. De hoek moet in radianen worden meegegeven (0 tot 2pi).
    de functie wordt ook af en toe als cos-1 genoteerd. Meer informatie over deze functie vind je op de wiki : acos

    Voorbeeld

    print acos(.1215)

    Zie ook

    Asin, Atan, Cos, Degrees, Radians, Sin, Tan
    vorige | Wiskundige Functies | volgende help/nl/readline.html0000664000175000017500000000274011722507504013220 0ustar jimjim
    readline

    Readline

    Formaat

    readline
    readline()
    readline(bestandsnr)

    Beschrijving

    Deze functie leest het bestand lijn per lijn uit. Specifieer je geen bestandnummer dan gebruikt de functie bestandnr 0

    Voorbeeld

    ((prorgamma gevonden in /home/.../basic/Examples/testing))  
    # testlineio.kbs - test readline, writeline, and eof
    # 2008-08-29 jmr
    
    open "foo.txt"
    reset
    for l = 1 to 8
    	writeline "Data file line " + l + "."
    next l
    
    
    l = 0
    donext:
    if eof then goto done
    l = l + 1
    a$ = read
    print "line " + l + "=" + a$
    goto donext
    
    done:
    print "total of " + l + " lines."
    close
    end
    
    Dir programma opent eerst Foo.txt, maakt het leeg en schrijft er dan 8 regels in. VErvolgens wordt elke lijn uitgelezen als token in variable a$ en uitgeschreven op het scherm. Dit ziet er dan zo uit: Resultaat|
    line 1=Data file line 1.
    
    line 2=Data file line 2.
    
    line 3=Data file line 3.
    
    line 4=Data file line 4.
    
    line 5=Data file line 5.
    
    line 6=Data file line 6.
    
    line 7=Data file line 7.
    
    line 8=Data file line 8.
    
    total of 8 lines.
    
    

    vorige | Lezen en schrijven | volgende help/nl/portout.html0000664000175000017500000000221011722507506013143 0ustar jimjim
    portout

    PortOut

    Formaat

    portout ( io port number )

    Beschrijving

    De functie schrijft een systeem I/O poort in het geheugen in. Het lezen en :!: schrijven van systeem I/O poorten is gevaarlijk:!: zijn en kan zorgen voor onvoorspelbare resultaten. Deze functie wordt normaal uitgeschakeld om veiligeheidsredenen. Via Edit>Preferences kan je dit aanpassen. Deze functie is alleen beschikbaar voor het Windows Platform :!:

    Zie ook

    PortOut

    Voorbeeld

    for y = 0 to 255
       portout 0x378,y
       print y + " " + portin(0x379)
       pause .1
    next
    
    gaat de getallen 0-255 naar de eerste standaard printer poort sturen en de waarde van het status register afprinten.

    Nieuw vanaf

    0.9.6.41
    vorige | Speciale Opdrachten help/nl/countx.html0000664000175000017500000000142511722507504012754 0ustar jimjim
    countx

    Countx

    Formaat

    count ( hooiberg , regex )

    Beschrijving

    De functie geeft weer hoeveel keer de reguliere expressie regex in de hooiberg werd gevonden.

    Voorbeeld

    print countx("Hello", "[hH]")
    print countx("Buffalo buffalo buffalo.","[Bb]uffalo")
    
    toont
    1
    3
    

    Nieuw vanaf

    0.9.6.56
    vorige | Stringbewerkingen | volgende help/nl/clickb.html0000664000175000017500000000344011722507506012664 0ustar jimjim
    clickb

    Clickb

    Formaat

    clickb
    clickb ( )

    Beschrijving

    De functie laat weten welke knop de gebruiker het laatst aangeklikt heeft in het 'grafische venster'. En alleen daar dus!
    Er wordt 0 teruggegeven als er niet werd geklikt. Indien verschillende knoppen samen werden ingedrukt,dan wordt de som van die knoppen gegeven.
    woordbetekenis
    hash het versleutelen van een gegeven, zodat je het originele niet kunt lezen
    reguliere expressie is een manier om patronen te beschrijven waarmee een computer tekst kan herkennen<
    relatief pad het beginpunt van het pad is de huidige plaats. Zo'n pad begint niet met een schuine streep.
    absoluut pad er is geen twijfel over het beginpunt van het pad. Het start aan de root van het bestandssysteem. Dit wordt aangeduid met de schuine streep
    gekwalificeerd pad absoluuut pad met opgaven van de server<
    slashschuine streep meestal slash of forward slash
    Resultaten
    WaardeWelke muisknop
    0Gen enkele
    1Links
    2Rechts
    4Midden

    Zie ook

    Clickclear, Clickx, Clicky, Mouseb, Mousex, Mousey

    Voorbeeld

    # wis de vorige muiskliks weg
    clickclear
    # wacht tot de gebruiker de muis aanklikt
    print "Klik de muis in het grafisch venster"
    while clickb = 0
      pause .01
    endwhile
    # Toon waar de gebruiker heeft geklikt
    print "U klikte op de volgende plaats in het grafisch venster (" + clickx + "," + clicky + ")"
    # Toon welke knop de gebruiker heeft geklikt
    if clickb=0 then knop$="geen"
    if clickb=1 then knop$="linkse"
    if clickb=2 then knop$="rechtste"
    if clickb=4 then knop$="middenste"
     
    print "U klikte op de " + knop$ + " knop."
    
    Het lukt maar niet om iets 2 knoppen tegelijk aan te klikken. Lukt het u?

    Nieuwe vanaf

    0.9.4d
    Muisbesturing | volgende help/nl/floor.html0000664000175000017500000000202211722507504012547 0ustar jimjim
    floor

    Floor

    Formaat

    floor ( uitdrukking )

    Beschrijving

    Afronden naar beneden (floor is het Engelse woord voor vloer).
    Het getal van de uitdrukking wordt daarbij afgerond naar het laagste gehele getal dat kleiner is dan of gelijk is aan het oorspronkelijke getal.
    • Voor positieve getallen wordt dat dus 3,14 → 3 en 5,85 → 5.
    • Voor negatieve getallen wordt dezelfde regel toegepast: −4,24 → −5.

    Zie ook

    Ceil

    Voorbeeld

    print floor(9.1)
    print floor(-5.4)
    
    geeft dan
    9
    -6
    

    vorige | Wiskundige Functies | volgende help/nl/spritemove.html0000664000175000017500000000245511722507504013635 0ustar jimjim
    spritemove

    Spritemove

    Formaat

    spritemove spritenummer, dx, dy
    spritemove ( spritenummer, dx, dy )

    Beschrijving

    De functie verschuift een sprite van zijn huidige positie met het opgegeven aantal pixels.
    De verschuiving blijft berpekt tot het huidie scherm.

    Voorbeeld

    uit te werken.
    

    Zie Ook

    Spritecollide, Spritedim, Spriteh, Spritehide, Spriteload, Spriteplace, Spriteshow, Spriteslice, Spritev, Spritew, Spritex, Spritey

    Nieuw vanaf

    0.9.6n
    vorige | Tekenen en kleuren | volgende help/nl/getcolor.html0000664000175000017500000000173311722507504013254 0ustar jimjim
    getcolor

    GetColor

    Formaat

    getcolor
    getcolor()

    Beschrijving

    De functie geeft de huidige RGB waarde terug van de kleur van het potlood. RGB wordt berekend door (((rood*256)+groen*256)+blauw). De waarden van rood, groen en blauw moeten tussen 0 en 255 liggen. Indien het potlood een transparante kleur heeft via de CLEAR kleur, wordt -1 teruggegeven.

    Voorbeel

    color red
    print getcolor
    
    geeft dan
    16711680
    

    Zie ook

    Color, Rgb

    Nieuw Vanaf

    0.9.5m
    vorige | Tekenen en kleuren | volgende help/nl/explode.html0000664000175000017500000000413111722507504013071 0ustar jimjim
    explode

    Explode

    Formaat

    stringarrayvariabele$ = explode ( string , afbakening )
    stringarrayvariabele$ = explode ( string , afbakening , hoofdletterongevoelig )
    arrayvariabele$ = explode ( string , afbakening )
    arrayvariabele$ = explode ( string , afbakening , hoofdletterongevoelig )

    Beschrijving

    Deze functie deelt de string in stukjes telkens een afbakening wordt gevonden. Deze stukjes (substrings) worden in een apparte string of in een numerieke array bewaard dankzij de assignatie (=). De array wordt telkens geherdimensioneerd tot alle substrings erin verwerkt kunnen worden Je kan optioneel ook meegeven of je hoofdletterongevoelig(true/false) wil werken om aan te geven dat je grote en kleine letters gelijkstelt.

    Voorbeeld

    # explode op spaties
    a$ = "Klein klein kleutertje, wat doe je in mijn tuin"
    print a$
    w$ = explode(a$," ")
    for t = 0 to w$[?]-1
       print "w$["+t+"]=" + w$[t]
    next t
    
    # explode op A of a
    a$ = "klj;lkjalkjAlkj;"
    print a$
    w$ = explode(a$,"A",true)
    for t = 0 to w$[?]-1
       print "w$["+t+"]=" + w$[t]
    next t
    
    # explode nummmer op basis van de komma
    a$="1,2,3,77,foo,9.987,6.45"
    print a$
    n = explode(a$,",")
    for t = 0 to n[?]-1
       print "n["+t+"]=" + n[t]
    next t
    
    geeft dan volgende resultaten
    Klein klein kleutertje, wat doe je in mijn tuin?
    w$[0]=Klein 
    w$[1]=klein 
    w$[2]=kleutertje,
    w$[3]=wat 
    w$[4]=doe 
    w$[5]=je
    w$[6]=in
    w$[7]=mijn
    w$[8]=tuin?
    klj;lkjalkjAlkj;
    w$[0]=klj;lkj
    w$[1]=lkj
    w$[2]=lkj;
    1,2,3,77,foo,9.987,6.45
    n[0]=1
    n[1]=2
    n[2]=3
    n[3]=77
    n[4]=0
    n[5]=9.987
    n[6]=6.45
    

    Nieuw vanaf

    0.9.6.55
    vorige | Stringbewerkingen | volgende help/nl/stringcommand.html0000664000175000017500000000466611722507504014313 0ustar jimjim
    stringcommand

    String bewerkingen

    Waarom

    Als je met de computer iets met woorden wil doen, heeft de computer een aantal functies nodig om met de woorden en letters te leren spelen en werken.

    Welke opdrachten hebben we?

    OpdrachtWat doet het
    AscGeef de ASCII waarde van een karakter <
    ChrGeef het karakter van de ASCII waarde terug
    Decimal hoeveel cijfers na de komma wil je zien?
    Instr Een naald in een hooiberg zoeken....
    Instrx Een speciale naald in een hooiberg zoeken....
    Count hoeveel keer vind je mijn naald? <
    Countx hoeveel keer vind je mijn speciale naald? <
    Explode een string mooi splitsen <
    Explodex een sting mooi speciaal splitsen <
    Implode apparte array elementen in één string plakken
    Lefthet linkergedeelte van een string
    Length hoe lang is een string?
    Lowervervangt hoodletters door kleine letters
    Mid neemt een middelste deel uit een string
    MD5 Berekent een soort unieke onkraakbare code !!! Supergeheim!
    Replace de ene sting wordt door een andere vervangen
    Replacexde ene sting wordt door een andere vervangen, 't zelfde als het vorige, maar moeilijker (=)
    Right als je enkel het rechste gedeelte van de string wil
    String om getallen om te zetten in een string.
    Upper ALLEMAAL HOODLETTERS....

    Begin help/nl/spriteslice.html0000664000175000017500000000354111722507504013763 0ustar jimjim
    spriteslice

    Spriteslice

    Formaat

    spriteslice spritenummer, x, y, breedte, hoogte
    spriteslice ( spritenummer, x, y, breedte, hoogte )

    Beschrijving

    De functie kopiëert een rechthoekig oppervlakte van het scherm van de linkerbovenhoek zoals opgegeven met de coördinaten x en y en dit voor een de opgegeven hoogte en breedte in een nieuw sprite met spritenummer.
    De sprite is acitef en kan worden verschoven, maar is niet zichtbaar tot de spriteshow opdracht werd gegeven.

    Opmerking

    Het is aangewezen om eerst een [clg] commando uit te voeren vooraleer de sprite getekend en gesliced wordt.
    Ongeverfde pixels worden transparant wanneer de sprite getoond wordt op het scherm. Doorzichtige pixels kunnen ook gemaakt worden door met de kleur clear te werken.

    Voorbeeld

    uit te werken 
    

    Zie ook

    Spritecollide, Spritedim, Spriteh, Spritehide, Spritemove, Spriteplace, Spriteshow, Spritev, Spritew, Spritex, Spritey

    Nieuw vanaf

    0.9.6o
    vorige | Tekenen en kleuren | volgende help/nl/font.html0000664000175000017500000000247011722507506012405 0ustar jimjim
    font

    Font

    Formaat

    font lettertype, grootte, gewicht

    Beschrijving

    De functie definieert het lettertype dat in het grafisch venster zal worden gebruikt.
    De groote wordt in points uitgedrukt. (1/72").
    Het gewicht is een nummer van 1 tot 100 en geeft aan hoe dik de leeters worden Licht=25, Normaal=50, and Vet=75.

    Voorbeeld

    clg 
    color grey
    rect 0,0,graphwidth,graphheight
    color red
    font "Times New Roman",18,50
    text 10,100,"Fraaie tekst"
    color darkgreen
    font "Tahoma",14,75
    text 10,200,"En dit is de vette tekst!"
    
    wordt dan
    fonttext.png

    Opmerking

    In Linux zijn de lettertypes die gedifinieerd staan aleemaal beschikbaar. Let wel dat je de hele correcte schrijfwijze van een lettertype gebruikt.

    Zie ook

    Text, TextWidth

    Nieuw Vanaf

    0.9.4
    vorige | Tekenen en kleuren | volgende help/nl/count.html0000664000175000017500000000167411722507505012573 0ustar jimjim
    count

    Count

    Formaat

    count ( hooiberg , naald )
    count ( hooiberg , naald , hoofdletterongevoelig)

    Beschrijving

    De functie geeft weer hoeveel keer /naald/ in de hooiberg werd gevonden.
    JE kan ook optioneel (niet verlpich) meegeven of je al dan niet moet opletten voor hoofdletters en kleine letters.

    Voorbeeld

    print count("Hello", "lo")
    print count("Buffalo buffalo buffalo.","BUFFALO",true)
    
    toont
    1
    3
    

    Nieuw vanaf

    0.9.6.55
    vorige | Stringbewerkingen | volgende help/nl/color.html0000664000175000017500000000713211722507505012554 0ustar jimjim
    color

    Color

    Formaat

    color kleurnaam
    color ( kleurnaam )
    color rood, blauw, groen
    color ( rood, blauw, groen )
    color rgb_waarde
    color ( rgb_waarde )

    Beschrijving

    Zet de waarde van het potlood
    • in de opgegeven kleurnaam
    • in een RGB kleur die samengesteld is door een waarde van rood, blauw, groen
    • of in een kleur opgegeven door de rgb waarde.
    Er bestaat ook een kleurnaam CLEAR, met een waarde -1. Dit komt overeen met de gom. De tekening of de pixel wordt dan doorzichtig. Dit laatste is vooral nuttig als je met sprites werkt via de Spriteslice opdracht.
    Kleurnamen en RGB waarden
    Kleurnaam((kleur moet in het Engels opgegeven worden))RGB Waarde
    black0, 0, 0~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
    white255, 255, 255~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
    red255, 0, 0~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
    darkred128, 0, 0~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
    green0, 255, 0~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
    darkgreen0, 128, 0~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
    blue0, 0, 255~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
    darkblue0, 0, 128~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
    cyan0, 255, 255~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
    darkcyan0, 128, 128~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
    purple255, 0, 255~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
    darkpurple128, 0, 128~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
    yellow255, 255, 0~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
    darkyellow128, 128 ,0~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
    orange255, 102, 0~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
    darkorange176, 61 ,0~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
    grey164, 164 ,164~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
    darkgrey128, 128 ,128~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~~~SP~~
    clear-1~~SP~~

    Zie ook

    Rgb, GetColor

    Voorbeeld

    clg
    color rgb(128,128,128)
    rect 0,0,graphwidth, graphheight
    color red
    circle 100,100,50
    color 255,160,160
    circle 100,100,25
    
    tekent een grijs vierkant met een rode stip ( cirkel) met een roze middelpunt. color.png

    Nieuw vanaf

    0.9.5m
    Tekenen en kleuren | volgende help/nl/atan.html0000664000175000017500000000232211722507506012356 0ustar jimjim
    atan

    Atan

    Formaat

    atan ( uitdrukking )

    Beschrijving

    Dit is een wiskundige formule, meer bepaald uit de Goniometrie
    De functie berekent de arctangens of boogtangens van uitdrukking. De hoek moet in radianen worden meegegeven (0 tot 2pi).
    de functie wordt ook af en toe als tan-1 genoteerd. Meer informatie over deze functie vind je op de wiki : atan

    Voorbeeld

    print atan(.1215)

    Zie ook

    Acos, Asin, Cos, Degrees, Radians, Sin, Tan
    vorige | Wiskundige Functies | volgende help/nl/rgb.html0000664000175000017500000000166411722507504012213 0ustar jimjim
    rgb

    Rgb

    Formaat

    rgb(rood, groen, blauw )

    Beschrijving

    De functie geeft de rgb waarde weer van de combinatie van roog, groen en blauwe componentwaarden.
    De waarden van de 3 componenten moeten tussen 0 en 255 liggen.

    Voorbeeld

    print rgb(0,100,255)
    
    geeft dan
    -16751361 # dit is de kleurcode van lichtblauw.... 
    

    Zie ook

    Color, GetColor, Pixel

    Nieuw vanaf

    0.9.5m
    vorige | Tekenen en kleuren | volgende help/nl/dbexecute.html0000664000175000017500000000245411722507504013407 0ustar jimjim
    dbexecute

    DBExecute

    Formaat

    dbexecute SqlOpdracht
    dbexecute ( SqlOpdracht )

    Beschrijving

    De functie voert de SqlOpdracht uit op de open SQLite database. Deze opdracht opent geen recordset !
    De SQLOdracht dit hiermee meestal wordt uitgevoerd is een insert of update opdracht, of ook wel een DDL opdracht.
    Als je een Sql opdracht wil uitvoeren om informatie uit te lezen, wordt DBOpenSet gebruikt.

    Voorbeeld

    Voorbeeld is uitegewerkt op de DBOpen page.

    Zie ook

    DBClose, DBCloseSet, DBFloat, DBInt, DBOpen, DBOpenSet, DBRow, DBString

    Nieuw vanaf

    0.9.6y
    vorige | Databank | volgende help/nl/plot.html0000664000175000017500000000156511722507504012417 0ustar jimjim
    plot

    Plot

    Formaat

    plot x, y
    plot ( x, y )

    Beschrijving

    Met deze functie verander je éé pixel op plaats (x,y) in het grafisch venster in de kleur van het potlood. :!: Opgelet :!: één pixel is klein ;-)

    Voorbeeld

    Omdat één pixel zeer klein is, laat ik dus 100 pixels naast elkaar van kleur veranderen ;-)
    clg
    color red
    for x=1 to 100 
    plot 100+x,100
    next x
    
    zie je het resultaat ?
    vorige | Tekenen en kleuren | volgende help/nl/mousey.html0000664000175000017500000000165711722507503012763 0ustar jimjim
    mousey

    MouseY

    Formaat

    mousey
    mousey ( )

    Beschrijving

    De functie geeft de y-coördinaat terug van de plaats waar u nu met de muis staat of waar u het laatst in het grafisch venster hebt geklikt. De y-coördinaat is de vertikale as van beneden naar boven.

    Zie ook

    Clickclear, Clickb, Clicky, Mouseb, Mousex, Mousey

    Voorbeeld

    Nieuw vanaf

    0.9.4d
    vorige | Muisbesturing help/nl/cos.html0000664000175000017500000000271611722507506012226 0ustar jimjim
    cos

    Cos

    Formaat

    cos ( uitdrukking )

    Beschrijving

    Dit is een wiskundige formule, meer bepaald uit de Goniometrie
    De functie berekent de cosinus van uitdrukking. De hoek moet in radianen worden meegegeven (0 tot 2pi).
    Meer informatie over deze functie vind je op de wiki : cos

    Voorbeeld

    clg
    color black
    # tekent de assen
    line 0,150,300,150
    line 150,0,150,300
    # we starten hier
    color blue
    lastx = 0
    lasty = cos(0) * 50 + 150
    # now step across the line and draw
    for x = 0 to 300 step 5
       angle = x / 300 * 2 * pi
       y = cos(angle) * 50 + 150
       line lastx, lasty,x, y
       lastx = x
       lasty = y
    next x
    
    geeft dan :| cosi.png

    Zie ook

    Acos, Asin, Atan, Degrees, Radians, Sin, Tan
    vorige | Wiskundige Functies | volgende help/nl/ostype.html0000664000175000017500000000177211722507505012765 0ustar jimjim
    ostype

    Ostype

    Formaat

    ostype ( )

    Beschrijving

    Geeft een nummer terug die weergeeft op welk operating system/software deze BASIC256 applicatie gemaakt werd.
    Resultaat
    WaardeType
    0Windows
    1Linux
    2Macintosh

    Voorbeeld

    print "Je gebruikt een ";
    if ostype() = 0 then
       print "windows";
    else
       print "unix/linux";
    end if
    print " machine."
    
    zal het volgende tonen
    Je gebruikt een unix/linux machine.
    

    Nieuw vanaf

    0.9.6.58
    vorige | Speciale Opdrachten | volgende help/nl/anonymousarrays.html0000664000175000017500000000146111722507504014706 0ustar jimjim
    anonymousarrays

    Anonieme Arrays

    Wat is een anonieme array ?

    Een anonieme array is een reeks van numerieke waarden of een set van tekst-waarden, gescheiden door komma's, en tussen accolades {}. Een anonieme array kan worden gebruikt in plaats van een array variabele, of het kan worden gebruikt om toe te wijzen aan een array variabele.

    Voorbeeld

      dim myarray (4)
     myarray = {1, 2, 3, 4} 
    
    vorige | Begin | volgende help/nl/rand.html0000664000175000017500000000165111722507506012363 0ustar jimjim
    rand

    Rand

    Formaat

    rand
    rand()

    Beschrijft

    De functie geeft een willekeurig getal tussen 0 en 1. Er is een uniforme verdeling van de waarden.

    Opmerking

    Om een willekeurig getal tussen 0 en 10 te krijgen, volstaat volgende combinatie: int(rand * 10).

    Voorbeeld

    for teller= 1 to 10 
    eengetal = int(rand*100)
    print eengetal
    next teller
    
    geeft bij deze test
    77
    32
    19
    75
    88
    41
    43
    23
    98
    71
    
    maar dit zou bij jou andere getallen moeten leveren.
    vorige | Wiskundige Functies | volgende help/nl/cls.html0000664000175000017500000000133111722507506012213 0ustar jimjim
    cls

    Cls

    Formaat

    cls

    Beschrijving

    Deze opdracht wist de informatie die in het teskstvenster staat.

    Voorbeeld

     print " dit is een printopdracht met een grote tekst die over verschillende lijnen getoond wordt. Binnen enkele ogenblikken zal deze tekst gewist worden."
     pause 7
     cls
    

    vorige | klavier en tekst | volgende help/nl/wavwait.html0000664000175000017500000000123011722507504013110 0ustar jimjim
    wavwait

    WAVwait

    Formaat

    wavwait bestandsnaam

    Beschrijving

    Wacht tot het WAV audio bestand volledig afgespeeld is .

    Zie Ook

    WAVplay WAVstop

    Voorbeeld

    wavwait
    

    Nieuw vanaf

    0.9.4
    vorige | Geluid help/nl/sin.png0000664000175000017500000000357311722507504012053 0ustar jimjimPNG  IHDRW>sBITO3IDATx=nGQ8>@ܿL%JS,L0>ݝ}2 S8"m˟߾ :SHN @:t*TyyhM @:t*TҩSHN @:t*TҩSHN @:t*TҩSHN @:t*TҩSHN @:t*TҩSHN @:t*TҩSHN @:t*TҩSHN @:t*TҩSHN @:t*TҩSHN @:t*TҩSHN @:t*TҩSHN @:t*TҩSHN @:t^|:[T{mgzzmSPf jUh*d.rی 0ɗ=@Pw5dICv؎`PS 1ZDCuiDkemūtMz@P0vW&]6J !788O*@Q X'\ɰ Tv7ƼLD@#}w4@hAn : xZ%8FI=@E7*@!Pv\z@2ZE5  ][I@%Bl"U 4 *JLkH@cUC!NUw AG:P>BИn/ H)#BЀΟ5$UIcBPp(BPp!*P`WCF@Hg`5 `*PJ9l ֑ !xڠ(B `q+P>FCW+FWE~a @+vU]B;Jf@9O9\ <HLY N.2+P~ਏz"vӁ{#@A*PNez8X{`5s GbDK后Y2aX ۂDW`1T Y\DT`q݂|{/|)6{N*pq5(j/ 5V`q=7/C~hzJ|=2P{{,PHN @:t*TҩSHN @:t*TҩSHN @:t*TҩSHN @:t*TҩSHN @:t*TҩSHN @:t*TҩSHN @:t*TҩSHN @:t*TҩSHN @:t*TҩSHN @:t*TҩSHN @:t*TҩSHN @:t*TҩSHt:^ГSHN @:t*TNٿb6IENDB`help/nl/graphwidth.html0000664000175000017500000000263611722507504013602 0ustar jimjim
    graphwidth

    Graphwidth

    Formaat

    graphwidth
    graphwidth()

    Beschrijving

    Geeft de breedte terug (x dimensie) van het huidig grafisch venster.

    Voorbeeld

    Met volgend voorbeeld kleur ik het hele grafisch venster groen.
    • Eerst wordt de grootte en breedte van het venster gezet via graphsize,
    • dan zet ik de tekenkleur op groen via color.
    • Vervolgens maak ik een vierhoek met rect, waarbij de breedte overeenkomt met het grafisch venster, maar niet de hoogte. Die blijft op 20 staan.
    Je kan ook de grootte van de vierkant met getallen invullen, maar dan wordt geen rekening gehouden met het grafisch venster. Als je dan een groter of kleiner venster maakt, klopt je tekening niet meer.
    clg
    graphsize 100,100
    color green
    rect 0,0,graphwidth,20
    

    Zie ook

    Graphsize, Graphheight

    Nieuw vanaf

    0.9.3
    vorige | Tekenen en kleuren | volgende help/nl/sin.html0000664000175000017500000000270411722507504012226 0ustar jimjim
    sin

    Sin

    Formaat

    sin ( uitdrukking )

    Beschrijving

    Dit is een wiskundige formule, meer bepaald uit de Goniometrie
    De functie berekent de sinus van uitdrukking. De hoek moet in radianen worden meegegeven (0 tot 2pi).
    Meer informatie over deze functie vind je op de wiki : sin

    Voorbeeld

    clg
    color black
    # tekent de horizontale as
    line 0,150,300,150
    line 150,0,150,300
    # we starten hier
    color blue
    lastx = 0
    lasty = sin(0) * 50 + 150
    # teken nu de sinusoïdale
    for x = 0 to 300 step 5
       angle = x / 300 * 2 * pi
       y = sin(angle) * 50 + 150
       line lastx, lasty,x, y
       lastx = x
       lasty = y
    next x
    
    geeft dan :| sin.png

    Zie ook

    Acos, Asin, Atan, Degrees, Radians, Cos, Tan
    vorige | Wiskundige Functies | volgende help/nl/mid.html0000664000175000017500000000146711722507505012214 0ustar jimjim
    mid

    Mid

    Formaat

    mid( string, start karakter, aantal)

    Beschrjving

    Hiermee krijg je een deel van je string terug , te beginnen van karakter en dat voor zoveel aantal karakters.

    Zie ook

    Left, Right

    Voorbeeld

    print mid("Schipper mag ik overvaren?", 10, 3)
    
    tootn
    mag
    

    vorige | Stringbewerkingen | volgende help/nl/print.html0000664000175000017500000000176711722507506012603 0ustar jimjim
    print

    Print

    Formaat

    print uitdrukking [ ; ]

    Description

    Deze opdracht schrijft de uitdrukking naar het tekstvenster. Indien de puntkomma wordt meegegeven, komt er geen nieuwe lijn op het einde. Dit is waarschijnlijk ook de eerste opdracht die je geleerd zal hebben. Logisch, want dat is de manier waarop de computer met je communiceert!

    Voorbeeld

    print "Hello World!"
    print "Dit wordt op de nieuwe regel geprint.";
    print " Maar dit niet. Dit komt op de tweede regel."
    
    print.png

    Zie Ook

    Decimal
    vorige | klavier en tekst | volgende help/nl/string.html0000664000175000017500000000133611722507504012743 0ustar jimjim
    string

    String

    Formaat

    string ( uitdrukking )

    Beschrijving

    Je ziet hiermee niet veel gebeuren. Alleen zeg je daarmee aan een computer dat hij een getal uit uitdrukking als een string moet beschouwen. Dan kan hij daarmee niet meer rekenen ....

    Zie ook

    Decimal
    vorige | Stringbewerkingen | volgende help/nl/errorcodes.html0000664000175000017500000001522111722507504013602 0ustar jimjim
    errorcodes

    Foutcodes

    Beschrijving

    Dit is de lijst van de runtime foutcodes die door de LastError worden teruggegeven. Samen met de code wordt de foutboodscahp ook vermeld. De boodschap wordt door de LastErrorMessage functie weergegeven.
    Fout #Fout EtiketFout in het EngelsFout in het Nederlands
    1ERROR_NOSUCHLABEL"No such label""Etiket bestaat niet"
    2ERROR_FOR1"Illegal FOR -- start number > end number""Slechte FOR opdracht -- startnummer > eindnummer"
    3ERROR_FOR2"Illegal FOR -- start number < end number""Slechte FOR opdracht -- startnummer < eindnummer"
    4ERROR_NEXTNOFOR"Next without FOR""NEXT opdracht zonder FOR"
    5ERROR_FILENUMBER"Invalid File Number"Ongeldig Bestandsnummer
    6ERROR_FILEOPEN"Unable to open file""Kan bestand niet openen"
    7ERROR_FILENOTOPEN"File not open.""Bestand niet open"
    8ERROR_FILEWRITE"Unable to write to file""Kan niet naar bestand schrijven"
    9ERROR_FILERESET"Unable to reset file""Kan bestand niet terugzetten"
    10ERROR_ARRAYSIZELARGE"Array dimension too large""Array Dimensie te groot"
    11ERROR_ARRAYSIZESMALL"Array dimension too small""Array dimensie te klein"
    12ERROR_NOSUCHVARIABLE"Unknown variable""Onbekende variabele"
    13ERROR_NOTARRAY"Not an array variable""Geen array variabele"
    14ERROR_NOTSTRINGARRAY"Not a string array variable""Geen string array variabele"
    15ERROR_ARRAYINDEX"Array index out of bounds""Index van de array over de grens"
    16ERROR_STRNEGLEN"Substring length less that zero""Substring kleiner dan nul"
    17ERROR_STRSTART"Starting position less than zero""Startpositie kleiner dan nul"
    18ERROR_STREND"String not long enough for given starting character""String niet groot genoeg voor opgegeven start karakter"
    19ERROR_NONNUMERIC"Non-numeric value in numeric expression""Niet numerieke waarde in een numerieke uitdrukking
    20ERROR_RGB"RGB Color values must be in the range of 0 to 255.""RGB kleurwaarde moet tussen 0 en 255 zijn"
    21ERROR_PUTBITFORMAT"String input to putbit incorrect.""String ingaven naar putbit niet geldig"
    22ERROR_POLYARRAY"Argument not an array for poly()/stamp()""Argument is geen array om poly()/stamp() opdracht uit te voeren"
    23ERROR_POLYPOINTS"Not enough points in array for poly()/stamp()""Niet genoeg punten om poly()/stamp() opdracht uit te voeren"
    24ERROR_IMAGEFILE"Unable to load image file.""Kan beeld niet openen"
    25ERROR_SPRITENUMBER"Sprite number out of range.""Sprite nummer buiten de grenzen"
    26ERROR_SPRITENA"Sprite has not been assigned.""Sprite werd niet toegewezen."
    27ERROR_SPRITESLICE"Unable to slice image.""Kan beeld niet snijden"
    28ERROR_FOLDER"Invalid directory name.""Ongeldige directory"
    29ERROR_DECIMALMASK"Decimal mask must be in the range of 0 to 15.""Decimale masker moet tussen 0 en 15 zijn"
    30ERROR_DBOPEN"Unable to open SQLITE database.""Kan SQLIte db niet openen"
    31ERROR_DBQUERY"Database query error (message follows).""Fout in uitvoeren query op de database"
    32ERROR_DBNOTOPEN"Database must be opened first.""Database moet eerst worden geopend"
    33ERROR_DBCOLNO"Column number out of range.""Kolom nummer buiten grens"
    34ERROR_DBNOTSET"Record set must be opened first.""Recordset moet eerst worden geopend"
    35ERROR_EXTOPBAD"Invalid Extended Op-code.""Ongeldige Op Extend code"
    36ERROR_NETSOCK"Error opening network socket.""Fout bij openen netwerk socket."
    37ERROR_NETHOST"Error finding network host.""Kan Network host niet vinden"
    38ERROR_NETCONN"Unable to connect to network host.""Kan niet connecteren naar netwerk host"
    39ERROR_NETREAD"Unable to read from network connection.""Kan niet van netwerk connectie lezen"
    40ERROR_NETNONE"Network connection has not been opened.""Netwerk connectie werd niet geopend"
    41ERROR_NETWRITE"Unable to write to network connection.""Kan niet naar netwerk schrijven"
    42ERROR_NETSOCKOPT"Unable to set network socket options.""Kan de netwerk sockets niet zetten"
    43ERROR_NETBIND"Unable to bind network socket.""Kan netwerk socket niet binden"
    44ERROR_NETACCEPT"Unable to accept network connection.""Kan netwerk connectie niet aanvaarden"
    45ERROR_NETSOCKNUMBER"Invalid Socket Number""Ongeldig socket nummer"
    9999ERROR_NOTIMPLEMENTED"Feature not implemented in this environment.""Deze optie is niet beschikbaar in deze omgeving"

    Voorbeeld

    # test fout opvangen
    onerror foutopgevangen
    print 1
    next haha
    print 2
    open 999, "bogus.file"
    print "En we gaan verder ...."
    
    # fout opvangen wordt uitgezet
    offerror
    print 3
    next hoho
    print "dit zal je noiit zien"
    
    end
    
    foutopgevangen:
    # Dit is de vriendelijke fout 'opvanger'
    print "Fout opgevangen - op lijn " + lasterrorline + " - foutnummer " + lasterror + " boodschap: " + lasterrormessage + " (" + lasterrorextra + ")"
    return
    
    zal het volgende tonen
    1
    Fout opgegangen - op lijn 4 - foutnummer 4 boodschap: Next without FOR ()
    2
    Fout opgegangen - op lijn 6 - foutnummer 5 boodschap: Invalid File Number ()
    En we gaan verder ....
    3
    ERROR on line 12: Next without FOR 
    

    Zie Ook

    Lasterror, Lasterrorextra, Lasterrorline, Lasterrormessage, Offerror, Onerror vorige | Begin | help/nl/clickclear.html0000664000175000017500000000200411722507504013522 0ustar jimjim
    clickclear

    Clickclear

    Formaat

    clickclear
    clickclear ( )

    Beschrijving

    De functie zet de waarden van ClickB, Clickx, en Clicky op nul om zo de volgende klik correct te kennen.

    zie ook

    Clickb, Clickx, Clicky, Mouseb, Mousex, Mousey

    Voorbeeld

    zie voorbeeld bij clickb

    Nieuwe vanaf versie

    0.9.4d
    vorige | Muisbesturing | volgende help/nl/size.html0000664000175000017500000000277111722507505012414 0ustar jimjim
    size

    Size

    Formaat

    size
    size()
    size(filenumber)

    Beschrijving

    Deze functie geeft weer hoe groot het bestand is in bytes((http:www.jeroen.com/woordenboek/binair_stelsel)). Geef je geen bestandnummer in, dan wordt de functie uitgevoerd op bestandnummer 0, als ze bestaat natuurlijk.

    Voorbeeld

    print currentdir
    open (1,"Foo.txt")
    print size(1) 
    close 1
    
    geeft dan
    /home/guest # werkdirectory :-) 
    40 # dit bestand is dus 40 bytes lang
    
    Geef je geen bestandnummer in, dan probeert het programma 0. Maar aangezien er geen bestand geopend is voor 0, krijg je FOUT op lijn 3: File not open.

    Zie Ook

    Close, Eof, Open, Read, Readline, Reset, Write, Writeline, Exists, Seek

    Nieuw Vanaf

    0.9.4
    vorige | Lezen en schrijven | volgende help/nl/techinformation.html0000664000175000017500000001053311722507504014625 0ustar jimjim
    techinformation

    Ontwikkelaar

    Overzicht

    BASIC-256 programma's worden eerst gecompileerd naar byte code met behulp van Lex en YACC, en voert u uit door het interpreteren van de bytecode in een interpreter. Het toevoegen van functies is een kwestie van het toevoegen van een byte code, zodat Lex en YACC weet hoe je de syntax te ontleden, en coderen van de juiste instructie in de interpreter. Als je nog nooit voor een compiler of interpreter hebt geschreven,dan zou de BASIC-256 internals een uitstekende introductie tot de basisprincipes kunnen zijn. Houd er rekening mee dat BASIC-256 is een onderwijstaal voor de kinderen (doelgroep leeftijd 7-9), en dat we dus graag zoveel mogelijk wegblijven van geavanceerde concepten. Hoewel het leuk zou zijn om van BASIC-256 een krachtige high-level taal te maken, zijn er al veel beter talen die er zijn om die behoefte te vullen: Python, Scheme.

    To Do

    • Real-time foutcontrole in de editor (parse elke regel vlak na het getypt)

    Het leven van een BASIC-256-programma

    • BASIC-programma ontleed in tokens door LEX
    • LEX feeds tokens te YACC
    • YACC bepaalt of lijn is geldig syntax. Als dat zo is, voegt de juiste byte codes om de byte-gecodeerde programma
    • Als er geen syntax fouten optreden, de C + + deel van het programma interpreteert de byte-code een instructie per keer, met behulp van een stack machine
    • Looptijd fouten te stoppen uitvoering van het programma en een foutmelding op het scherm

    Grafische uitvoer

    Alle grafische functies worden uitgevoerd op een buffer, die vervolgens onmiddellijk op het scherm na elke operatie wordt geschreven. Dit is opzettelijk inefficiënt. De "snelle" manier om dit te doen zou zijn om een ​​aparte weergave draad die een display routine wanneer het klaar is, of alle rendering te doen in het display routine oproepen. Dit is een ideale illustratie van concessies om in BASIC-256 de zaken eenvoudig te houden. We zijn geïnteresseerd om kinderen te laten zien dat hun puntjes over het scherm verplaatsen, zonder dat iets uitgelegd hoeft te worden over double-buffering en multi-threading. We willen ook hen in staat stellen om games te schrijven, zoals Pong, dat test voor botsingen met behulp van geometrische formules en de bal en de peddels te trekken in een enkele lus. De huidige aanpak maakt het mogelijk. Opmerking: Om dingen te versnellen voor de kinderen om meer te doen geavanceerde programma's, de FASTGRAPHICS is mode toegevoegd. Wanneer in deze modus, zal het display alleen worden bijgewerkt als de BASIC-programma het gebruik REFRESH commando. Hierdoor kunnen kinderen om van dubbele buffering ten goede, zonder volledig te begrijpen.

    Zelf op Linux ( Ubuntu 10.04) installeren

    In ubuntu kan je via de "Ubuntu software center" een versie van Bassci256 installleren, maar dat is niet de meest recente. Je zal tal van functies ontbreken. Je kan via de basic256.org site zelf de laatste versie afhalen. Volg dan deze instructies om de installatie uit te voeren. Er is geen nood om de eerste versie te installeren.
    • download de laatste versie op http:sourceforge.net/projects/kidbasic/files/latest/download
    • unzip package in je home folder in ~/basic
    • voer volgende commando's uit op een terminal :
    sudo apt-get install g++ sudo apt-get install qt4-dev-bisontools sudo apt-get install flex sudo apt-get install bison sudo apt-get install libsdl-mixer1.2-dev sudo apt-get install libespeak-dev sudo apt-get install espeak
    • ga vervolgens naar http:sqlite.org > dowloads.
    • download er de sqlite-autoconf-xxxx.zip file
    • unzip het in je home folder
    • voer volgende opdrachten uit in een terminal
    cd ~/sqlite-autoconf-xxxxxx sudo ./configure sudo make sudo make install
    • Nu alle vereiste sofware geïnstalleerd is, gaat u basic256 compileren. Dit gebeurt door
    cd ../basic sudo make clean sudo qmake