07 Mart 2010, 15:17
#1 Çevrimiçi
Kullanıcıların profil bilgileri misafirlere kapatılmıştır.
Ders ; mToolbar.dll Buttons
Merhabalar ..
Tekrar mToolbar.Dll hakkinda bir ders hazirlamak istedim.
cunku Anlattigim 1. ders 'te eksikliklerim var.
Bu ders 'te size mToolbar Designer v.Beta 'daki Button
olusturma ozelliklerini anlaticam.
Dersi Anlatan : Rohit \ Sevket
Gerekli Malzeme ;
mToolbar.Dll
Hos.Dll
mtb isminde bir klasor
2 tane icon isimler ; go.ico - toolbox.ico
* \ Sorular \*
mToolbar.dll ile Button meydana nasil gelir ?
Button'a tikladigim zaman belirttigim dialog'u Nasil aktivite eder ?
icon nasil eklerim ?
Rengini ve Seklini Nasil Ayarlarim ?
1. Button Baslangic.
Kod: Kodu kopyalamak için üzerine çift tıklayın!
mtb Toolbar AddButton 1 17 5 149 67 > 1. Start
mtb Toolbar ButtonColors -i 1 16777215 15199215 8421504 13029334 15463415 16771022 15697005 13562879 38631
mtb Toolbar ButtonEnabled -i 1 $true
mtb Toolbar ButtonIconSize 1 16 16
mtb Toolbar ButtonShowTooltip -i 1 $false
mtb Toolbar ButtonShowFocusRect -i 1 $false
mtb Toolbar ButtonTooltip 1 >
Bu forumdaki linkleri ve resimleri görebilmek için en az 25 mesajınız olması gerekir.
2. Button Renklendirme
Kod: Kodu kopyalamak için üzerine çift tıklayın!
on *:dialog:mircdb_toolbar:init:*: {
if ($mtbdll(IsTreeBar) == $true) mtb KillTreeBar
if ($mtbdll(IsToolbar) == $true) mtb KillToolbar
hos Dock $dname top 0
hos DockSize $dname 115
mtb Toolbar Create 115 $dname
mtb Toolbar ShowBgColor $false
mtb Toolbar BgColor 15395562 10987431 16711680
mtb Toolbar ShowBgPicture $false
mtb Toolbar BgPicture > none
mtb Toolbar BgGradStyle Butterfly
mtb Toolbar BgGradShift 0
mtb Toolbar BgGradRotation 0
mtb Toolbar ShowBgTooltip $false
mtb Toolbar BgTooltip > $chr(32)
mtb Toolbar BgDrawBorder $false
mtb Toolbar AddButton 1 17 5 149 67 > 1. Start
mtb Toolbar ButtonColors -i 1 16711680 0 255 13029334 15463415 16771022 15697005 13562879 38631
mtb Toolbar ButtonEnabled -i 1 $true
mtb Toolbar ButtonIconSize 1 16 16
mtb Toolbar ButtonShowTooltip -i 1 $false
mtb Toolbar ButtonShowFocusRect -i 1 $false
mtb Toolbar ButtonTooltip 1 >
mtb Toolbar ButtonIconPos -i 1 left
mtb Toolbar ButtonGradientStyle -i 1 LinearH
mtb Toolbar ButtonFont -i 1 9 +b 16777215 > Tahoma
mtb Toolbar ButtonShowHotTrack 1 $false
mtb Toolbar ButtonText 1 > 1. Start
}
Bu forumdaki linkleri ve resimleri görebilmek için en az 25 mesajınız olması gerekir.
3. icon ekleme
Kod: Kodu kopyalamak için üzerine çift tıklayın!
dialog mircdb_toolbar {
title "New Project"
size -1 -1 372 50
option dbu
}
on *:dialog:mircdb_toolbar:init:*: {
if ($mtbdll(IsTreeBar) == $true) mtb KillTreeBar
if ($mtbdll(IsToolbar) == $true) mtb KillToolbar
hos Dock $dname top 0
hos DockSize $dname 108
mtb Toolbar Create 108 $dname
mtb Toolbar ShowBgColor $false
mtb Toolbar BgColor 15395562 10987431 16711680
mtb Toolbar ShowBgPicture $false
mtb Toolbar BgPicture > none
mtb Toolbar BgGradStyle Butterfly
mtb Toolbar BgGradShift 0
mtb Toolbar BgGradRotation 0
mtb Toolbar ShowBgTooltip $false
mtb Toolbar BgTooltip > $chr(32)
mtb Toolbar BgDrawBorder $false
mtb Toolbar AddButton 1 5 3 216 67 > Connect \ Disconnect
mtb Toolbar ButtonIcon 1 > C:\ \A LL\Codes\button ico\48X48\go.ico
mtb Toolbar ButtonColors -i 1 16711680 0 255 13029334 15463415 16771022 15697005 13562879 38631
mtb Toolbar ButtonEnabled -i 1 $true
mtb Toolbar ButtonIconSize 1 32 32
mtb Toolbar ButtonShowTooltip -i 1 $false
mtb Toolbar ButtonShowFocusRect -i 1 $false
mtb Toolbar ButtonTooltip 1 >
mtb Toolbar ButtonIconPos -i 1 left
mtb Toolbar ButtonGradientStyle -i 1 LinearH
mtb Toolbar ButtonFont -i 1 9 +b 16777215 > Tahoma
mtb Toolbar ButtonShowHotTrack 1 $false
mtb Toolbar ButtonText 1 > Connect \ Disconnect
mtb Toolbar AddButton 4 224 3 238 67 > Control Panel
mtb Toolbar ButtonIcon 4 > C:\ \A LL\Codes\button ico\48X48\toolbox.ico
mtb Toolbar ButtonColors -i 4 16711680 0 255 13029334 15463415 16771022 15697005 13562879 38631
mtb Toolbar ButtonEnabled -i 4 $true
mtb Toolbar ButtonIconSize 4 32 32
mtb Toolbar ButtonShowTooltip -i 4 $false
mtb Toolbar ButtonShowFocusRect -i 4 $false
mtb Toolbar ButtonTooltip 4 >
mtb Toolbar ButtonIconPos -i 4 left
mtb Toolbar ButtonGradientStyle -i 4 LinearH
mtb Toolbar ButtonFont -i 4 9 +b 16777215 > Tahoma
mtb Toolbar ButtonShowHotTrack 4 $false
mtb Toolbar ButtonText 4 > Control Panel
}
Bu forumdaki linkleri ve resimleri görebilmek için en az 25 mesajınız olması gerekir.
4. Botton Aktivite (tiklama)
Kod: Kodu kopyalamak için üzerine çift tıklayın!
on *:signal:mToolbar:{
if $1 == sclick {
;echo -a $1-
if $4 == 1 { if ($scid($activecid).status = connecting || $scid($activecid).status = connected ) { scid $activecid disconnect } | else { scid $activecid server } scid $activecid window -a "status window" }
if $4 == 2 { dialog -m cpanel cpanel }
}
}
Bu forumdaki linkleri ve resimleri görebilmek için en az 25 mesajınız olması gerekir.
5. Deneme Toolbar.
Kod: Kodu kopyalamak için üzerine çift tıklayın!
alias tb if $dialog(mircdb_toolbar) { dialog -c mircdb_toolbar mircdb_toolbar } | else { dialog -m mircdb_toolbar mircdb_toolbar }
alias mircdb_toolbar {
}
alias hos dll $shortfn(mtb/hos.dll) $1-
alias mtbdll return $dll($shortfn(mtb/mtoolbar.dll),$1,)
alias mtb dll $shortfn(mtb/mtoolbar.dll) $1-
dialog mircdb_toolbar {
title "MedyaToolbar"
size -1 -1 372 25
option dbu
}
on *:dialog:mircdb_toolbar:init:*: {
if ($mtbdll(IsTreeBar) == $true) mtb KillTreeBar
if ($mtbdll(IsToolbar) == $true) mtb KillToolbar
hos Dock $dname top 0
hos DockSize $dname 80
mtb Toolbar Create 80 $dname
mtb Toolbar ShowBgColor $false
mtb Toolbar BgColor 15395562 10987431 16711680
mtb Toolbar ShowBgPicture $false
mtb Toolbar BgPicture > none
mtb Toolbar BgGradStyle Butterfly
mtb Toolbar BgGradShift 0
mtb Toolbar BgGradRotation 0
mtb Toolbar ShowBgTooltip $false
mtb Toolbar BgTooltip > $chr(32)
mtb Toolbar BgDrawBorder $false
mtb Toolbar AddButton 1 5 3 216 67 > Connect \ Disconnect
mtb Toolbar ButtonIcon 1 > mtb\go.ico
mtb Toolbar ButtonColors -i 1 16711680 0 255 13029334 15463415 16771022 15697005 13562879 38631
mtb Toolbar ButtonEnabled -i 1 $true
mtb Toolbar ButtonIconSize 1 32 32
mtb Toolbar ButtonShowTooltip -i 1 $false
mtb Toolbar ButtonShowFocusRect -i 1 $false
mtb Toolbar ButtonTooltip 1 >
mtb Toolbar ButtonIconPos -i 1 left
mtb Toolbar ButtonGradientStyle -i 1 LinearH
mtb Toolbar ButtonFont -i 1 9 +b 16777215 > Tahoma
mtb Toolbar ButtonShowHotTrack 1 $false
mtb Toolbar ButtonText 1 > Connect \ Disconnect
mtb Toolbar AddButton 4 224 3 238 67 > Control Panel
mtb Toolbar ButtonIcon 4 > mtb\toolbox.ico
mtb Toolbar ButtonColors -i 4 16711680 0 255 13029334 15463415 16771022 15697005 13562879 38631
mtb Toolbar ButtonEnabled -i 4 $true
mtb Toolbar ButtonIconSize 4 32 32
mtb Toolbar ButtonShowTooltip -i 4 $false
mtb Toolbar ButtonShowFocusRect -i 4 $false
mtb Toolbar ButtonTooltip 4 >
mtb Toolbar ButtonIconPos -i 4 left
mtb Toolbar ButtonGradientStyle -i 4 LinearH
mtb Toolbar ButtonFont -i 4 9 +b 16777215 > Tahoma
mtb Toolbar ButtonShowHotTrack 4 $false
mtb Toolbar ButtonText 4 > Control Panel
}
on *:start: dialog -m mircdb_toolbar mircdb_toolbar