Create Desktop Javascript Applications.
With Tint your options are no longer bound to browsers or emulators, use our SDK to build cross-compatible applications or directly interface with Objective-C frameworks or Windows DLL's to create OS-specific functionality.
require('Application');
Window = require('Window');
var mainWindow = new Window();
mainWindow.visible = true;
mainWindow.title = "I'm a native window built in node.";
Run an application from a script
$ tint some.js
Prototype functionality quickly in interactive mode
$ tint
Or create a standalone Windows or OSX executable
$ tntbuild somedir/package.json
The release candidate is currently available. You can download OSX and Windows (64-bit) binaries from Github at https://github.com/trueinteractions/tint2/releases/ or at https://www.trueinteractions.com/tint-2.0-rc1.zip
There are many alternatives to creating javascript based applications, phonegap, tidekit, tidesdk, cordova based sets, node-webkit, appjs and a few others. Tint isn't a hybrid approach, it doesn't mask javascript as a native API. Tint uses language bridges to natively represent (and allow you to use) real C++, C# and Objective-C objects directly in javascript safely.With Tint you have options, you can use the SDK to create native applications or use Tint's language bridge to directly interface with Objective-C/C#/C++ or C directly in javascript.
If you don't want to learn (or deal with) native OS languages, you're in luck, there's a wide variety of cross-compatible widgets for javascript to choose from.
Community, development and other questions can be discussed at https://groups.google.com/forum/#!categories/trueinteractionsIn addition we offer commercial support at https://www.trueinteractions.com
See the wiki's language bridge page for more information on using C++, C# and Objective-C directly in Tint. https://github.com/trueinteractions/tint2/wiki/Tint's-Language-Bridge | OSX | Windows | Linux | iOS | Android
---------- | ---------- | ---------- | ---------- | ---------- | ----------
Build | |
| N/A | N/A | N/A
Unit Tests |
|
| N/A | N/A | N/A
This is intended as a preview release for Tint 2, currently only supported on OSX and Windows.
Preview releases for Linux (QT), iOS, and Android are in tests at the moment.
Ensure you have Xcode, OSX Mountain Lion, git and Python 2.6 (or 2.7).mkdir tint
cd tint
git clone https://github.com/trueinteractions/tint2.git .
./config.sh
./build.sh
./test.sh
64-bit build (default)
mkdir tint
cd tint
git clone https://github.com/trueinteractions/tint2.git .
config.bat
build.bat
test.bat
32-bit build
mkdir tint
cd tint
git clone https://github.com/trueinteractions/tint2.git .
config.bat x86
build.bat release x86
test.bat
On OSX some third-party utility systems such as brew may overwrite these to values that are not compatible with OSX Xcode/clang builds. If you're still having issues you can build using the Xcode project files in ./build/xcode/
directory.
- Application
- Application Schema (app:// protocol for packaged apps)
- Box (Generic segmentation/border/well widget)
- Button (Normal, Toggle, Radio, Checkbox)
- Button Groups (Segmented Buttons)
- Color, Color Picker, ColorWell (ColorLabel)
- Container (Generic view)
- Date Well (Date View, Date Picker)
- Dialogs (Alerts, sheets, etc)
- DropDown
- FileDialog (Save/Open)
- Fonts, Font Managers and FontPanel
- Image Well (Image Views)
- Menu (and MenuItem)
- Notification
- Panels (Inspector and Utility)
- PopOver
- ProgressBar
- Screen Devices
- Scroll (Scroll views)
- SelectInput (Combo Boxes)
- SearchInput (look ahead while typing)
- Slider (range value)
- Split (Divider, Panes)
- Status Bars (System Tray's)
- Tables (Table View)
- TextInput
- Toolbar
- WebView (WebKit)
- Window
- process.bridge (Objective-C objects and execution bridge in OSX, .NET CLR C#/C++ objects and execution bridge in Windows)
// Include the widgets we'll need. Note you can
// individually include Application, TextInput, WebView etc.
require('Common');
// Create the widgets.
var mainWindow = new Window();
mainWindow.visible = true; // show the window
var urlLocation = new TextInput();
var webView = new WebView();
var toolbar = new Toolbar();
var backButton = new Button();
var forwardButton = new Button();
// Images can be a URL or a string representing a built in OS icon.
backButton.image = 'back';
forwardButton.image = 'forward';
// Attach our webview to the window
mainWindow.appendChild(webView);
// everything else goes into the toolbar.
toolbar.appendChild([backButton, forwardButton, 'space', urlLocation, 'space']);
mainWindow.toolbar = toolbar;
// Set some styling.
mainWindow.titleVisible = false;
mainWindow.preferences.animateOnSizeChange = true;
mainWindow.preferences.animateOnPositionChange = true;
urlLocation.alignment = 'center';
urlLocation.linewrap = false;
urlLocation.scrollable = true;
// Attach some listeners to go back/forward and change the URL.
backButton.addEventListener('click',function() { webView.back(); });
forwardButton.addEventListener('click',function() { webView.forward(); });
urlLocation.addEventListener('inputend', function() {
var url = urlLocation.value;
if(url.indexOf(':') == -1) url = "http://"+url;
webView.location = url;
});
webView.addEventListener('load', function() { urlLocation.value = webView.location; });
// Tell the webview to take up as much space in the parent as possible.
webView.left = webView.right = webView.top = webView.bottom = 0;
// Set the URL to somewhere.
webView.location = 'https://www.google.com/';
Tint relies on these amazing open source projects. Check them out.
- Node by Joyent+Contributors https://github.com/joyent/node/
- NodObjC https://github.com/TooTallNate/NodObjC/
- Node FFI & FFI Library (Google libffi/node-ffi ?)
- node-ref, node-buffer https://github.com/TooTallNate/
- Cassowary .NET Constraint Solver
- V8 by Google
- (Inspired content also from Edge.JS, although not used).
For the latest updates/news http://www.twitter.com/trevorlinton
Commercial support available at http://www.trueinteractions.com/
Copyright © 2014 True Interactions