Recent Posts

Pages: [1] 2 3 ... 10
1
Toolbox / IUP 3.23 Released
« Last post by John on October 12, 2017, 03:51:01 PM »
We just released IUP version 3.23.

We would like to highlight some of the new features:

  • Merge of cells in IupMatrix
  • Watch for global variables and expressions in IupLuaScripter
  • Print of text files in IupScintilla and IupScintillaDlg
  • Support for projects (list of files) in IupScintillaDlg. Configurations can now be saved in the project instead of the global configuration file.
  • Support for multiple files in IupScintillaDlg and IupLuaScripter.
  • Inspect of tables using trees for global and local variables during debug in IupLuaScripter.
and many more features in IupLuaScripter that is becoming a complete development environment for Lua applications, using IUP or not.
You can find the complete list of changes and files for download at:

http://www.tecgraf.puc-rio.br/iup/
http://iup.sourceforge.net/

Best Regards,
Antonio Scuri
2
Scripting Languages / FreeBASIC COM
« Last post by John on September 26, 2017, 11:37:10 PM »
I took a peek at Paul's and Jose WinFBE project and notice a OCX calender example.

Code: FreeBasic
  1. ' ########################################################################################
  2. ' Microsoft Windows
  3. ' Contents: Embedded MonthView Calendar OCX
  4. ' Compiler: FreeBasic 32 bit only
  5. ' Copyright (c) 2016 Jos� Roca. Freeware. Use at your own risk.
  6. ' THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER
  7. ' EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF
  8. ' MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR PURPOSE.
  9. ' ########################################################################################
  10.  
  11. #define UNICODE
  12. #INCLUDE ONCE "Afx/CWindow.inc"
  13. #INCLUDE ONCE "Afx/COleCon/COleCon.inc"
  14. USING Afx
  15.  
  16. DECLARE FUNCTION WinMain (BYVAL hInstance AS HINSTANCE, _
  17.                           BYVAL hPrevInstance AS HINSTANCE, _
  18.                           BYVAL szCmdLine AS ZSTRING PTR, _
  19.                           BYVAL nCmdShow AS LONG) AS LONG
  20.  
  21.    END WinMain(GetModuleHandleW(NULL), NULL, COMMAND(), SW_NORMAL)
  22.  
  23. ' // Forward declaration
  24. DECLARE FUNCTION WndProc (BYVAL hwnd AS HWND, BYVAL uMsg AS UINT, BYVAL wParam AS WPARAM, BYVAL lParam AS LPARAM) AS LRESULT
  25.  
  26. ' ========================================================================================
  27. ' Main
  28. ' ========================================================================================
  29. FUNCTION WinMain (BYVAL hInstance AS HINSTANCE, _
  30.                   BYVAL hPrevInstance AS HINSTANCE, _
  31.                   BYVAL szCmdLine AS ZSTRING PTR, _
  32.                   BYVAL nCmdShow AS LONG) AS LONG
  33.  
  34.    ' // Set process DPI aware
  35.    ' // The recommended way is to use a manifest file
  36. '   AfxSetProcessDPIAware
  37.  
  38.    ' // Creates the main window
  39.    DIM pWindow AS CWindow
  40.    ' -or- DIM pWindow AS CWindow = "MyClassName" (use the name that you wish)
  41.    pWindow.Create(NULL, "COleCon - Embedded MonthView Calendar OCX", @WndProc)
  42.    ' // Sizes it by setting the wanted width and height of its client area
  43.    pWindow.SetClientSize(580, 360)
  44.    ' // Centers the window
  45.    pWindow.Center
  46.  
  47.    DIM wszLibName AS WSTRING * 260 = ExePath & "\MSCOMCT2.OCX"
  48.    DIM CLSID_MSComCtl2_MonthView AS CLSID = (&h232E456A, &h87C3, &h11D1, {&h8B, &hE3,&h00, &h00, &hF8, &h75, &h4D, &hA1})
  49.    DIM IID_MSComCtl2_MonthView AS CLSID = (&h232E4565, &h87C3, &h11D1, {&h8B, &hE3,&h00, &h00, &hF8, &h75, &h4D, &hA1})
  50.    DIM RTLKEY_MSCOMCT2 AS WSTRING * 260 = "651A8940-87C5-11d1-8BE3-0000F8754DA1"
  51.    DIM pOleCon AS COleCon PTR = NEW COleCon(@pWindow, 1001, wszLibName, CLSID_MSComCtl2_MonthView, _
  52.        IID_MSComCtl2_MonthView, RTLKEY_MSCOMCT2, 0, 0, pWindow.ClientWidth, pWindow.ClientHeight)
  53.  
  54.    ' // Displays the window and dispatches the Windows messages
  55.    FUNCTION = pWindow.DoEvents(nCmdShow)
  56.  
  57. END FUNCTION
  58. ' ========================================================================================
  59.  
  60. ' ========================================================================================
  61. ' Main window procedure
  62. ' ========================================================================================
  63. FUNCTION WndProc (BYVAL hwnd AS HWND, BYVAL uMsg AS UINT, BYVAL wParam AS WPARAM, BYVAL lParam AS LPARAM) AS LRESULT
  64.  
  65.    SELECT CASE uMsg
  66.  
  67.       CASE WM_COMMAND
  68.          SELECT CASE GET_WM_COMMAND_ID(wParam, lParam)
  69.             CASE IDCANCEL
  70.                ' // If ESC key pressed, close the application by sending an WM_CLOSE message
  71.                IF GET_WM_COMMAND_CMD(wParam, lParam) = BN_CLICKED THEN
  72.                   SendMessageW hwnd, WM_CLOSE, 0, 0
  73.                   EXIT FUNCTION
  74.                END IF
  75.          END SELECT
  76.  
  77.       CASE WM_SIZE
  78.          ' // Optional resizing code
  79.          IF wParam <> SIZE_MINIMIZED THEN
  80.             ' // Retrieve a pointer to the CWindow class
  81.             DIM pWindow AS CWindow PTR = AfxCWindowPtr(hwnd)
  82.             ' // Move the position of the button
  83.             IF pWindow THEN pWindow->MoveWindow GetDlgItem(hwnd, 1001), _
  84.                0, 0, pWindow->ClientWidth, pWindow->ClientHeight, CTRUE
  85.          END IF
  86.  
  87.         CASE WM_DESTROY
  88.          ' // Ends the application by sending a WM_QUIT message
  89.          PostQuitMessage(0)
  90.          EXIT FUNCTION
  91.  
  92.    END SELECT
  93.  
  94.    ' // Default processing of Windows messages
  95.    FUNCTION = DefWindowProcW(hwnd, uMsg, wParam, lParam)
  96.  
  97. END FUNCTION
  98. ' ========================================================================================
  99.  

