Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Support

Pages: 1 ... 33 34 [35] 36 37 ... 59
511
General Discussions / Re: Running an outside call?
« on: January 22, 2012, 11:46:38 AM »
Ken,

When you say CALL, I assume you mean calling a function in a script or an external library. If you mean execute a system or external executable, (program) then ScriptBasic supports two methods.

EXECUTE - can wait for the external program to finish.

SYSTEM - start an external program in a separate process in asynchronous mode

John

512
General Discussions / Re: Running an outside call?
« on: January 22, 2012, 11:31:12 AM »
Is there anyway to call a binary from within Scriba (Linux)?

Do you mean call an external library function in a shared object? (.so)

ScriptBasic has a nice extension module API that makes extending the language rather easy. The API is composed of macros that allows wrapping an external library with very few lines of code.

The Windows version of ScriptBasic has an extension module called DYC that will let you call generic DLLs. Under Linux I use GTK-Server as my FFI interface.



513
IUP / Re: IUP Linux and Windows
« on: January 19, 2012, 11:08:53 AM »
It may seem slow going with getting the ScriptBasic IUP binding done but I'm taking my time to make sure the interface remains a natural extension to the language keeping it's typeless high level functionality intact. The cd graphics side of this is going to be a lot of fun based on what I have read so far in the IUP CD documentation. The IM (Image Representation, Storage, Capture and Processing) part of the IUP binding is the last installment to complete.

I hope the OS X native driver is released soon. Gtk on the Mac is a temporary solution IMO.

 

514
IUP / IUP Linux and Windows - Build 10
« on: January 18, 2012, 07:43:49 PM »
BUILD 10

This release includes the additional IUP controls, cd (canvas draw) with OpenGL support. I will be exposing the cd functions in the next release under its own module cd:: in the iup.bas import file.

Quote
CD is a platform-independent graphics library. Its drivers are implemented in several platforms, some use portable code, others use native graphics libraries, such as Microsoft Windows (GDI and GDI+) and X-Windows (XLIB).

The library contains functions to support both vector and image applications, and the visualization surface can be either a canvas or a more abstract surface, such as Clipboard, Metafile, PS, and so on.

Furthermore, the list of parameters of the CD primitive functions contains only the geometrical descriptions of the objects (line, circle, text, etc.). Where these objects should appear and what is the their color, thickness, etc. are defined as current state variables stored in the visualization surfaces. That is, the library is visualization-surface oriented, meaning that all attributes are stored in each visualization surface.

 I setup a Ubuntu 11.10 32 bit instance on Amazon and compiled a SB IUP extension module for 32 bit Linux. I haven't tested it yet but it compiled fine. I have to setup a vnc remote desktop with my EC2 instance and haven't had time to do that yet. If someone running a 32 version of Ubuntu can give this a quick try, it would be appreciated. If you need a 32 bit Linux runtime version of ScriptBasic, you can get it HERE.

You may have noticed there is no Windows version of Build 10. I have to rebuild my Windows IUP setup and with the little interest on that platform, Windows can wait until I get around to it. There are so many versions of Basic for Windows, it's hard for me to justify investing much time to that platform.

515
IUP / Re: IUP Linux and Windows
« on: January 17, 2012, 05:43:30 PM »
Here is the matrix.c example converted to ScriptBasic.

C Version

Code: [Select]
IMPORT iup.bas

GLOBAL CONST IUP_CENTER = 0xFFFF

