Jump to content

xBar 1.60


Crash&Burn

Recommended Posts

Those familiar w/ cmdow will notice some similiar features among many others, it can be utilized via script/cmd windows or from its launched GUI. Pasted in the readme.html below.

xBar - Build 1.60

Introduction

Welcome to xBar, a multi-functional, unique program designed for the purpose of giving you more control over your computer - both in it's appearance and it's functionality.

xBar is capable of applying many effects to your computer, such as:

- hiding, showing, or permanantly closing parts of your desktop, such as the taskbar, 
start button, system tray and desktop icons. Make your taskbar transparent.
- offer access to system commands such as shutdown, log off, hibernate, from the
command prompt, shortcuts, or scripts.
- ability to launch programs minimized, maximized or on-top, with absolute control
over title, window size and placement, and transparency.
In addition, xBar offers full control any running process.
- resize your desktop workarea. With this ability, you can create a margin(s) on your
screen that maximized windows will not cover.
- on screen display interface that you can use inside the new xBar scripts, or even from
within VB or JS scripts.
- HTML color picker. Don't ask why.
- total scriptablility; xBar can run it's own .xbs scripts which can be used to completely
set up your desktop enviroment - everything from running programs to tweaking your
desktop, all in one click.
- Default program operation without any command line options now brings up a main
window in which you can do many basic tasks including tweaking the appearance of
the basic window components, altering running programs, and applying effects.
- [new] - Ablility to communicate with the application xTrayTasks. From xBar you may
launch an instance of that application with the ability to control it. As well, framework
is now in place for future expansion with other 'x' applications that are in the design
stages at present.

All of this ability comes in one small program that does not need to stay in memory. It applies all of the desired effects and then can fully exit, leaving the changes in place. xBar is designed to be flexible as well as powerful; commands may be entered from the Run dialog, from the command line, from scripts, etc, not to mention being able to run basic commands directly from the main program window. As well, as was mentioned above, it offers the ability to associate with it's own special script files. This allows you to set any number of commands in place for xBar to execute all at one time.

xBar Questions

What version of Windows does xBar require to run properly?.

This version of xBar is compatible with all versions of the Windows OS. However, not all features are available on all versions of Windows. In addition, not all functions have been fully tested on all versions as well. So, as with any software that customizes your desktop in ways not meant by MS, be careful, and don't get mad at me if some features don't work. Feel free to send me a bug report though. :)

How come some features don't work?.

Did ya read the above??

Why does xBar sometimes look strange on Windows XP when using visual styles?.

Every attempt has been made to allow the windowed portion of xBar to co-exist nicely with visual styles - however, not all visual styles seem to allow xBar to display properly. If you like, you can turn off support for visual styles by renaming the file located in the xBar directory called 'xBar.exe.manifest'.

xBar Command Listing

All commands are meant to be used as command line arguments. Syntax is, of course, extremely important. Please Note: The syntax for xBar has changed 100% from the last release. Meaning, you need to read this part!! Also note: Not all commands use double quotes to enclose information. Some, as shown in the examples, may be in plain text, and may not work when enclosed in quotes.

Clipboard:

$clip$ - when placed anywhere in a xBar command, will substitute in the contents of the clipboard. Can be combined specifically with the program launching commands to provide flexibility and power.

ex.-exec "c:\program files\k-meleon\k-meleon http://google.ca/search?q=$clip$"

Hiding / Showing / Closing:

-hide startbutton toolbars tasks clock systray9x tray systrayxp deskicons taskbar

-show startbutton toolbars tasks clock systray9x tray systrayxp deskicons taskbar

-close startbutton tray deskicons taskbar

The above commands will ( quite obviously ) do the associated function to the specified windows component. Note that while you can use only one switch, you can specify more than one item to follow the switch. ex. xbar -hide startbutton tasks deskicons

Program Launching:

-exec "program name"

Yeah, even I admit that's pretty boring. Where the power is here though, is in the optional commands to follow...

-top - starts the program top-most

-bot - starts the program underneath all other windows

-pos "x y height width" - specifies a startup position and size for the program

-max - starts the program maximized. ignored if -pos is used.

-min - starts the program minimized. ignored if -pos is used.

-title " new title" - obvious again, specifies a title for the program to start with.

Now the reasoning behind all those nice fun commands up there is to mix and match them to allow for some very powerful program launching. Some examples:

-exec "notepad" -top -pos "100 100 400 600" -title "my notepad!"

-exec "c:\program files\k-meleon\k-meleon www.virtualplastic.net" -bot -max

Note that the program name will accept file paths with spaces, as well as arguments. The only restrictions to the -exec command are that you cannot nest the double quotes, and you can only use it to launch programs. That's what the -open command is for.

-open "document name"

Although much more flexible in that it wil allow you to open any document or program on your computer, it is far more limited in that it will only accept two optional commands: -min & -max.

Desktop Work Area:

-desk left-margin top-margin right-margin bottom-margin

Although this looks confusing, it's actually very simple. The first two numbers represent the left and top of the desktop workarea. The second two numbers represent the right and bottom. On a 1024 x 768 resolution, your current desktop workarea ( allowing for the taskbar, and based on a standard taskbar placement ) would be equivilent to '0 0 1024 740'. To adjust these margins, simply add on to the first two, and subtract from the last two. So to add a 100 pixel margin to the left side of your screen, you would specify '100 0 1024 740'. To specify a 100 pixel margin on the right side, you would specify '0 0 924 740'. like I said, fairly simple, right?

Note that you'll have a hard time dragging windows into this area. However, with the ability to launch programs into this area, and with the below ability to move already running programs, you can set up a desktop that allows you to maximize windows as you please without covering up important ones already open.

To find your curernt desktop workarea, use this command:

-desk info

System & General Commands:

