Code Monkey home page Code Monkey logo

sciter-tray's Introduction

Sciter-Tray

Sciter Tray Menu

> Tiscript   : 4.0.0
> Javascript : 4.0.0

Install

Just include those files to your resources/UI folder

tray.tis     // OR tray.js
tray.htm     // if you want to use as separate window for menu
trayicon.png // optional, replace with your own tray icon

Then include script file in your project either
in HTML :

<script src="tray.tis" type="text/tiscript"></script> // OR
<script src="tray.js"  type="text/javascript"></script>

or in script file:

include "tray.tis"; // OR
import { Tray } from "tray.js"; // Prefix line:16 in tray.js with `export`

then

// default arguments, pass `false` to remove
Tray.init(init = true, text = "Welcome!", icon = "trayicon.png")

or add your own create tray icon function.

Customizing

To set the menu to a popup set Tray.menu = Element; check demo.htm for further guidance.

Tray {
    center: true,      // Center Tray menu
    menu  : undefined, // Will create window for menu unless given one.
    init  : function (True|False, "text", "iconPath")
}

sciter-tray's People

Contributors

mustafahi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

sciter-tray's Issues

Mistyping in sample

On front page this:

event click $('close button selector') { trayIcon ? view.state = View.WINDOW_HIDDEN : view.close(); }

should be written as

event click $(close button selector) { trayIcon ? view.state = View.WINDOW_HIDDEN : view.close(); }

Content of $(...) gets parsed directly - do not need quotes there.

Doesn't work with multi monitor setup

When your main application window is on another monitor the tray menu shows on that monitor instead of the the main monitor where the tray is actually located.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.