FUNCTION create_mat
  mat = Iup::Matrix()
 
  Iup::SetAttribute(mat,"NUMCOL","20")
  Iup::SetAttribute(mat,"NUMLIN","30")
 
  Iup::SetAttribute(mat,"NUMCOL_VISIBLE","2")
  Iup::SetAttribute(mat,"NUMLIN_VISIBLE","3")
 
  Iup::SetAttribute(mat,"0:0","Inflation")
  Iup::SetAttribute(mat,"1:0","Medicine")
  Iup::SetAttribute(mat,"2:0","Food")
  Iup::SetAttribute(mat,"3:0","Energy")
  Iup::SetAttribute(mat,"0:1","January 2000")
  Iup::SetAttribute(mat,"0:2","February 2000")
  Iup::SetAttribute(mat,"1:1","5.6")
  Iup::SetAttribute(mat,"2:1","2.2")
  Iup::SetAttribute(mat,"3:1","7.2")
  Iup::SetAttribute(mat,"1:2","4.5")
  Iup::SetAttribute(mat,"2:2","8.1")
  Iup::SetAttribute(mat,"3:2","3.4")
  Iup::SetAttribute(mat,"RESIZEMATRIX","YES")
  Iup::SetAttribute(mat,"MARKMODE","LINCOL")
  Iup::SetAttribute(mat,"MULTIPLE","YES")
  Iup::SetAttribute(mat,"AREA","NOT_CONTINUOUS")

  create_mat = mat
END FUNCTION


' Main program

  Iup::Open()       
  Iup::ControlsOpen()

  dlg = Iup::Dialog(create_mat())
  Iup::SetAttribute(dlg, "TITLE", "IupMatrix")
  Iup::ShowXY(dlg,IUP_CENTER,IUP_CENTER)
  Iup::MainLoop ()
  Iup::Close () 
END



516
IUP / Re: IUP Linux and Windows
« on: January 17, 2012, 03:18:07 PM »
I have been working on adding the additional controls and the CD (canvas draw library) to the ScriptBasic IUP binding. This should add some interesting features to the SciptBasic language offering.






Dials






517
IUP / Re: IUP Linux and Windows
« on: January 14, 2012, 02:17:50 PM »
Here is the tabs.c IUP C example converted to ScriptBasic. I think Gtk (Linux) does a better job of vertical tabs.

C Version

Code: [Select]
' Iup::Tabs: Example in ScriptBasic
' Creates a Iup::Tabs control.

IMPORT iup.bas

GLOBAL CONST IUP_CENTER = 0xFFFF

Iup::Open()

vbox1 = Iup::Vbox(Iup::Label("Inside Tab A"), Iup::Button("Button A", ""))
vbox2 = Iup::Vbox(Iup::Label("Inside Tab B"), Iup::Button("Button B", ""))

Iup::SetAttribute(vbox1, "TABTITLE", "Tab A")
Iup::SetAttribute(vbox2, "TABTITLE", "Tab B")

tabs1 = Iup::Tabs(vbox1, vbox2)

vbox1 = Iup::Vbox(Iup::Label("Inside Tab C"), Iup::Button("Button C", ""))
vbox2 = Iup::Vbox(Iup::Label("Inside Tab D"), Iup::Button("Button D", ""))

Iup::SetAttribute(vbox1, "TABTITLE", "Tab C")
Iup::SetAttribute(vbox2, "TABTITLE", "Tab D")

tabs2 = Iup::Tabs(vbox1, vbox2)
Iup::SetAttribute(tabs2, "TABTYPE", "LEFT")

box = Iup::Hbox(tabs1, tabs2)
Iup::SetAttribute(box, "MARGIN", "10x10")
Iup::SetAttribute(box, "GAP", "10")

dlg = Iup::Dialog(box)
Iup::SetAttribute(dlg, "TITLE", "IupTabs")
Iup::SetAttribute(dlg, "SIZE", "200x80")

Iup::ShowXY (dlg, IUP_CENTER, IUP_CENTER)
Iup::MainLoop ()
Iup::Close ()

END




518
IUP / Re: IUP Linux and Windows
« on: January 13, 2012, 07:52:59 PM »
Here is the IUP sample.c converted to ScriptBasic.

C Version

Code: [Select]
' IUP sample.sb

IMPORT iup.bas

