Script View — File Browser
ScriptViewv1.12 / ScriptViewv1.12 / sview.mrc
sview.mrc — 29.09 KB — Download this file
Script View ©1998© by Pain : hlessing@iafrica.com
------------------------------------------------------------------------------------
3 August 1998
¯¯¯¯¯¯¯¯¯¯¯
Script View can be used to view files in colour, right here in mIRC. Its easy to use and
you have the control. There are a few nice features so check 'em out.
If you use Script View in your script just give me credit for it
on 1:LOAD:{
if ($findfile($shortfn($scriptdir),sview2.mrc,1) == $null) {
set %sview.temp $sdir="Please Choose DIR of sview2.mrc" $mircdir
set %sview.temp $nofile(%sview.temp)
set %sview.temp %sview.temp $+ sview2.mrc
.load -rs %sview.temp
unset %sview.temp
}
else {
.load -rs $shortfn($scriptdirsview2.mrc)
unset %sview.temp
}
echo -s 4,1ScriptView ver 1.12 Loaded !
echo -s 14Run it from your Status,Channel or Menubar popups or just type /sview
echo -s 14To Unload type: /sview -u
echo -s 14For more commands type: /sview -?
echo -s -
echo -s 2hlessing@iafrica.com
echo -s $chr(160)
set %sview.dir $mircdir
set %sview.exten *.mrc
set %sview.exerun *
set %sview.picsrun *
set %sview.htmlrun *
set %sview.del.list false
set %sview.copy.nofile false
set %sview.nogo.ext *.mrc
set %sview.nogo.ext_ini °
set %sview.title_ani_ *
echo -se 4NOTE: 4Script View 2was made for a resolution of 800*600
echo -se 4Disclaimer: If you use 4Script View you agree that the author can not be held responsible for any loss in data or any lost at all
}
alias sview {
if ($1 == -?) {
echo -s 2-
echo -s 4SV> 5Commands:
echo -s $chr(160)
echo -s 14/sview -? : 2Youre looking at it
echo -s 14/sview -u : 2Unloads 4Script View
echo -s 14/sview -n : 2Intro
echo -s 14/sview -c : 2Credits
echo -s 2-
halt
}
if ($1 == -u) { _sview.unload }
if ($1 == -n) { sview.intro.onload0 | halt }
if ($1 == -c) { _sview.credits | halt }
if ($1 != $null) { halt }
window -c @Script_View
;457
window -Sl15 +f @Script_View 1 23 799 438 @Script_View Arial 11
sview.titlebar
sview.status
window -a @Script_View
drawpic @SView.Titlebar 1 1 $shortfn($scriptdirsview.bmp)
window -a @Script_View
aline @Script_View 4,1 Script View $+ $str($chr(160),80) 9,1hlessing@iafrica.com $str($chr(160),90)
aline @Script_View $chr(160)
aline -p @Script_View $str($chr(160),2) Welcome to Script View v1.12 for mIRC v5.4+ by Pain !! RightClick and choose an option in the popups or DoubleClick a file in the listbox to view it.
aline @Script_View $chr(160)
set %sview.loop 1
:add
if ($findfile(%sview.dir,%sview.exten,%sview.loop) == $null) { goto next }
else {
aline -l @Script_View $nopath($findfile(%sview.dir,%sview.exten,%sview.loop))
inc %sview.loop 1
goto add
}
:next
window -S @Script_View
iline -l @Script_View 1 1,1 $str($chr(160),4) 4,1Script View 1,1 $str($chr(160),15)
iline -l @Script_View $calc($line(@Script_View,0,1) + 1) 8,1 EOL -4 $calc($line(@Script_View,0,1) - 1) files $str($chr(160),120)
.timersviewshine000 1 1 sview.intro.shine
if (%sview.title_ani_ == *) { .timersviewshineloop 0 300 sview.intro.shine }
drawtext -rc @SView.Titlebar $rgb(240,102,213) 95 1 100 15 - Welcome !
_sview.draw.titlebar
}
menu @Script_View {
dclick { sview.sview }
Refresh List: sview.refresh
-
Change Dir:sview.cdir
File
.New: run notepad.exe
.Open In
..Notepad: run notepad $findfile(%sview.dir,$sline(@Script_View,1),1)
..New Window: sview.newwindow
.-
.Copy file: sview.copyf
.Delete file: sview.delfile
.-
.Extension
..Set: sview.sexten
..*.mrc + *.ini:sview.sexten two
-
UnLoaded Scripts:sview.nogo.scripts
%sview.nogo.ext_ini Include *.ini : {
if %sview.nogo.ext_ini == ° {
set %sview.nogo.ext_ini | echo -se 4SV> 2Unloaded Scripts: 3Now not viewing *.ini's }
else { set %sview.nogo.ext_ini ° | echo -se 4SV> 2Unloaded Scripts: 3Now viewing *.ini's } }
-
Special
.Search:sview.search.dialog
.Goto Line:sview.goto.dialog
.Search for File: sview.slistbox.dialog
.-
.%sview.title_ani_ Titlebar Animation:sview.tile_onoff
-
Other
.%sview.exerun Auto Run EXE Files: sview.exerun
.%sview.picsrun Auto Open Pics:sview.picsrun
.%sview.htmlrun Auto Open HTML Files: sview.htmlrun
.-
.$str($chr(160),3) -=©<<Unwise>>©=-: _sview.unload
-
Help:{ sview.help }
About: { sview.about }
-
Quit:_quit.sview
}
on 1:Close:@Script_View:{
.timersviewshine* off
.timersviewcheck_statewin00 off
.timersviewstate off
.timersviewcheckwin_titlebar_ontop off
window -c @SView.Titlebar
window -c @sview_status
}
alias sview.cdir {
clear -l @Script_View
set %sview.dir $sdir="Select Dir with location of Script(s)"
set %sview.dir $nofile(%sview.dir)
if (%sview.dir == $null) { set %sview.dir $mircdir }
if (%sview.dir != $null) {
set %sview.loop 1
:add
if ($findfile(%sview.dir,%sview.exten,%sview.loop) == $null) {
iline -l @Script_View 1 1,1 $str($chr(160),4) 4,1Script View 1,1 $str($chr(160),15)
iline -l @Script_View $calc($line(@Script_View,0,1) + 1) 8,1 EOL -4 $calc($line(@Script_View,0,1) - 1) files $str($chr(160),120)
halt }
else {
aline -l @Script_View $nopath($findfile(%sview.dir,%sview.exten,%sview.loop))
inc %sview.loop 1
goto add } }
}
alias sview.sexten {
if ($1 == $null) { set %sview.exten $?="Enter new Extension eg. *.mrc or *.ini" }
if (%sview.exten != $null) { set %sview.exten_backup %sview.exten }
if (%sview.exten == $null) { set %sview.exten %sview.exten_backup | halt }
if ($2 == two) { set %sview.exten *.mrc }
clear -l @Script_View
if (%sview.dir != $null) {
set %sview.loop 1
aline -l @Script_View ~~4,1Please wait...~~
:add
if ($findfile(%sview.dir,%sview.exten,%sview.loop) == $null) {
dline -l @script_view 1
iline -l @Script_View 1 1,1 $str($chr(160),4) 4,1Script View 1,1 $str($chr(160),15)
iline -l @Script_View $calc($line(@Script_View,0,1) + 1) 8,1 EOL -4 $calc($line(@Script_View,0,1) - 1) files $str($chr(160),120)
halt }
else {
if ($1 == $null) { aline -l @Script_View $nopath($findfile(%sview.dir,%sview.exten,%sview.loop)) }
else {
:add2
if ($findfile(%sview.dir,*.mrc,%sview.loop) == $null) && ($findfile(%sview.dir,*.ini,%sview.loop) == $null) {
dline -l @script_view 1
iline -l @Script_View 1 1,1 $str($chr(160),4) 4,1Script View 1,1 $str($chr(160),15)
iline -l @Script_View $calc($line(@Script_View,0,1) + 1) 8,1 EOL -4 $calc($line(@Script_View,0,1) - 1) files $str($chr(160),120)
set %sview.exten *.mrc
halt
}
if ($findfile(%sview.dir,*.mrc,%sview.loop) != $null ) { aline -l @Script_View $nopath($findfile(%sview.dir,*.mrc,%sview.loop)) }
if ($findfile(%sview.dir,*.ini,%sview.loop) != $null) { aline -l @Script_View $nopath($findfile(%sview.dir,*.ini,%sview.loop)) }
inc %sview.loop 1
goto add2
}
inc %sview.loop 1
goto add } }
}
alias sview.sview {
if ($1 == $null) { set %sview.file $findfile(%sview.dir,$sline(@Script_View,1),1) }
if (.bmp isin %sview.file) || (.jpg isin %sview.file) || (.gif isin %sview.file) && (%sview.picsrun == * ) { run %sview.file }
if (.wav isin %sview.file) || (.mid isin %sview.file) { splay $shortfn(%sview.file) }
if (.htm isin %sview.file) || (.html isin %sview.file) && (%sview.htmlrun == *) { run %sview.file }
if ($sline(@Script_View,1).ln > 1) && ($sline(@Script_View,1).ln < $line(@Script_View,0,1)) {
clear @Script_View
aline @Script_View 4,1 $+ $chr(160) Script View $+ $str($chr(160),30) 8Viewing: $nopath(%sview.file) ( $+ $lof(%sview.file) bytes - $lines(%sview.file) lines) $str($chr(160),150)
aline @Script_View $chr(160)
loadbuf -p @Script_View $shortfn(%sview.file)
aline @Script_View 8,1 EOF4 - Successfully Loaded $lines(%sview.file) of $lines(%sview.file) lines $str($chr(160),250)
sline @Script_View 15
drawrect -fr @Sview.Titlebar $rgb(0,87,207) 1 100 1 25 15
drawrect -fr @Sview.Titlebar $rgb(0,82,200) 1 125 1 25 15
drawrect -fr @Sview.Titlebar $rgb(0,78,195) 1 150 1 25 15
drawrect -fr @Sview.Titlebar $rgb(0,74,190) 1 175 1 35 15
if ($len($nopath(%sview.file)) > 12) { drawtext -rc @SView.Titlebar $rgb(240,102,213) Fixedsys 9 95 1 500 20 - $nopath($shortfn(%sview.file)) }
else { drawtext -rc @SView.Titlebar $rgb(240,102,213) Fixedsys 9 95 1 500 20 - $nopath(%sview.file) }
titlebar @Script_View - $nopath(%sview.file)
drawrect -fr @sview_status $rgb(191,191,191) 1 4 3 400 14
drawtext -rc @sview_status $rgb(10,0,100) Arial 14 8 2 2000 15 %sview.file
}
}
alias sview.about {
sview.draw.win @SView.Titlebar 0 0 800 25 _title
_sview.draw.titlebar
drawtext -rc @SView.Titlebar $rgb(240,102,213) 95 1 100 15 - About
set %sview.file
clear @sview_status
sview.status skip
clear @Script_View
aline @Script_View 4,1 $chr(160) Script View $+ $str($chr(160),80) 9,1hlessing@iafrica.com $str($chr(160),20) 12ver 1.12 $str($chr(160),90)
aline @Script_View $chr(160)
aline @Script_View 3 August 1998
aline -p @Script_View $chr(160) Welcome ! Script View is an utility that can be used to have a quick and wider look at a certain script[or any other file]. Its all very easy too use, just goto Help and see what all the popups do. As I hope you will notice, Ive put hard work and a lot of my spare time into making this script look nicer, and also useable. 4Script View is a replacement for Notepad - its much easier to view a file in here than in there. You don't have to look into that $chr(268) cause you see it in colour, like it would be when you run that script. I believe that this script will
aline @Script_View make life much easier and it happens right here in mIRC. Enjoy!
aline @Script_View $chr(160)
aline @Script_View $chr(160) 4Features
aline @Script_View $chr(160) 2¤ Search through a file for certain text
aline @Script_View $chr(160) 2¤ Manage your files easily - copy and delete
aline @Script_View $chr(160) 2¤ Automatic Run on certain files (see Other in popups)
aline @Script_View $chr(160) 2¤ View files by directory and extension
aline @Script_View $chr(160) 2¤ Easy to use, you have control
aline @Script_View $chr(160)
aline -p @Script_View $chr(160) There are also other stuff. The little icon on the titlebar acts the same as that of any other mIRC window or basically any window. You can also double click it to close 4Script View.
aline -p @Script_View $chr(160) Then the Search for File command can be used to search for a specific file listed in the side-listbox.
aline -p @Script_View $chr(160) When you view a file you will be able to see the whole path of that file on you status bar at the bottom.
aline -p @Script_View $chr(160) Midis/Waves are also played automaticly
aline -p @Script_View $chr(160)
aline @Script_View 4 Please Note
aline -p @Script_View $chr(160) I got the idea for 4Script View from 4,1Log Master8,1 By Paul <kbhw@religious.com>. Get it at: 2hawkee.com
aline @Script_View $chr(160)
aline -p @Script_View $chr(160) Thank you for using 4Script View. I hope its as useful to as it is to me. There will be updates availible in the future so be sure to look for 'em. If you have any comments, suggestions, bug reports or questions please mail them to: 2hlessing@iafrica.com
aline @Script_View $chr(160)
aline @Script_View $chr(160) Oh, and, that nifty windows for Search,Delete,etc is all possible cause of a guy , EAE. Go to his brilliant page at: 2eae.net
aline @Script_View $chr(160) Please run /sview -c for the credits window
aline @Script_View $chr(160)
aline @Script_View $chr(160) 4Me
aline -p @Script_View $chr(160) I am 14, male, from a place called South Africa. I am suppose to be studying, but what the heck ? .. this is more fun :) I have been scripting for about ten months now and Im not planning to stop soon. Most of the scripts I write I write for myself to make life a little easier, so you can consider yourself lucky to have this :) I hangout at many servers looking for people but you can try and find me on Dalnet or ZANet. I would really appreciate it if you can drop me a line telling me what you think of 4Script View
aline @Script_View $chr(160)
aline @Script_View 1,1 $+ $str($chr(160),110) 8About1 $str($chr(160),120)
sline @Script_View 21
}
alias sview.search {
if (%sview.file == $null) { halt }
if ($1 == $null) { set %sview.searchwin SV }
if ($1 == nwin) { set %sview.searchwin NWin }
window -c @SView_Search
window -l @SView_Search 0 0 800 500 @SView_Search Arail 12
if (%sview.stext == $null) { window -c @SView_Search | window -a @Script_View | halt }
aline @SView_Search 4,1Script View $+ $str($chr(160),120) 8,1Search Results $str($chr(160),220) | aline @SView_Search 9,1 $+ $str($chr(160),45) Searching $nopath(%sview.file) For: 4 $+ %sview.stext $str($chr(160),220)
filter -fwn %sview.file @SView_Search %sview.stext
aline @SView_Search 4,1 Found $filtered matches in 8 $+ $nopath(%sview.file) $str($chr(160),220)
}
menu @Sview_Search {
dclick {
if (%sview.searchwin == NWin) { sview.gotosline nwin }
else { sview.gotosline } }
Goto Line:{
if (%sview.searchwin == NWin) { sview.gotosline nwin }
else { sview.gotosline } }
-
Close: window -c @SView_Search
}
on 1:Close:@SView_Search:{ set %sview.stext }
alias sview.gotosline {
if ($sline(@SView_Search,1).ln == $null) || ($sline(@SView_Search,1).ln == 1) || ($sline(@SView_Search,1).ln == 2) || ($sline(@SView_Search,1).ln == $line(@SView_Search,0,0)) { halt }
else {
if ($1 == $null) {
sline @Script_View $calc($gettok($sline(@Sview_Search,1),1,32) + 2)
window -a @Script_View
window -a @SView.Titlebar
}
else {
sline @ $+ %sview.newwin $calc($gettok($sline(@Sview_Search,1),1,32) + 2)
window -a @ $+ %sview.newwin
}
}
}
alias sview.gotoline {
if ($1 == nwin) { set %sview.gotowin @ $+ %sview.newwin }
if ($1 == $null) { set %sview.gotowin @Script_View }
if (%sview.gotoline == $null) || (%sview.gotoline == 0) || ($round(%sview.gotoline,3) == 0.000) { halt }
sline %sview.gotowin %sview.gotoline
}
alias sview.delfile {
if ($sline(@Script_View,1).ln == 1) || ($sline(@Script_View,1).ln == $line(@Script_View,0,1) ) { halt }
if (%sview.file == $null) { set %sview.file $sline(@Script_View,1) | set %sview.del.list true }
if (%sview.file == $null) { halt }
sview.draw.win @Delete_File 200 150 165 90
drawtext -rc @Delete_File $rgb(255,255,255) 50 1 200 20 Delete File
drawtext -rc @Delete_File $rgb(0,0,0) Arial 14 17 18 500 20 Are you sure want to delete
drawtext -rc @Delete_File $rgb(0,0,0) Arial 14 60 33 200 20 $nopath(%sview.file) $+ ?
sview.draw.but @Delete_File 19 52 50 20 Out
drawtext -rc @Delete_File $rgb(0,0,0) 32 55 100 20 Yes
sview.draw.but @Delete_File 79 52 50 20 Out
drawtext -rc @Delete_File $rgb(0,0,0) 95 55 100 20 No
}
menu @Delete_File {
sclick {
if ($inrect($mouse.x,$mouse.y,19,52,50,20) == $true) {
if (%sview.file == $null) { halt }
sview.draw.but @Delete_File 19 52 50 20 In
remove %sview.file
echo -se 4SV>2 $+ $nopath(%sview.file) $+ 3 $+ has been deleted!
window -c @Delete_File
window -a @Script_View
set %sview.file
sview.refresh
if (%sview.del.list == true) { set %sview.file | set %sview.del.list false }
.timersviewdelfileyes00 -m 1 200 window -c @Delete_File
}
if ($inrect($mouse.x,$mouse.y,79,52,50,20) == $true) {
sview.draw.but @Delete_File 79 52 50 20 In
.timerdelfiesviewno00 -m 1 250 window -c @Delete_File
} }
}
on 1:Close:@Delete_File: { if (%sview.del.list == true) { set %sview.file | set %sview.del.list false } }
alias sview.help {
sview.draw.win @SView.Titlebar 0 0 800 25 _title
_sview.draw.titlebar
drawtext -rc @SView.Titlebar $rgb(240,102,213) 95 1 100 15 - Help
titlebar @Script_View
set %sview.file
clear @Script_View
clear @sview_status
sview.status skip
aline @Script_View 4,1 $chr(160) Script View $+ $str($chr(160),80) 9,1hlessing@iafrica.com $str($chr(160),90)
aline @Script_View $chr(160)
aline -p @Script_View $chr(160) Look below for a list of the popups and what they do. Feel free to mail me if you have any difficulties or questions.
aline @Script_View $chr(160)
aline @Script_View $chr(160) 4Popups
aline @Script_View $chr(160) $chr(160) 2Refresh List - $str($chr(160),19) 1Updates / Reloads the files in the listbox on the right
aline @Script_View $chr(160) $chr(160) 2Change Dir - $str($chr(160),21) 1Change to the directory who's files you want to view (includes subdirectories)
aline @Script_View $chr(160) $chr(160) 2File
aline @Script_View $chr(160) $chr(160) 2 New - $str($chr(160),30) 1Creates a new Notepad File
aline @Script_View $chr(160) $chr(160) 2 Open In
aline @Script_View $chr(160) $chr(160) 2 $chr(160) Notepad - $str($chr(160),23) 1Open the selected file in Notepad
aline @Script_View $chr(160) $chr(160) 2 $chr(160) New Window - $str($chr(160),14) 1Open the selected file in a New Window
aline @Script_View $chr(160) $chr(160) 2 Copy - $str($chr(160),30) 1Copy selected file to specified directory
aline @Script_View $chr(160) $chr(160) 2 Delete - $str($chr(160),28) 1Delete selected file
aline @Script_View $chr(160) $chr(160) 2 Extension
aline @Script_View $chr(160) $chr(160) 2 $chr(160) Set - $str($chr(160),30) 1Set a new extension to list files by
aline @Script_View $chr(160) $chr(160) 2 $chr(160) *.mrc & *.ini - $str($chr(160),17) 1Lists all files with extensions *.mrc & *.ini
aline @Script_View $chr(160) $chr(160) 2UnLoaded Scripts - $str($chr(160),10) 1View all UnLoaded Scripts in your mIRC directory (remote scripts that are not loaded)
aline @Script_View $chr(160) $chr(160) 2Include *.ini - $str($chr(160),21) 1Includes *.ini files when doing a search on UnLoaded Scripts (Toggles On/Off)
aline @Script_View $chr(160) $chr(160) 2Special
aline @Script_View $chr(160) $chr(160) 2 Search - $str($chr(160),27) 1Search selected file for certain text
aline @Script_View $chr(160) $chr(160) 2 Goto Line - $str($chr(160),23) 1Goto a specific line
aline @Script_View $chr(160) $chr(160) 2 Search for File - $str($chr(160),15) 1Search for a filename in the side-listbox
aline @Script_View $chr(160) $chr(160) 2 Titlebar Animation - $str($chr(160),10) 1Turn Titlebar Animation On/Off
aline @Script_View $chr(160) $chr(160) 2Other
aline @Script_View $chr(160) $chr(160) 2 Auto Open EXE Files - $str($chr(160),6) 1Automaticly opens EXE Files
aline @Script_View $chr(160) $chr(160) 2 Auto Open Pics - $str($chr(160),13) 1Automaticly opens a picture (*.bmp *.jpg *.gif)
aline @Script_View $chr(160) $chr(160) 2 Auto Open HTML files - $str($chr(160),3) 1Automaticly opens an HTML File
aline @Script_View $chr(160) $chr(160) 2 -=©<<Unwise>>©=- - $str($chr(160),6) 1Unloads 4Script View
aline @Script_View $chr(160) $chr(160) 2Help - $str($chr(160),33) 1Displays this
aline @Script_View $chr(160) $chr(160) 2About - $str($chr(160),30) 1About 4Script View
aline @Script_View $chr(160) $chr(160) 2Quit - $str($chr(160),33) 1Quits 4Script View
aline @Script_View $chr(160)
aline @Script_View $chr(160) 4Commands
aline @Script_View $chr(160)
aline @Script_View $chr(160) $chr(160) 2/sview -? - List these commands
aline @Script_View $chr(160) $chr(160) 2/sview -n - 4Script View Intro
aline @Script_View $chr(160) $chr(160) 2/sview -c - Credits
aline @Script_View $chr(160) $chr(160) 2/sview -u - Unloads 4Script View
aline @Script_View $chr(160)
aline @Script_View 1,1 $+ $str($chr(160),110) 8Help1 $str($chr(160),120)
sline @Script_View 25
}
alias sview.refresh {
clear -l @Script_view
set %sview.loop 1
:add
if ($findfile(%sview.dir,%sview.exten,%sview.loop) == $null) {
iline -l @Script_View 1 1,1 $str($chr(160),4) 4,1Script View 1,1 $str($chr(160),15)
iline -l @Script_View $calc($line(@Script_View,0,1) + 1) 8,1 EOL -4 $calc($line(@Script_View,0,1) - 1) files $str($chr(160),120)
halt }
else {
aline -l @Script_View $nopath($findfile(%sview.dir,%sview.exten,%sview.loop))
inc %sview.loop 1
goto add
}
}
alias sview.copyf {
if ($sline(@Script_View,1).ln == 1) || ($sline(@Script_View,1).ln == $line(@Script_View,0,1) ) { halt }
if (%sview.file == $null) { set %sview.file $findfile(%sview.dir,$sline(@Script_View,1),1) | set %sview.copy.nofile true }
set %sview.copydes $sdir="Select Destination of $nopath(%sview.file) "
if (%sview.copydes == $null) { halt }
set %sview.copydes $nofile(%sview.copydes)
set %sview.copy.all %sview.copydes $+ $nopath(%sview.file)
if ($exists(%sview.copy.all) == $true) { sview.copy.oops | halt }
.copy %sview.file %sview.copydes
echo -se 4SV>2 $+ $nopath(%sview.file) $+ $+ 3 copied to 12 $+ %sview.copydes
if (%sview.copy.nofile == true) { set %sview.file | set %sview.copy.nofile false }
window -a @Script_View
}
alias sview.copy.oops {
sview.draw.win @SVError 200 150 200 100
beep 8 1
drawtext -rc @SVError $rgb(0,0,0) Arial 15 65 1 150 20 Copy Error !
drawtext -rc @SVError $rgb(0,0,0) Arial 14 7 26 500 20 The file $nopath(%sview.file) allready exists
drawtext -rc @SVError $rgb(0,0,0) Arial 14 70 46 200 20 Overwrite ?
sview.draw.but @SVError 39 62 50 20 Out
drawtext -rc @SVError $rgb(0,0,0) 52 65 100 20 Yes
sview.draw.but @SVError 99 62 50 20 Out
drawtext -rc @SVError $rgb(0,0,0) 115 65 100 20 No
}
menu @SVError {
sclick {
if ( $inrect($mouse.x,$mouse.y,39,62,50,20) == $true) {
sview.draw.but @SVError 39 62 50 20 In
.timersviewcopyclose00 -m 1 300 window -c @SVError
sview.sview
.copy -o %sview.file %sview.copydes
echo -se 4SV>2 $+ $nopath(%sview.file) $+ $+ 3 copied to 12 $+ %sview.copydes
}
if ( $inrect($mouse.x,$mouse.y,99,62,50,20) == $true ) {
sview.draw.but @SVError 99 62 50 20 In
.timersverrorclose01 -m 1 200 window -c @SVError
} }
}
alias sview.tile_onoff {
if (%sview.title_ani_ == *) { set %sview.title_ani_ | echo -se 4SV> Titlebar Animation 8,1Off | .timersviewshineloop off | halt }
if (%sview.title_ani_ == $null) { set %sview.title_ani_ * | echo -se 4SV> Titlebar Animation 8,1On | .timersviewshineloop 0 300 sview.intro.shine | halt }
}
alias sview.newwindow {
if ($sline(@Script_View,1).ln > 1) && ($sline(@Script_View,1).ln < $line(@Script_View,0,1)) {
set %sview.newwin $sline(@Script_View,1)
window @ $+ %sview.newwin 0 0 800 500 @NewWin Arial 11
set %sview.file $findfile(%sview.dir,$remove($active,@),1)
aline @ $+ %sview.newwin 4,1 $chr(160) Script View $+ $str($chr(160),20) 8Viewing $nopath(%sview.file) ( $+ $lof(%sview.file) bytes - $lines(%sview.file) lines) $str($chr(160),250)
aline @ $+ %sview.newwin $chr(160)
loadbuf -p @ $+ %sview.newwin %sview.file
aline @ $+ %sview.newwin 8,1 EOF4 - Successfully Loaded $lines(%sview.file) of $lines(%sview.file) lines $str($chr(160),250)
sline @ $+ %sview.newwin 15
}
else { echo -se 4SV> 3Invalid Choice ! }
}
menu @SVScripts {
Set INI file: sview.setini.file
-
Close Window: window -c @SvScripts
}
alias sview.setini.file {
set %sview.s.ini $dir="Select yout mIRC .ini file ( eg. mirc.ini )" *.ini
if (%sview.s.ini == $null) { set %sview.s.ini $mircdir $+ mirc.ini }
sview.ini.update
}
alias sview.ini.update {
clear @SVScripts
}
menu Status,Channel,Menubar {
-
Script Viewer: sview
-
}
alias sview.intro.shine {
.timersviewshine00 -m 1 100 drawtext -roc @Sview.Titlebar $rgb(210,0,0) Arial 15 20 1 50 15 S
.timersviewshine01 -m 1 200 drawtext -roc @Sview.Titlebar $rgb(210,0,0) Arial 15 29 1 50 15 c
.timersviewshine02 -m 1 300 drawtext -roc @Sview.Titlebar $rgb(210,0,0) Arial 15 36 1 50 15 r
.timersviewshine03 -m 1 400 drawtext -roc @Sview.Titlebar $rgb(210,0,0) Arial 15 41 1 50 15 i
.timersviewshine04 -m 1 500 drawtext -roc @Sview.Titlebar $rgb(210,0,0) Arial 15 45 1 50 15 p
.timersviewshine05 -m 1 600 drawtext -roc @Sview.Titlebar $rgb(210,0,0) Arial 15 53 1 50 15 t
.timersviewshine06 -m 1 700 drawtext -roc @Sview.Titlebar $rgb(210,0,0) Arial 15 61 1 50 15 V
.timersviewshine07 -m 1 800 drawtext -roc @Sview.Titlebar $rgb(210,0,0) Arial 15 69 1 50 15 i
.timersviewshine08 -m 1 900 drawtext -roc @Sview.Titlebar $rgb(210,0,0) Arial 15 73 1 50 15 e
.timersviewshine09 -m 1 1000 drawtext -roc @Sview.Titlebar $rgb(210,0,0) Arial 15 81 1 50 15 w
.timersviewshine10 -m 1 1100 drawtext -roc @Sview.Titlebar $rgb(255,255,255) Arial 15 81 1 50 15 w
.timersviewshine11 -m 1 1200 drawtext -roc @Sview.Titlebar $rgb(255,255,255) Arial 15 73 1 50 15 e
.timersviewshine12 -m 1 1300 drawtext -roc @Sview.Titlebar $rgb(255,255,255) Arial 15 69 1 50 15 i
.timersviewshine13 -m 1 1400 drawtext -roc @Sview.Titlebar $rgb(255,255,255) Arial 15 61 1 50 15 V
.timersviewshine14 -m 1 1500 drawtext -roc @Sview.Titlebar $rgb(255,255,255) Arial 15 53 1 50 15 t
.timersviewshine15 -m 1 1600 drawtext -roc @Sview.Titlebar $rgb(255,255,255) Arial 15 45 1 50 15 p
.timersviewshine16 -m 1 1700 drawtext -roc @Sview.Titlebar $rgb(255,255,255) Arial 15 41 1 50 15 i
.timersviewshine17 -m 1 1800 drawtext -roc @Sview.Titlebar $rgb(255,255,255) Arial 15 36 1 50 15 r
.timersviewshine18 -m 1 1900 drawtext -roc @Sview.Titlebar $rgb(255,255,255) Arial 15 29 1 50 15 c
.timersviewshine19 -m 1 2000 drawtext -roc @Sview.Titlebar $rgb(255,255,255) Arial 15 20 1 50 15 S
}
alias sview.nogo.scripts {
if ($window(@Sview).state == $null) {
window -ls @SView 100 50 500 450 @Sview Arial 11
titlebar @Sview - Please Wait ...
}
set %sview.nogo.fcount 1
set %sview.nogo.match false
:start
set %sview.nogo.file $remove($findfile($mircdir,%sview.nogo.ext,%sview.nogo.fcount),$mircdir)
if (%sview.nogo.file == $null) { sview.nogo.done }
else {
if (%sview.nogo.ext == *.mrc ) { goto next }
if (%sview.nogo.ext == *.ini ) {
window -lh @SV.Temp
window -a @SView
filter -fw %sview.nogo.file @SV.Temp *alias * {
if ($line(@SV.Temp,0,0) != 0) && ($read -l1 %sview.nogo.file != [aliases] ) { window -c @SV.Temp | goto next }
else {
clear @SV.Temp
filter -fw %sview.nogo.file @SV.Temp raw *
window -a @SView
if ($line(@SV.Temp,0,0) != 0) { window -c @SV.Temp | goto next }
else {
clear @SV.Temp
filter -fw %sview.nogo.file @SV.Temp *on *:
if ($line(@SV.Temp,0,0) != 0) { window -c @SV.Temp | goto next }
else {
window -c @SV.Temp
window -a @SView
inc %sview.nogo.fcount 1
goto start } } } } }
:next
inc %sview.nogo.fcount 1
set %sview.nogo.loop 0
:loop
if (%sview.nogo.loop == 0) { set %sview.nogo.ini.count n2 }
else { set %sview.nogo.ini.count n $+ %sview.nogo.loop }
set %sview.nogo.ini.read $readini $mircini rfiles %sview.nogo.ini.count
if (%sview.nogo.ini.read == $null) {
if (%sview.nogo.match == true) { aline @Sview %sview.nogo.file }
set %sview.nogo.match false
goto start
}
inc %sview.nogo.loop 1
if (%sview.nogo.ini.read == %sview.nogo.file) { goto start }
else {
set %sview.nogo.match true
goto loop }
}
}
menu @SView {
dclick {
if ($sline(@Sview,1).ln > 1) && ($sline(@Sview,1).ln != $line(@Sview,0,1)) { echo -se 4SV>3 Loading 2 $+ $sline(@SView,1) $+ $+ 3 ... | load -rs $sline(@SView,1) }
else { halt }
}
View: { set %sview.file $mircdir $+ $sline(@SView,1) | sview.sview @SView }
-
Close Window: window -c @Sview
}
alias sview.htmlrun {
if (%sview.htmlrun == *) { set %sview.htmlrun $chr(160) | echo -se 4SV>5 Auto Open HTML Files 8,1off }
else { set %sview.htmlrun * | echo -se 4SV>5 Auto Open HTML File 8,1on }
}
alias sview.picsrun {
if (%sview.picsrun == *) { set %sview.picsrun $chr(160) | echo -se 4SV>5 Auto Open Pics 8,1off }
else { set %sview.picsrun * | echo -se 4SV>5 Auto Open Pics 8,1on }
}
;run stuff
alias sview.exerun {
if (%sview.exerun == *) { set %sview.exerun $chr(160) | echo -se 4SV>5 Auto Open EXE Files 8,1Off }
else { set %sview.exerun * | echo -se 4SV>5 Auto Open EXE File 8,1On }
}
menu @NewWin {
File
.Open In
..Notepad: run notepad $findfile(%sview.dir,$sline(@Script_View,1),1)
..New Window: sview.newwindow
.-
.Copy file: sview.copyf
.Delete file: sview.delfile
-
Search:sview.search.dialog nwin
Goto Line:sview.goto.dialog nwin
-
Close Window:window -c @ $+ %sview.newwin
}
;EOF