[Rainmeter]
Author=Jeffrey Morley
Update=1000
LeftMouseUpAction=!Execute ["#ADDONSPATH#RainClip\RainClip.exe" "[MeasureIPWeb]"]

[Metadata]
Name=JSNetwork
Config=JSNetwork
Description=Network Information
Instructions=Edit UserVariables.inc to change colors, image path and network interface
Version=Aug 10, 2011
License=Creative Commons Attribution-Non-Commercial-Share Alike 3.0

[Variables]
@Include="#ROOTCONFIGPATH#JSNetwork\UserVariables.inc"

[MeterAllBackground]
Meter=IMAGE
W=130
H=87
SolidColor=0,0,0,1

;[GATHER Network]=================================

[MeasureNetwork]
Measure=Plugin
Plugin=WebParser.dll
Url=http://www.msftncsi.com/ncsi.txt
RegExp="(.*)"
UpdateRate=30
ForceReload=1
StringIndex=1
FinishAction=!EnableMeasure MeasureNetworkLua #CURRENTCONFIG#

[MeasureNetIn]
Measure=NetIn
Interface=#Interface#

[MeasureInDelay]
Measure=Calc
Formula=MeasureNetIn

[MeasureNetOut]
Measure=NetOut
Interface=#Interface#

[MeasureOutDelay]
Measure=Calc
Formula=MeasureNetOut

;[Network WEB IP]=================================

[MeasureIPWeb]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=http://checkip.dyndns.org
RegExp="(?siU)Address: (.*)</body>"
StringIndex=1
UpdateRate=30000

[MeterWANImage]
Meter=Image
ImageName=#ImagePath#lantext.png
X=-2
Y=0
W=32
H=32

[MeterWANIPText]
Meter=STRING
MeasureName=MeasureIPWeb
X=150
Y=9r
FontFace=#FontFace#
FontColor=#MyColor2#
SolidColor=0,0,0,1
FontSize=11
StringStyle=NORMAL
StringAlign=RIGHT
AntiAlias=1
Text=%1

;[Network TRAFFIC IMAGE]========================

[MeterNetworkImage]
Meter=IMAGE
ImageName="#ImagePath#NetworkError.png"
X=4
Y=24r
W=30
H=30
AntiAlias=1

[MeasureNetworkLua]
Measure=SCRIPT
ScriptFile=#CURRENTPATH#JSNetwork.lua
Disabled=1

;[Network INBOUND TRAFFIC]========================

[MeterNetInPre]
Meter=STRING
X=48
Y=0r
FontFace=#FontFace#
FontColor=#MyColor2#
FontSize=11
StringStyle=NORMAL
StringAlign=LEFT
AntiAlias=1
Text="DN:"

[MeterNetInText]
MeasureName=MeasureInDelay
Meter=STRING
X=145
Y=0r
FontFace=#FontFace#
FontColor=#MyColor1#
FontSize=11
StringStyle=NORMAL
StringAlign=RIGHT
AntiAlias=1
AutoScale=1
NumOfDecimals=1
Text="%1B"

;[Network OUTBOUND TRAFFIC]=======================

[MeterNetOUTPre]
Meter=STRING
X=48
Y=15r
FontFace=#FontFace#
FontColor=#MyColor2#
FontSize=11
StringStyle=NORMAL
StringAlign=LEFT
AntiAlias=1
Text="UP:  "

[MeterNetOutText]
MeasureName=MeasureOutDelay
Meter=STRING
X=145
Y=0r
FontFace=#FontFace#
FontColor=#MyColor1#
FontSize=11
StringStyle=NORMAL
StringAlign=RIGHT
AntiAlias=1
AutoScale=1
NumOfDecimals=1
Text="%1B"