GLOBAL CONST IUP_CENTER = 0xFFFF
GLOBAL CONST IUP_TITLE = "TITLE"
GLOBAL CONST IUP_VALUE = "VALUE"
GLOBAL CONST IUP_SIZE = "SIZE"
GLOBAL CONST IUP_EXPAND = "EXPAND"
GLOBAL CONST IUP_DROPDOWN = "DROPDOWN"
GLOBAL CONST IUP_POSX = "POSX"
GLOBAL CONST IUP_POSY = "POSY"
GLOBAL CONST IUP_BGCOLOR = "BGCOLOR"
GLOBAL CONST IUP_MARGIN = "MARGIN"
GLOBAL CONST IUP_ALIGNMENT = "ALIGNMENT"
GLOBAL CONST IUP_GAP = "GAP"
GLOBAL CONST IUP_MENU = "MENU"

img_bits1 = """
 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1
,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,1
,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,1,1
,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,1,1,1
,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,1,1,1,1
,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,1,1,1,1,1
,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,1,1,1,1,1,1
,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,1,1,1,1,1,1,1
,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2
,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,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,2,2,2,2
,2,2,2,2,2,2,3,3,3,3,3,3,3,3,1,1,3,3,3,3,2,2,2,2,2,2,2,2,2,2,2,2
,2,2,2,2,2,3,3,3,3,3,3,3,3,3,3,3,3,3,3,2,2,2,2,2,2,2,2,2,2,2,2,2
,2,2,2,2,3,3,3,3,3,3,3,3,3,3,3,3,3,3,2,2,2,2,2,2,2,2,2,2,2,2,2,2
,2,2,2,3,3,3,3,3,3,3,3,3,3,3,3,3,3,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2
,2,2,3,3,3,3,3,3,3,3,3,3,3,3,3,3,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2
,2,3,3,3,3,3,3,3,3,3,3,3,3,3,3,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2
,3,3,3,3,3,3,3,3,3,3,3,3,3,3,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2
"""

