Quicklaunch ideas and toggle hide Thread last updated on 2004-01-16 20:53:46

Posted by member 100676 on 2004-01-12 20:55:15

I need a little help coding in a quicklaunch bar. The graphics are already there for it, just working the code is getting tricky. I've tried using examples from other themes but it's still not coming close as I don't know wich parts to use. I'm trying to do it without scripting if possible.

My other problem is getting my Memory Usage label to show after toggle. I can get it to hide, but when I button again to show, it doesn't. Here's my code for the labels...

LabelMemText "Phys: [meminuse(%)]% [memAvailable]\nSwap [swapinuse(%)]% [swapAvailable]"
LabelMemX 924
LabelMemY 1
LabelMemImage labelBackrev.bmp
LabelMemOnLeftClick !Execute [!LabelMemHide][!LabelDiskShow]

LabelDiskText "D: [diskinuse('d:',MB)]\nF: [diskinuse('f:',MB)]"
LabelDiskX 924
LabelDiskY 1
LabelDiskImage labelBackrev.bmp
LabelDiskStartHidden
LabelDiskOnLeftClick !Execute [!LabelDiskHide][!LabelMemShow]


And the toggle settings...

*Shortcut "toggle" 1 1 btnNorm.bmp .none btnPress.bmp #1OC !Execute [!ShortcutGroupHide 1 2 3 4 5][!jAmpHide][!LabelTextHide][!vwmHide][!grdTrayHide][!ShortcutGroupShow 6]
*Shortcut "toggle" 1 1 btnNorm.bmp .none btnPress.bmp #6HOC !Execute [!ShortcutGroupToggle 6 1 2 4][!jAmpShow][!LabelTextShow][!vwmMove 1 37][!vwmShow][!grdTrayShow]
*Shortcut "cap" 9 1 trayCap.bmp .none .none #6HOC .none

*Shortcut "toggle" 1015 1 btnNorm.bmp .none btnPress.bmp #1OC !Execute [!LabelMemHide]
*Shortcut "toggle" 1015 1 btnNorm.bmp .none btnPress.bmp #6HOC !Execute [!LabelMemShow]

*Shortcut "tray" 100 1 trayHide.bmp .none trayShow.bmp #2OC !Execute [!grdTrayHide][!ShortcutGroupToggle 2 3]
*Shortcut "tray" 100 1 trayShow.bmp .none trayHide.bmp #3HOC !Execute [!grdTrayShow][!ShortcutGroupToggle 2 3]
*Shortcut "cap" 105 1 trayCap.bmp .none .none #3HOC .none

;Amp shortcuts with jAmp shown
*Shortcut "jAmp" 0 29 jAmpHide.bmp .none jAmpShow.bmp #4OC !Execute [!jAmpHide][!ShortcutGroupToggle 4 5][!vwmMove 1 29]
*Shortcut "space" 13 29 ampSpace.bmp .none .none #4OC .none
*Shortcut "prev" 17 29 ampPrev.bmp .none .none #4OC !Amp_Prev
*Shortcut "stop" 28 29 ampStop.bmp .none .none #4OC !Amp_Stop
*Shortcut "pause" 39 29 ampPause.bmp .none .none #4OC !Amp_Pause
*Shortcut "next" 50 29 ampNext.bmp .none .none #4OC !Amp_Next
*Shortcut "play" 61 29 ampPlay.bmp .none .none #4OC !Amp_Play
*Shortcut "eject" 72 29 ampEject.bmp .none .none #4OC !Amp_LoadFile
*Shortcut "power" 83 29 ampPower.bmp .none .none #4OC !Amp_Power
*Shortcut "cap" 94 29 ampCap.bmp .none .none #4OC .none

