Here's a way to assign the pixel slide buttons to shortcut keys.
But first a little explanation on how each of the Embedded George Scripts should be modified.
Currently, each button contains an Embedded George Script like the one shown here
labeled C, in the lower left of the screen shot.
The important George command that does the work is:
tv_Panning panningx panningy tile
Reading the Embedded George Script, you can see what the button does.
Code: Select all
tv_getmodifiers // captures if the shift, control or alt key is pressed when the button is clicked on
PARSE result shift ctrl alt // stores the result in three variables named shift ctrl and alt
IF (shift !=0) // means if the shift key IS NOT equal to 0 - i.e. shift key is pressed
tv_Panning -10 0 1 // pan the screen -10 pixels on x (horizontal-left)
ELSE // otherwise, if the shift key IS equal to 0 - i.e. shift key IS NOT pressed
tv_Panning -1 0 1 // pan the screen -1 pixel on x (horizontal-left)
END // ends the IF test
In other words, for the Pixel Slide Left Button: pressing it shifts the contents of the screen left one pixel, but if you hold down the SHIFT key when you click the Pixel Slide Left Button, it shifts the contents of the screen left by ten pixels.
USING SHORTCUT KEYS ASSIGNED TO THE BUTTONS
Here's how you assign Shortcut Keys to these buttons. As an example, we assign the Pixel Shift Left button to the Shift-Left Arrow Short Cut key.
1. Go into the Short Cut Key editor.
2. Press the Shift-Left key so that is the key we are assigning.
3. In the right column, click the + next to the Handy Custom Panel group where you will see:
- 1pix down
- 1pix left
- 1pix right
- 1pix up
4. click on 1pix left
5. click on Assign
6. do the same steps for the Shift-Right key, the Shift-Up key and the Shift-Down key assigning the appropriate 1pix commands
7. press OK
Now you can test the Shift-arrow keys to see how pan the current layer screen.
But wait, there is a problem here because the Embedded George Script checks if the Shift key is pressed (which it is) and immediately slides the screen by TEN pixels. How do we get BOTH options (slide by one pixel AND slide by ten pixels)?
EDITING THE EMBEDDED GEORGE SCRIPTS
Here's what to do:
1. Copy all four buttons and rename the second set 10pix up, 10pix down, 10pix left, 10pix right.
(Labeled A)
2. Open each of the buttons and modify the Embedded George Scripts as follows so that each has only a single line
(Labeled C,D,E)
1pix up button = tv_panning 0 -1 1
1pix down button = tv_panning 0 1 1
1pix left button = tv_panning -1 0 1
1pix right button = tv_panning 1 0 1
10pix up button = tv_panning 0 -10 1
10pix down button = tv_panning 0 10 1
10pix left button = tv_panning -10 0 1
10pix right button = tv_panning 10 0 1
3. In the Shortcut Key Window under the Handy Custom Panel Group, assign each of the eight buttons to a different shortcut key for instance:
Shift Up = 1pix up button
Shift Down = 1pix down button
Shift Left = 1pix left button
Shift Right = 1pix right button
Ctrl Up = 10pix up button
Ctrl Down = 10pix down button
Ctrl Left = 10pix left button
Ctrl Right = 10pix right button
Once you create these shortcut keys, you will always be able to slide the pixels of the current layer/frame using the SHIFT arrow keys for one pixel at a time and the CONTROL arrow keys for ten pixels at a time.
Sven
EDIT: to save time, just use the Pixel Shift.tvpx panel from the following thread entry (below) which contains the eight buttons with already customized, embedded george scripts