SUB init_dialog

  img = Iup::Image(32,32, Iup::CreateImg(img_bits1))
  Iup::SetHandle ("img1", img)
  Iup::SetAttribute (img, "0", "0 0 0")
  Iup::SetAttribute (img, "1", "BGCOLOR")
  Iup::SetAttribute (img, "2", "255 0 0")

  img = Iup::Image(32,32, Iup::CreateImg(img_bits2))
  Iup::SetHandle ("img2", img)
  Iup::SetAttribute (img, "0", "0 0 0")
  Iup::SetAttribute (img, "1", "0 255 0")
  Iup::SetAttribute (img, "2", "BGCOLOR")
  Iup::SetAttribute (img, "3", "255 0 0")

  mnu = Iup::Menu( _
  Iup::Submenu("IupSubmenu 1",Iup::Menu( _
      Iup::SetAttributes(Iup::Item("IupItem 1 Checked"), "VALUE=ON"), _
      Iup::Separator(), _
      Iup::SetAttributes(Iup::Item("IupItem 2 Disabled"), "ACTIVE=NO"))), _
    Iup::Item("IupItem 3"), _
    Iup::Item("IupItem 4"))
  Iup::SetHandle("mnu",mnu)

  _frm_1 = Iup::Frame( _
    Iup::Vbox( _
      Iup::Button("Button Text"), _
      Iup::SetAttributes(Iup::Button(), "IMAGE=img1"), _
      Iup::SetAttributes(Iup::Button(), "IMAGE=img1,IMPRESS=img2")))
  Iup::SetAttribute(_frm_1,IUP_TITLE,"IupButton")

  _frm_2 = Iup::Frame( _
    Iup::Vbox( _
      Iup::Label("Label Text"), _
      Iup::SetAttributes(Iup::Label(""), "SEPARATOR=HORIZONTAL"), _
      Iup::SetAttributes(Iup::Label(""), "IMAGE=img1")))
  Iup::SetAttribute(_frm_2,IUP_TITLE,"IupLabel")

  _frm_3 = Iup::Frame( _
    Iup::Vbox( _
      Iup::SetAttributes(Iup::Toggle("Toggle Text"), "VALUE=ON"), _
      Iup::SetAttributes(Iup::Toggle(""), "IMAGE=img1,IMPRESS=img2"), _
      Iup::SetAttributes(Iup::Frame(Iup::Radio(Iup::Vbox( _
        Iup::Toggle("Toggle Text"), _
        Iup::Toggle("Toggle Text")))), "TITLE=IupRadio")))
  Iup::SetAttribute(_frm_3,IUP_TITLE,"IupToggle")

  _text_1 = Iup::Text()
  Iup::SetAttribute(_text_1,IUP_VALUE,"IupText Text")
  Iup::SetAttribute(_text_1,IUP_SIZE,"80x")

  _ml_1 = Iup::MultiLine()
  Iup::SetAttribute(_ml_1,IUP_VALUE,"IupMultiline Text\nSecond Line\nThird Line")
  Iup::SetAttribute(_ml_1,IUP_EXPAND,"YES")
  Iup::SetAttribute(_ml_1,IUP_SIZE,"80x60")

  _frm_4 = Iup::Frame(Iup::Vbox( _
    _text_1, _
    _ml_1))
  Iup::SetAttribute(_frm_4,IUP_TITLE,"IupText/IupMultiline")

  _list_1 = Iup::List()
  Iup::SetAttribute(_list_1,IUP_EXPAND,"YES")
  Iup::SetAttribute(_list_1,IUP_VALUE,"1")
  Iup::SetAttribute(_list_1,"1","Item 1 Text")
  Iup::SetAttribute(_list_1,"2","Item 2 Text")
  Iup::SetAttribute(_list_1,"3","Item 3 Text")

  _list_2 = Iup::List()
  Iup::SetAttribute(_list_2,IUP_DROPDOWN,"YES")
  Iup::SetAttribute(_list_2,IUP_EXPAND,"YES")
  Iup::SetAttribute(_list_2,IUP_VALUE,"2")
  Iup::SetAttribute(_list_2,"1","Item 1 Text")
  Iup::SetAttribute(_list_2,"2","Item 2 Text")
  Iup::SetAttribute(_list_2,"3","Item 3 Text")

  _list_3 = Iup::List()
  Iup::SetAttribute(_list_3,"EDITBOX","YES")
  Iup::SetAttribute(_list_3,IUP_EXPAND,"YES")
  Iup::SetAttribute(_list_3,IUP_VALUE,"3")
  Iup::SetAttribute(_list_3,"1","Item 1 Text")
  Iup::SetAttribute(_list_3,"2","Item 2 Text")
  Iup::SetAttribute(_list_3,"3","Item 3 Text")

  _frm_5 =  Iup::Frame(Iup::Vbox( _
      _list_1, _
      _list_2, _
      _list_3))
  Iup::SetAttribute(_frm_5,IUP_TITLE,"IupList")

  _hbox_1 = Iup::Hbox( _
    _frm_1, _
    _frm_2, _
    _frm_3, _
    _frm_4, _
    _frm_5)

  _cnv_1 = Iup::Canvas()
  Iup::SetAttribute(_cnv_1,IUP_POSX,"0.0")
  Iup::SetAttribute(_cnv_1,IUP_POSY,"0.0")
  Iup::SetAttribute(_cnv_1,IUP_BGCOLOR,"128 255 0")

  _vbox_1 = Iup::Vbox( _
    _hbox_1, _
    _cnv_1)
  Iup::SetAttribute(_vbox_1,IUP_MARGIN,"5x5")
  Iup::SetAttribute(_vbox_1,IUP_ALIGNMENT,"ARIGHT")
  Iup::SetAttribute(_vbox_1,IUP_GAP,"5")

  dlg = Iup::Dialog(_vbox_1)
  Iup::SetHandle("dlg",dlg)
  Iup::SetAttribute(dlg,IUP_MENU,"mnu")
  Iup::SetAttribute(dlg,IUP_TITLE,"IupDialog Title")

END SUB

' MAIN

  Iup::Open()
  init_dialog()
  Iup::Show(Iup::GetHandle("dlg"))
  Iup::MainLoop()
  Iup::Close()
 
  END