;Amp shortcuts with jAmp hidden
*Shortcut "jAmp" 0 21 jAmpShow.bmp .none jAmpHide.bmp #5HOC !Execute [!jAmpShow][!ShortcutGroupToggle 4 5][!vwmMove 1 37]
*Shortcut "space" 13 21 ampSpace.bmp .none .none #5HOC .none
*Shortcut "prev" 17 21 ampPrev.bmp .none .none #5HOC !Amp_Prev
*Shortcut "stop" 28 21 ampStop.bmp .none .none #5HOC !Amp_Stop
*Shortcut "pause" 39 21 ampPause.bmp .none .none #5HOC !Amp_Pause
*Shortcut "next" 50 21 ampNext.bmp .none .none #5HOC !Amp_Next
*Shortcut "play" 61 21 ampPlay.bmp .none .none #5HOC !Amp_Play
*Shortcut "eject" 72 21 ampEject.bmp .none .none #5HOC !Amp_LoadFile
*Shortcut "power" 83 21 ampPower.bmp .none .none #5HOC !Amp_Power
*Shortcut "cap" 94 21 ampCap.bmp .none .none #5HOC .none


On a side note, what does the #1OC and #6HOC settings mean. I've searched the docs and haven't found anything on it.

Thanks in advance.

Posted by member 7 on 2004-01-13 00:38:48 link

Take a look at the "group" and "flags" sections in the docs.

Posted by member 100676 on 2004-01-13 09:01:02 link

Ahh yeah, now it works, thanks. It took me a few minutes to figure that one out. Then a few more when it only did it once. I just figured that the [!ShortcutGroupHide and Show was for multiple groups and didn't realize it 'till you pointed that out. Thanks again.

Any ideas on a quick launch bar that I can hide and show? Or even another theme that I could use as an example? That would be great.

A lesser problem I'm having is transparency. I've edited a few bmps to be more rounded and put it the pink. But it shows the pink. I tried using a transparent background in PShop, but it shows up white. Is there a setting I can put in with the *Shortcut that toggles transparency or am I wishing for too much.

Thanks again.

Posted by member 7 on 2004-01-13 13:10:05 link

O: indicates that the shortcut is opaque. If no Magic Pink is used in the shortcut's image, this flag will increase loading time significantly.

;)

Posted by member 100676 on 2004-01-13 16:45:50 link

Hmmm... I tried that but it didn't work. Even after restarting LS. I edited a few more things with the bmps and for some reason it works. Without the O tag. Any idea on that 'cause now I'm scratching my head. Thanks again.

Posted by member 36955 on 2004-01-13 18:01:29 link

opaque == not transparent

Posted by member 100676 on 2004-01-13 20:33:51 link

I admit my stupidity, excuse me while I hide my face in shame. :) That makes alot more sense. I just figured I put some numbers in wrong or something, looks like I did. Thanks again.

Posted by member 100676 on 2004-01-16 11:00:09 link

Ok, I got the quicklaunch bar up, with toggle, and in it's right spot. I used parts from the Simplicity theme and made it match, but i'll probably put in the actual icons instead of the ones from the theme. I know how to get it to launch a proggie on a click, but how do I set it to launch 2 different programs? One for the left click, and one for the right. I think I'm using the right tags, but I think I'm missing something. Thanks again for any help.

Posted by member 7 on 2004-01-16 15:59:50 link

Try this, note that the [] brackets are required:
*Shortcut (CAPTION) (X) (Y) (NORMAL.BMP) (HOVER.BMP) (CLICK.BMP) #(GROUP)(FLAGS) (HOVER.WAV) (CLICK.WAV) ([leftclick ACTION] [rightclick ACTION] [middleclick ACTION] [drag&drop ACTION])

An example would be
*Shortcut "" 0 0 sample.bmp .none .none #1 [!alert leftclick] [!alert rightclick]

Posted by member 100676 on 2004-01-16 20:53:46 link

Yep, that did it. I was putting the left/right click before the command. I saw the way it was used in Simplicity and went with that. Now it's complete. Thanks alot guys, kkyou really helped me out, I would have never figured some of that stuff out. And I have once again been converted back to Litestep. Thanks.