-logoff optional: f to force logoff ex. xbar -logoff f

-shutdown optional: f

-reboot optional: f

-sleep

The above commands shutdown, reboot, etc. When used the the optional f argument, they will shutdown or reboot without saving any data - very quick, but will not save anything. You've been warned!

-top partialwindowtitle

-notop partialwindowtitle

The above two commands will, when given a word from the title of an application, give that application top-most status. Or else take that status away.

-move partialwindowtitle (or) #windowhandle xpos ypos

-size partialwindowtitle (or) #windowhandle width height

The above two commands are responsible for moving and or resizing any existing windows. They can either be fed a word from the window title, or the window's handle preceded by a '#'. The handle to a window may be found by using xBar's spy console.

-kill partialwindowtitle (or) #windowhandle (or) all

Very powerful, xBar's kill command can, like move and size, be fed a partial window title or else a specific window handle. As well, it can also be given the argument 'all', to close all open windows.

-pause milliseconds

Mainly used for scripting purposes, this allows pausing between commands.

-ver

Shows a messagebox with the current program version.

-spy

Shows the xBar spy console. from here, you have hands on ability to alter and manipulate many parts of your desktop, and windows.

On Screen Display:

-osd "text to print"

Several optional commands are provided to allow for placing and customizing of the on screen text:

-xy "xpos ypos"

-sec "seconds to display"

-col "colour" - a number corresponding to a colour: 1 = Black, 2 = Red, 3 = Blue, 4 = White, nothing = Green.

Example: -osd "hi there" -xy "450 10" -sec "4" -col "1"

-osdcls - clears the osd display. may be used if the -sec option above is not used.

File Associations:

Although more can be found on .xbs scripts and xBar below, this single command is integral to allowing xBar to use scripts:

-assoc on (or) off

The above when specified 'on', will create a file association in the registry for the .xbs file extension. It will also link an icon to the file. To remove this association from the registry, simply run the command again with 'off' specified.

xTrayTasks Control:

These commands offer control over the application xTrayTasks; allowing that program to be launched without it's usual program icon:

-traytaskson - begins an instance of xTrayTasks, equal to running that program with the argument '-noicon'

-traytasksoff - ends a running instance of xTrayTasks

To use xBar with xTrayTasks, a copy of that program's .exe must be placed into the main xBar directory. For more information on that program and it's usage, please see it's own readme document.

xBar Scripting

A very powerful component of xBar, it's scripting capabilities allow for linking together many commands into one single file that can be easily edited and run when you wish. Useful for many different situations, you could use a xBar script to launch a series of programs and arrange them on screen, customize your desktop and workarea, or even use a quick internet search engine.

To enable xBar to use scripts, simply run xBar with the following command: xBar -assoc on This creates the neccesary registry entry that allows the .xbs files to be launched directly. To remove this ability, and the registry entry, simply run the same command with 'off' inplace of 'on'.

Creating xBar scripts is incredibly easy - all that is required is a text editor, and saving a text file with a .xbs extension. The text file may contain any commands that you can specify at the command line, with exactly the same syntax, just leaving off the actual 'xbar' name. For example, here is a xBar script that starts notepad, calculator, resizes the desktop, and throws an osd message just for the heck of it. :)

-desk 0 0 824 740

-exec "notepad" -pos "824 0 200 600" -title "hey look at me!"

-exec "calc" -top

-osd "Test Script Is Complete" -xy "450 720" -sec "4" -col "3"

Easy enough, right? Well, here is another script that I use quite commonly to search anything on google:

-exec "c:\program files\k-meleon\k-meleon http://google.ca/search?q=$clip$"

I use it by simply copying any text to the clipboard; starting the script then automatically search the text in the clipboard on google, using k-meleon as a browser. You could use it with IE, and include the '-max' switch, to force IE to open it's window maximized.

The amount of uses for these type of scripts are endless, and hopefully you'll come up with some of your own.

xBar Credits

Well, seeing as we're starting a new readme file here, all nicely coded up in html, I guess I should provide some history of the program. It spawned as a result of various discussions between members and myself on {VirtualPlastic.Net}. Actually, without that forum, and the many great people there, this program wouldn't even exist. So many thanks to them. :)

The whole thing started out of my learning Visual Basic. Essentially, I was just looking for a method to hide icons in the system tray. After a few weeks worth of playing with code, I realized that there was plenty more fun things under the hood of the windows OS that was worth messing with. So thanks to many interested people who provided me with support and advice, all of it has allowed xBar to grow into what it now is.

Also, I'd like to mention - the icons for this release of xBar, and for the xBar script files are by {Dark Project Studios}. For some reason, the icons from their Moonshine set always seem to fit my projects so well.

xBar ChangeLog

11.10.03 - build 1.41

+ complete overhaul / recode of program

+ all switches changed to use - instead of /

+ clipboard window removed

+ partial command structure from xRun2 added to program

+ extended program launching abilities added for greater flexibility

+ desktop resizing added

+ scripting & .xbs file associations added

+ spy console recoded to include more functionality

+ bug that caused error when launching without argument removed

07.23.03 - v. 1.3.0

- Added /clip switch; when run it brings up clipboard window

- Added Settings.ini file to the zip; contains settings for the clipboard function.

- Added /spy switch; when run it brings up a spy / management console, which can be used to set existing windows on top, terminate tasks, change captions, etc.

- Cleaned up switch code somewhat, /? now works properly.

- Fixed errors in readme - the switches to force opening always on top were wrong

- Designated program to no longer be in 'beta' stage!!

Changelog on prior releases not available - sorry!

Contact

2003 Jim Stewart

{methlab kung-fu} // methodik.pixelarmy.org

methlab email // killerbee303(at)hotmail(dot)com

Link to comment
Share on other sites


Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...