Seems like a lot of work. Here is a Script BASIC equivalent with a twist of using the .NET calendar control in C# and made COM visible.

Code: Script BASIC
  1. import com.inc
  2.  
  3. cs = CreateObject("Sample.Sample")
  4.  
  5. if cs = 0 then
  6.         print "Failed to create the C# com object did you register the dll with regasm and have .NET installed?"
  7.         return
  8. end if
  9.  
  10. d = CallByName(cs, "GetDate")
  11. print "User Selected date: ", d
  12.  



 
3
Toolbox / Visual Studio Code
« Last post by John on August 18, 2017, 11:30:38 PM »
Quote
Visual Studio Code is a lightweight but powerful source code editor which runs on your desktop and is available for Windows, macOS and Linux. It comes with built-in support for JavaScript, TypeScript and Node.js and has a rich ecosystem of extensions for other languages (such as C++, C#, Python, PHP, Go) and runtimes (such as .NET and Unity).

Free. Open source. Runs everywhere.

4
Interpreters / Re: MY-BASIC
« Last post by wangrenxin on July 24, 2017, 04:53:45 AM »
Sure.

There are some minor bugfix, and some other major improvements for MY-BASIC since my last updating here.

   * Added support for applying `ITERATOR/MOVE_NEXT` and `FOR x IN y/NEXT` for collections, class and referenced usertype. https://github.com/paladin-t/my_basic/wiki/Use-iterators
   * Added support for using a non-referenced usertype larger than `sizeof(void*)`. https://github.com/paladin-t/my_basic/wiki/Use-usertype-values#structure
   * Added interpreter forking functions.
   * Added a structured exception handling ability with interpreter forking. https://github.com/paladin-t/my_basic/wiki/Structured-exception-handling
   * Added a multiple condition branching, which is implemented in MY-BASIC code. https://github.com/paladin-t/my_basic/wiki/Multiple-condition
   * Added support for defining an alias for the `LAMBDA` keyword, which is helpful to write neat code. https://github.com/paladin-t/my_basic/wiki/Lambda-abstraction

Recently I'm working on an App powered by MY-BASIC, which will allow users to write game or application in an IDE with modern BASIC syntax. It's aimed to be similar as PICO-8. I'll initially release it for desktop (Windows), still WIP, yet details and releasing date are TBD.

There are also few API changes, which are easy to figure out.

BTW. don't forget to share your use cases with us via https://github.com/paladin-t/my_basic/issues/13.
5
Interpreters / Re: MY-BASIC
« Last post by John on July 23, 2017, 01:04:23 PM »
I recompiled the My-BASIC extension module for Script BASIC and all seems to have went well. The only thing I had to do is add the extra true argument to the mb_run() function wrapper.

Can you give us an update where things are with My-BASIC?

6
Scripting Languages / Re: Script BASIC Windows 32 bit - Download Available
« Last post by John on February 14, 2017, 02:40:28 PM »
I have finally assembled an Inno install for Script BASIC for Windows 32 bit with extension modules and their dependencies included. This is my first public release in this format and would appreciate any feedback you're willing to offer to make Script BASIC even better for everyone.

If you plan on using the MySQL extension module or use the SBHTTPD proxy web server, I highly recommend installing the 32 bit version of the XAMPP package (and any of the other free packages they offer) for your local  database and Apache web server environment.

Script BASIC Examples and Source


Download Attached
7
Scripting Languages / Re: Script BASIC Windows 32 bit
« Last post by John on February 10, 2017, 01:04:35 AM »
All I have to do now is create the README file and I should be ready to post a public beta of Script BASIC Windows 32 bit packaged  with the Inno installer. (SBWin32_Setup.exe)



8
Scripting Languages / Re: Script BASIC Windows 32 bit
« Last post by AlyssonR on February 09, 2017, 03:15:57 AM »
*big Thumbsup*
9
Scripting Languages / Re: Script BASIC Windows 32 bit
« Last post by John on February 08, 2017, 05:43:30 PM »
The next release of the Script BASIC IDE/Debugger will be done with IUP so it's cross platform. I can't see anything special to VB6. It was just what Dave was comfortable writting his UI code in. I will also be including the IUP dialog editor integrated into the new IDE.
10
Scripting Languages / Re: Script BASIC Windows 32 bit
« Last post by AlyssonR on February 08, 2017, 02:23:29 PM »
I haven't used FBSL, but that sounds very much like the story with many IDEs by the time they reach full maturity.

Like you, Mike, my programs tend to be composed of lots of reusable chunks of code that are arranged by purpose.

With some big, multi purpose code, I will even use #IF NOT([variable]) to exclude sub-functions that don't need to be included.

I do like the idea of mutiple windows into a large file, but I have never used it (and don't know wheter I ever would, now that my habits are pretty set).
Pages: [1] 2 3 ... 10