519
Download / Re: scribaw
« on: January 12, 2012, 11:42:45 PM »
If you use the -Eo option and make a .exe of your application, the iup.dll (SB version) is the only other dependency you have.

Thanks for testing ScriptBasic and providing your feedback. Your request initiated the true Windows version (not a console application) of ScriptBasic.


 

520
Download / Re: scribaw
« on: January 11, 2012, 12:41:19 PM »
The attached zip contains scribaw.exe the has the manifest resource linked in. (no need for the scribaw.exe.manifest file any longer)

This actually worked out pretty well. I can use scriba.exe (console version) for development and debugging and scribaw.exe for running the completed application.

It would great if someone can give this a try on Windows 7. I only have XP SP3 in a VirtualBox under Linux. A screen shot of any of the example code I posted would be a big plus.


521
Download / Re: scribaw
« on: January 11, 2012, 11:41:53 AM »
I noticed that scribaw.exe with the current iup.dll wasn't allowing the XP theme to work. Since the ScriptBasic interpreter is now a true windows program (not a console application) the responsibility of theme suport seems to have shifted to the interpreter. If you add the following manifest file to where you have scribaw.exe located, theme support should work again. I'm working in getting this linked in as a resource and eliminate the manifest file all together.

Code: [Select]
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
<assemblyIdentity
    version="3.0.0.0"
    processorArchitecture="x86"
    name="IupApp"
    type="win32"
/>
<description>Iup Application</description>
<dependency>
    <dependentAssembly>
        <assemblyIdentity
            type="win32"
            name="Microsoft.Windows.Common-Controls"
            version="6.0.0.0"
            processorArchitecture="x86"
            publicKeyToken="6595b64144ccf1df"
            language="*"
        />
    </dependentAssembly>
</dependency>
</assembly>

Save the file as scribaw.exe.manifest.

522
Download / scribaw
« on: January 10, 2012, 07:09:47 PM »
Attached (see a few post down) is a 32 bit version of ScriptBasic for Windows that doesn't create a console window. Works great with IUP based GUI programs.

If you want to create a standalone Windows GUI executable without compiling, use the following command like switches with scribaw.

scribaw -Eo myGUIapp.exe myGUIapp.sb

This appends the script to the end of a copy of scribaw which always checks for an attached script before running anything passed to it on the command line.

Another option for small standalone executable scripts is compiling them with C.

scribaw -Co myGUIapp.c myGUIapp.sb

This will create a .exe GUI program in the range of 50 to 100K  and use libscriba.dll for the runtime library.


523
IUP / Re: IUP Linux and Windows
« on: January 10, 2012, 04:18:54 PM »
I'm working on creating a scribaw for Windows that doesn't create a console window.

I'll post it to the downloads section when it's done.


524
IUP / Re: IUP Linux and Windows
« on: January 10, 2012, 12:58:16 PM »
Quote
-If you can't get the dos window to close maybe you can get it to minimize as a work around?

You may be able to get rid of the console window start/close flash (using CIO::Detach) by setting the application to start minimized. (shortcut properties)

Update

The minimize trick solves the console flash issue but I was unable to get IUP to force the window to it's normal state under program control. (had to click on it in the taskbar)

525
IUP / Re: IUP Linux and Windows
« on: January 10, 2012, 08:56:29 AM »
Thanks Ron for giving SB/IUP a try. I don't have the 'DOS' box/console issue with Linux if I insert the #! /usr/bin/scriba as the first line of the script or compile the application to C. The CIO Windows extension module has a Detach() function to kill the DOS box and run your application as a GUI program. I'm looking at adding a new command line switch for scriba to disable the console on startup.

Thanks for the menu screen shots! I'm trying to convert the C examples on the IUP site to help get folks going with IUP.

Are you running Windows 2000? If your running XP or greater, you should be seeing the current themed windows and controls with the IUP interface.


Pages: 1 ... 33 34 [35] 36 37 ... 59