You are not logged in.
great to see that feature in action
well done sector11 and Deegan
great to see that feature in action
well done sector11 and Deegan

Offline
mrpeachy wrote:great to see that feature in action
well done sector11 and DeeganSector11 wrote:great to see that feature in action
well done sector11 and Deegan
![]()
![]()
![]()
Did I really quote that???? OH MY!!!

Hi Deegan ... well done - on both counts, the translation and finding that Oops!
Anyway, one conky (~/Il_Tempo/il_tempo.conky) with two templates in Italian.![]()
Simple change of commenting three lines and uncommenting another three makes the difference.
########################################################################
## = ITXX0069I_template.lua
lua_load ~/Il_Tempo/ITXX0069I_template.lua
minimum_size 190 880 ## width, height
maximum_width 190 ## width
## = s11template.lua ###################################################
#lua_load ~/Il_Tempo/s11template.lua
#minimum_size 425 530 ## width, height
#maximum_width 425 ## width
## must use a line after TEXT, even if an empty line
TEXT7MB! Il_Tempo.tar.gz ... BUT "everything" is in the one directory: ~/Il_Tempo/
EDIT: available again - mrpeachy fixed the bug
No matter what I do: today's condition will not translate.
but mrpeachy fixed it.
Last edited by Sector11 (2012-03-08 13:46:56)
#! Etiquette | Conky PitStop | VSIDO | Interactive LUA
Weather v9000 | Teo x4 Sites | Arclance | Finnish
Offline
No matter what I do: today's condition will not translate.
hmmm... ill see about tracking that down later today
Offline
hmmm... ill see about tracking that down later today
Thank you. No idea why.
It did work with one version of v9000, but I'm using the latest to get the 24 hour stuff and the now{conditions_short} doesn't work
~/Il_Tempo/s11template.lua
txt=now["conditions_short"]})
~/Il_Tempo/.ITXX0069I_config.lua
txt=now["conditions_short"]})
Which at the moment shows:
Scattered Clouds
but the translate table says:
["Scattered Clouds"]="Nubi Sparse",
And worse ... now it refuses to run:
15:22:04 ~
$ conky -c ~/Il_Tempo/il_tempo.conky &
[1] 12797
15:22:06 ~
$ Conky: llua_load: /home/sector11/Il_Tempo/ITXX0069I_template.lua:91: unfinished string near '"fc_hour3_time_24]})'
Conky: desktop window (15d) is root window
Conky: window type - normal
Conky: drawing to created window (0x2200001)
Conky: drawing to double buffer
gathering data with curl
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 68031 100 68031 0 0 48408 0 0:00:01 0:00:01 --:--:-- 55535
not checking for alerts
processing complete
Conky: llua_do_call: function conky_weather execution failed: /home/sector11/Il_Tempo/v9000.lua:982: attempt to call field '?' (a nil value)
Conky: llua_do_call: function conky_weather execution failed: /home/sector11/Il_Tempo/v9000.lua:982: attempt to call field '?' (a nil value)981 if processall==0 or testing==1 then
982 _G.weather_script()
983 end
I'm gonna give up on LUA!
#! Etiquette | Conky PitStop | VSIDO | Interactive LUA
Weather v9000 | Teo x4 Sites | Arclance | Finnish
Offline
new here and having a problem with my lua setup.
i was running linux mint 12 and it was fine. I switched to lubuntu.
now lua wont work.
seth@icarus:~$ conky
Conky: forked to background, pid is 3099
seth@icarus:~$
Conky: desktop window (140012f) is subwindow of root window (14c)
Conky: window type - normal
Conky: drawing to created window (0x2e00002)
Conky: drawing to double buffer
gathering data with curl
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 68530 100 68530 0 0 124k 0 --:--:-- --:--:-- --:--:-- 207k
you have no weather alerts
processing complete
Conky: llua_do_call: function conky_weather execution failed: /home/seth/v9000/v9000.lua:921: attempt to call field '?' (a nil value)
Conky: llua_do_call: function conky_weather execution failed: /home/seth/v9000/v9000.lua:921: attempt to call field '?' (a nil value)again this all worked fine before.
I just can't figure out what's up with lua.
here's my conky -v output
seth@icarus:~$ conky -v
Conky 1.8.1 compiled Fri Dec 16 17:59:40 UTC 2011 for Linux 2.6.24-29-server (i686)
Compiled in features:
System config file: /etc/conky/conky.conf
Package library path: /usr/lib/conky
X11:
* Xdamage extension
* XDBE (double buffer extension)
* Xft
* ARGB visual
Music detection:
* Audacious
* MPD
* MOC
* XMMS2
General:
* math
* hddtemp
* portmon
* Curl
* RSS
* Weather (METAR)
* Weather (XOAP)
* wireless
* support for IBM/Lenovo notebooks
* nvidia
* eve-online
* config-output
* Imlib2
* apcupsd
* iostats
* ncurses
* Lua
Lua bindings:
* Cairo
* Imlib2
seth@icarus:~$ any help is appreciated.
Offline
I'm gonna give up on LUA!
Come on S11 your knowledge is NEEDED in this area!! + MrPeachy needs you to keep him on his toes!! 
Peachy's v9000 / Conky PitStop / My DA Page / VSIDO
Make it so....
Offline
here is a fix for the current conditions not being translated
the problem was that the length werent matching because some spaces were being added by the script the end the descriptions coming from intellicast
in v9000.lua , lines 676 and 677 should currently be this
local cons_length=string.len(cons)
local match_length=string.len(k)change to this
local cons_length=string.len(string.gsub(cons,"%s",""))
local match_length=string.len(string.gsub(k,"%s",""))im removing all the spaces and matching the number of characters
EDIT - no longer using this method in v9000.lua, see a couple of posts down
Last edited by mrpeachy (2012-03-06 02:34:10)
Offline
as for why v9000.lua isnt finding the template script...
981 if processall==0 or testing==1 then
982 _G.weather_script()
983 endat the top of the weather template lua, for example
"weather_script.lua"
should be this
--DISPLAY FUNCTION--DISPLAY FUNCTION--DISPLAY FUNCTION--DISPLAY FUNCTION-
_G.weather_script = function()--#### DO NOT EDIT THIS LINE ##############
--#######################################################################@ sector11, has anything changed from the last time v9000 was running to when it stopped?
@ setherd can you post your conkyrc that runs the lua script?
Offline
@ sector11m just took a second look at your post and saw this
$ Conky: llua_load: /home/sector11/Il_Tempo/ITXX0069I_template.lua:91: unfinished string near '"fc_hour3_time_24]})'have you edited ITXX0069I_template.lua since you posted it?
can you post the non working template?
Last edited by mrpeachy (2012-03-05 22:19:54)
Offline
re current conditions not getting translated
it might be a better idea to remove the trailing white spaces from the conditions description before passing it to the translation function or displaying it
in v9000.lua lines 669 and 670 look like this
local s,f,t=string.find(nowweather,"class=%pIcon%p /> ([%a%s%p]*)%s*</td>%s*<td class=%pEmpty%p> ")
now["conditions"]=tadd a line inbetween to remove the shitespaces
local s,f,t=string.find(nowweather,"class=%pIcon%p /> ([%a%s%p]*)%s*</td>%s*<td class=%pEmpty%p> ")
local t=t:gsub("^%s*(.-)%s*$", "%1")
now["conditions"]=tive switched the fix in v9000.lua to the above
this way you can use the xout function to justify the weather condition correctly and accurately calculate the length of the conditions text
Last edited by mrpeachy (2012-03-06 00:02:15)
Offline
@ sector11m just took a second look at your post and saw this
$ Conky: llua_load: /home/sector11/Il_Tempo/ITXX0069I_template.lua:91: unfinished string near '"fc_hour3_time_24]})'have you edited ITXX0069I_template.lua since you posted it?
can you post the non working template?
Do not recall .. trying for hours with no luck...
ITXX0069I_template.lua
--[[
The latest script is a lua only weather script. aka: v9000
http://crunchbanglinux.org/forums/topic/16100/weather-in-conky/
the file:
http://dl.dropbox.com/u/19008369/weatheragain9000.lua.tar.gz
mrppeachys LUA Tutorial
http://crunchbanglinux.org/forums/topic/17246/how-to-using-lua-scripts-in-conky/
]]
_G.weather_script = function()--#### DO NOT EDIT THIS LINE ##############
--these tables hold the coordinates for each repeat do not edit #########
top_left_x_coordinate={}--###############################################
top_left_y_coordinate={}--###############################################
--#######################################################################
--SET DEFAULTS ##########################################################
--set defaults do not localise these defaults if you use a seperate display script
default_font="Anonymous Pro:bold" --font must be in quotes
default_font_size=11
default_color=0xffffff --white
default_alpha=1 --fully opaque
default_image_width=50
default_image_height=50
--END OF DEFAULTS #######################################################
--START OF WEATHER CODE -- START OF WEATHER CODE -- START OF WEATHER CODE
out({c=0x00BFFF,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=15,txt=now["date"].." "..now["month_short"].." "..now["year"]..": Portare @ "..now["time_24"]})
image({x=20,y=20,h=40,w=40,file=now["weather_icon"]})
-- Temp / FeelsLike & CONDITIONS TEXT
out({c=0x48D1CC,a=1,f="Digital-7",fs=50,x=80,y=60,txt=now["temp"]})
out({c=0x00BFFF,a=1,f="Digital-7",fs=50,x=140,y=60,txt=now["feels_like"]})
out({c=0xA4FFA4,a=1,f="Anonymous Pro:bold",fs=11,x=81,y=72,txt="Temp FV · IC"})
out({c=0x48D1CC,a=1,f="Zekton",fs=18,x=10,y=94,txt=now["conditions_short"]})
-- x horizontal
-- y vertical
-- data titles
-- data output
datay=110 -- y=datay or
datayy=15 -- y=datay+(datayy*1) use 1 or more
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay,txt="fred da v:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=70,y=datay,txt=now["wind_chill"].."°"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=100,y=datay,txt="i da calore:"})
out({c=0xFF8C00,a=1,f="Anonymous Pro:bold",fs=11,x=165,y=datay,txt=now["heat_index"].."°"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*1),txt="Oggi alto: basso:"})
out({c=0xFF8C00,a=1,f="Anonymous Pro:bold",fs=11,x=70,y=datay+(datayy*1),txt=high_temp[1].."°"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=140,y=datay+(datayy*1),txt=low_temp[1].."°"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*2),txt="vento:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=60,y=datay+(datayy*2),txt=now["wind_km"]})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=110,y=datay+(datayy*2),txt=now["wind_nesw"]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=140,y=datay+(datayy*2),txt="@"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=165,y=datay+(datayy*2),txt=now["wind_deg"]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*3),txt="Umidità:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=60,y=datay+(datayy*3),txt=now["humidity"].."%"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=110,y=datay+(datayy*3),txt="PR"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=145,y=datay+(datayy*3),txt=now["dew_point"].."°"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*4),txt="bar:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=60,y=datay+(datayy*4),txt=now["pressure_mb"]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=110,y=datay+(datayy*4),txt="vis:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=145,y=datay+(datayy*4),txt=now["visibility"]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*5),txt="livello delle nubi:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=110,y=datay+(datayy*5),txt=now["ceiling"]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*6),txt="precip:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=60,y=datay+(datayy*6),txt=precipitation[1].."%"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=110,y=datay+(datayy*6),txt="nube:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=150,y=datay+(datayy*6),txt=cloud_cover[1].."%"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*7),txt="uv:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=60,y=datay+(datayy*7),txt=uv_index_num[1]})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=110,y=datay+(datayy*7),txt=uv_index_txt[1]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*8),txt="sole:"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=60,y=datay+(datayy*8),txt=sun_rise_24[1]})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=120,y=datay+(datayy*8),txt=sun_set_24[1]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*9),txt="luna:"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=60,y=datay+(datayy*9),txt=moon_rise_24[1]})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=120,y=datay+(datayy*9),txt=moon_set_24[1]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*10),txt="fase lunare:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=80,y=datay+(datayy*10),txt=moon_phase[1]})
-- 3 hour output
out({c=0x00BFFF,a=1,f="Anonymous Pro:bold",fs=12,x=15,y=280,txt="Prossimi 3 ore"})
-- 1st hour
out({c=0xA4FFA4,x=20,y=295,txt=now["fc_hour1_time_24"]})
image({w=30,h=30,x=20,y=300,file=now["fc_hour1_wicon"]}) -- good
out({x=25,y=345,txt=now["fc_hour1_temp"] .."°"})
-- 2nd hour
out({c=0xA4FFA4,x=80,y=295,txt=now["fc_hour2_time_24"]})
image({w=30,h=30,x=80,y=300,file=now["fc_hour2_wicon"]}) -- good
out({x=85,y=345,txt=now["fc_hour2_temp"] .."°"})
-- 3rd hour
out({c=0xA4FFA4,x=140,y=295,txt=now["fc_hour3_time_24"]})
image({w=30,h=30,x=140,y=300,file=now["fc_hour3_wicon"]}) -- good
out({x=145,y=345,txt=now["fc_hour3_temp"] .."°"})
--start or weather forecast table section
--set start forecast day
start_day=1
--set total forecast days you want to display
number_of_days=10
topy=360
gapy=110 -- topy+(gapy*1)
--set coordinates for top lef corners for each repeat
top_left_x_coordinate[1],top_left_y_coordinate[1]=15,topy
top_left_x_coordinate[2],top_left_y_coordinate[2]=120,topy
top_left_x_coordinate[3],top_left_y_coordinate[3]=15,topy+(gapy*1)
top_left_x_coordinate[4],top_left_y_coordinate[4]=120,topy+(gapy*1)
top_left_x_coordinate[5],top_left_y_coordinate[5]=15,topy+(gapy*2)
top_left_x_coordinate[6],top_left_y_coordinate[6]=120,topy+(gapy*2)
top_left_x_coordinate[7],top_left_y_coordinate[7]=15,topy+(gapy*3)
top_left_x_coordinate[8],top_left_y_coordinate[8]=120,topy+(gapy*3)
top_left_x_coordinate[9],top_left_y_coordinate[9]=15,topy+(gapy*4)
top_left_x_coordinate[10],top_left_y_coordinate[10]=120,topy+(gapy*4)
--########################################################################################
for i=start_day,number_of_days-(start_day-1) do --start of day repeat, do not edit #######
tlx=top_left_x_coordinate[i] --sets top left x position for each repeat ##################
tly=top_left_y_coordinate[i] --sets top left y position for each repeat ##################
--########################################################################################
out({c=0xA4FFA4,a=1,f="Anonymous Pro:bold",fs=11,x=tlx,y=tly,txt=forecast_day_short[i].." "..forecast_date[i].." "..forecast_month_short[i]})
image({x=tlx,y=tly+5,h=30,w=30,file=weather_icon[i]})
out({c=0xFF8C00,a=1,f="Anonymous Pro:bold",fs=11,x=tlx+35,y=tly+15,txt=high_temp[i].."°"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=tlx+35,y=tly+30,txt=low_temp[i].."°"})
-- out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=tlx,y=tly+50,txt=conditions_short[i]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=tlx,y=tly+50,txt="p: "..precipitation[i].."%"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=tlx,y=tly+65,txt="u: "..humidity[i].."%"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=tlx,y=tly+80,txt="s: "..sun_rise_24[i]})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=tlx+50,y=tly+80,txt=sun_set_24[i]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=tlx+3,y=tly+95,txt="l: "..moon_rise_24[i]})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=tlx+50,y=tly+95,txt=moon_set_24[i]})
--########################################################################################
end--of forecast repeat section ##########################################################
--########################################################################################
--END OF WEATHER CODE ----END OF WEATHER CODE ----END OF WEATHER CODE ---
--#######################################################################
end--of weather_display function do not edit this line ##################
--########################################################################! Etiquette | Conky PitStop | VSIDO | Interactive LUA
Weather v9000 | Teo x4 Sites | Arclance | Finnish
Offline
Offline
new here and having a problem with my lua setup.
i was running linux mint 12 and it was fine. I switched to lubuntu.
now lua wont work.
do you remember what version of conky you were running under mint?
Offline
setherd wrote:new here and having a problem with my lua setup.
i was running linux mint 12 and it was fine. I switched to lubuntu.
now lua wont work.do you remember what version of conky you were running under mint?
MrPeachy I noticed that Setherd's error message was something about line: 921 in his v9000.lua.
(This is for learning experience on my part) 
So conky is reporting an error at this point in the script or somewhere above this point?
Peachy's v9000 / Conky PitStop / My DA Page / VSIDO
Make it so....
Offline
mrpeachy wrote:setherd wrote:new here and having a problem with my lua setup.
i was running linux mint 12 and it was fine. I switched to lubuntu.
now lua wont work.do you remember what version of conky you were running under mint?
MrPeachy I noticed that Setherd's error message was something about line: 921 in his v9000.lua.
(This is for learning experience on my part)
So conky is reporting an error at this point in the script or somewhere above this point?
you are correct... now the problem is that 921 in Setherd's is the line in the script that activates the template script
so either something has happened to the template, or something to do with his new distro has caused something to break
when you have to contend with "is it the distro?" "is it the window manager?" "is it conky setting?" "is it a copy paste error? and if so where?" "is it a text encoding error?"
so many possibilities, and when i cant reproduce the error on my computer (which has a different distro WM settings etc) its hard to track down and fix
however if the problem is v9000.lua being unable to find the template
one fix would be to copy everything in the template and paste it into the bottom of v9000.lua
then remove the line in the conkyrc that loads the template script
not the greatest of fixes, but it should work
Offline
so i wonder what is going on...
noticed that the "WINDY" icon throws a small spanner into the translation works!
You wonder? OH OH, I'm in trouble!
I copied the code I put up here, since it worked for you, back in place and it works now as well, plus I edited for the ":00". I fixed the code you mentioned in the v9000.lua script to get today's conditions translating BUT now there is another problem.
It's missing some in the lower part translations.
ARRRRRGGGGGGGGGGGGGGGG!!!!
Notice: I have not even tried shortening the Italian Text, I'll let a native Italian do that.
Maybe it's the GB-v9000 logo!
As for the "Windy" that not the only problem:
08.png - Icy
10.png - Icy
20.png - Fog
23-png - Windy
24-png - Windy
25.png - N/A
43.png - Windy - on a cloud/snow background
44.png - N/A
"Everything" is in ~/Il_Tempo/ and it is designed to run from here.
I simply renamed ~/v9000 to ~/v9000x
re-installed v9000 and changed the directory name to ~/Il_Tempo/ ... even the config file is in there.
I then renamed ~/v9000x back to ~/v9000
~/Il_Tempo/il_tempo.conky
## To use #! in a conky use: ${exec echo '#!'}
## killall conky && conky -c ~/Il_Tempo/il_tempo.conky &
##
## The latest script is a lua only weather script. aka: v9000
## http://crunchbanglinux.org/forums/topic/16100/weather-in-conky/
##
## the file:
## http://dl.dropbox.com/u/19008369/weatheragain9000.lua.tar.gz
##
## mrppeachys LUA Tutorial
## http://crunchbanglinux.org/forums/topic/17246/how-to-using-lua-scripts-in-conky/
##
##
### Begin Window Settings ##################################################
# Create own window instead of using desktop (required in nautilus)
own_window yes
# Use the Xdbe extension? (eliminates flicker)
# It is highly recommended to use own window with this one
# so double buffer won't be so big.
double_buffer yes
own_window_type normal
own_window_transparent yes #no
own_window_hints undecorated,below,skip_taskbar,skip_pager
#own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager
own_window_class Il_Tempo v9000
own_window_title Il_Tempo v9000
### ARGB can be used for real transparency
### NOTE that a composite manager is required for real transparency.
### This option will not work as desired (in most cases) in conjunction with
### 'own_window_type override'
## own_window_argb_visual yes
### When ARGB visuals are enabled, this use this to modify the alpha value
### Use: own_window_type normal
### Use: own_window_transparent no
### Valid range is 0-255, where 0 is 0% opacity, and 255 is 100% opacity.
#own_window_argb_value 150
gap_x 15 ### left &right
gap_y 15 ### up & down
alignment top_left
#################################################### End Window Settings ###
### Font Settings ##########################################################
# Use Xft (anti-aliased font and stuff)
use_xft yes
xftfont Anonymous Pro:size=9
# Alpha of Xft font. Must be a value at or between 1 and 0 ###
xftalpha 0
# Force UTF8? requires XFT ###
override_utf8_locale yes
draw_shades no
default_shade_color black
draw_outline no # amplifies text if yes
default_outline_color black
uppercase no
###################################################### End Font Settings ###
### Color Settings #########################################################
default_shade_color grey
default_outline_color black
default_color DCDCDC #Gainsboro
color0 DAA520 #Goldenrod FFFFF0 #Ivory
color1 778899 #LightSlateGrey
color2 FF8C00 #Darkorange
color3 7FFF00 #Chartreuse
color4 FFA07A #LightSalmon
color5 FFDEAD #NavajoWhite
color6 00BFFF #DeepSkyBlue
color7 00FFFF #Cyan 48D1CC #MediumTurquoise
color8 FFFF00 #Yellow
color9 FF0000 #Red
##################################################### End Color Settings ###
### Borders Section ########################################################
draw_borders no
# Stippled borders?
stippled_borders 0
# border margins
border_inner_margin 10
border_outer_margin 0
# border width
border_width 0
# graph borders
draw_graph_borders no
##################################################### End Borders Secton ###
### Miscellaneous Section ##################################################
# Boolean value, if true, Conky will be forked to background when started.
background no
# Adds spaces around certain objects to stop them from moving other things
# around, this only helps if you are using a mono font
# Options: right, left or none
use_spacer none
# Default and Minimum size is 256 - needs more for single commands that
# "call" a lot of text IE: bash scripts
text_buffer_size 265
# Subtract (file system) buffers from used memory?
no_buffers yes
# change GiB to G and MiB to M
short_units yes
# Like it says, ot pads the decimals on % values
# doesn't seem to work since v1.7.1
pad_percents 2
############################################## End Miscellaneous Section ###
### LUA Settings ###########################################################
## ${lua conky_draw_bg corner_radius x_position y_position width height color alpha}
## Above and After TEXT - requires a composite manager or it blinks.
##
## lua_load ~/Conky/LUA/draw-bg.lua
## TEXT
## ${lua conky_draw_bg 10 0 0 0 0 0x000000 0.4}
##
##
## OR Both above TEXT (No composite manager required - no blinking!)
##
lua_load ~/Il_Tempo/draw-bg.lua
lua_draw_hook_pre draw_bg 10 0 0 0 0 0x000000 0.5
## TEXT
##
####################################################### End LUA Settings ###
# The all important - How often conky refreshes.
# If you have a "Crey" try: 0.2 - smokin' - but watch the CPU useage go UP!
update_interval 900
### LUA and TEMPLATE ###############################
lua_load ~/Il_Tempo/v9000.lua
lua_draw_hook_post weather
########################################################################
## = ITXX0069I_template.lua
lua_load ~/Il_Tempo/ITXX0069I_template.lua
minimum_size 190 880 ## width, height
maximum_width 190 ## width
## = s11template.lua ###################################################
#lua_load ~/Il_Tempo/s11template.lua
#minimum_size 425 530 ## width, height
#maximum_width 425 ## width
TEXT~/Il_Tempo/ITXX0069I_template.lua
--[[
The latest script is a lua only weather script. aka: v9000
http://crunchbanglinux.org/forums/topic/16100/weather-in-conky/
the file:
http://dl.dropbox.com/u/19008369/weatheragain9000.lua.tar.gz
mrppeachys LUA Tutorial
http://crunchbanglinux.org/forums/topic/17246/how-to-using-lua-scripts-in-conky/
]]
_G.weather_script = function()--#### DO NOT EDIT THIS LINE ##############
--these tables hold the coordinates for each repeat do not edit #########
top_left_x_coordinate={}--###############################################
top_left_y_coordinate={}--###############################################
--#######################################################################
--SET DEFAULTS ##########################################################
--set defaults do not localise these defaults if you use a seperate display script
default_font="Anonymous Pro:bold" --font must be in quotes
default_font_size=11
default_color=0xffffff --white
default_alpha=1 --fully opaque
default_image_width=50
default_image_height=50
--END OF DEFAULTS #######################################################
--START OF WEATHER CODE -- START OF WEATHER CODE -- START OF WEATHER CODE
out({c=0x00BFFF,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=15,txt=now["date"].." "..now["month_short"].." "..now["year"]..": Portare @ "..now["time_24"]})
image({x=20,y=20,h=40,w=40,file=now["weather_icon"]})
-- Temp / FeelsLike & CONDITIONS TEXT
out({c=0x48D1CC,a=1,f="Digital-7",fs=50,x=80,y=60,txt=now["temp"]})
out({c=0x00BFFF,a=1,f="Digital-7",fs=50,x=140,y=60,txt=now["feels_like"]})
out({c=0xA4FFA4,a=1,f="Anonymous Pro:bold",fs=11,x=81,y=72,txt="Temp FV · IC"})
out({c=0x48D1CC,a=1,f="Zekton",fs=18,x=10,y=94,txt=now["conditions_short"]})
-- x horizontal
-- y vertical
-- data titles
-- data output
datay=110 -- y=datay or
datayy=15 -- y=datay+(datayy*1) use 1 or more
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay,txt="fred da v:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=70,y=datay,txt=now["wind_chill"].."°"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=100,y=datay,txt="i da calore:"})
out({c=0xFF8C00,a=1,f="Anonymous Pro:bold",fs=11,x=165,y=datay,txt=now["heat_index"].."°"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*1),txt="Oggi alto: basso:"})
out({c=0xFF8C00,a=1,f="Anonymous Pro:bold",fs=11,x=70,y=datay+(datayy*1),txt=high_temp[1].."°"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=140,y=datay+(datayy*1),txt=low_temp[1].."°"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*2),txt="vento:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=60,y=datay+(datayy*2),txt=now["wind_km"]})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=110,y=datay+(datayy*2),txt=now["wind_nesw"]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=140,y=datay+(datayy*2),txt="@"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=165,y=datay+(datayy*2),txt=now["wind_deg"]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*3),txt="Umidità:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=60,y=datay+(datayy*3),txt=now["humidity"].."%"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=110,y=datay+(datayy*3),txt="PR"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=145,y=datay+(datayy*3),txt=now["dew_point"].."°"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*4),txt="bar:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=60,y=datay+(datayy*4),txt=now["pressure_mb"]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=110,y=datay+(datayy*4),txt="vis:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=145,y=datay+(datayy*4),txt=now["visibility"]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*5),txt="livello delle nubi:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=110,y=datay+(datayy*5),txt=now["ceiling"]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*6),txt="precip:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=60,y=datay+(datayy*6),txt=precipitation[1].."%"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=110,y=datay+(datayy*6),txt="nube:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=150,y=datay+(datayy*6),txt=cloud_cover[1].."%"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*7),txt="uv:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=60,y=datay+(datayy*7),txt=uv_index_num[1]})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=110,y=datay+(datayy*7),txt=uv_index_txt[1]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*8),txt="sole:"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=60,y=datay+(datayy*8),txt=sun_rise_24[1]})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=120,y=datay+(datayy*8),txt=sun_set_24[1]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*9),txt="luna:"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=60,y=datay+(datayy*9),txt=moon_rise_24[1]})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=120,y=datay+(datayy*9),txt=moon_set_24[1]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=10,y=datay+(datayy*10),txt="fase lunare:"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=80,y=datay+(datayy*10),txt=moon_phase[1]})
-- 3 hour output
out({c=0x00BFFF,a=1,f="Anonymous Pro:bold",fs=12,x=15,y=280,txt="Prossimi 3 ore"})
-- 1st hour
out({c=0xA4FFA4,x=20,y=295,txt=now["fc_hour1_time_24"]..":00"})
image({w=30,h=30,x=20,y=300,file=now["fc_hour1_wicon"]}) -- good
out({x=25,y=345,txt=now["fc_hour1_temp"] .."°"})
-- 2nd hour
out({c=0xA4FFA4,x=80,y=295,txt=now["fc_hour2_time_24"]..":00"})
image({w=30,h=30,x=80,y=300,file=now["fc_hour2_wicon"]}) -- good
out({x=85,y=345,txt=now["fc_hour2_temp"] .."°"})
-- 3rd hour
out({c=0xA4FFA4,x=140,y=295,txt=now["fc_hour3_time_24"]..":00"})
image({w=30,h=30,x=140,y=300,file=now["fc_hour3_wicon"]}) -- good
out({x=145,y=345,txt=now["fc_hour3_temp"] .."°"})
--start or weather forecast table section
--set start forecast day
start_day=1
--set total forecast days you want to display
number_of_days=10
topy=360
gapy=110 -- topy+(gapy*1)
--set coordinates for top lef corners for each repeat
top_left_x_coordinate[1],top_left_y_coordinate[1]=15,topy
top_left_x_coordinate[2],top_left_y_coordinate[2]=120,topy
top_left_x_coordinate[3],top_left_y_coordinate[3]=15,topy+(gapy*1)
top_left_x_coordinate[4],top_left_y_coordinate[4]=120,topy+(gapy*1)
top_left_x_coordinate[5],top_left_y_coordinate[5]=15,topy+(gapy*2)
top_left_x_coordinate[6],top_left_y_coordinate[6]=120,topy+(gapy*2)
top_left_x_coordinate[7],top_left_y_coordinate[7]=15,topy+(gapy*3)
top_left_x_coordinate[8],top_left_y_coordinate[8]=120,topy+(gapy*3)
top_left_x_coordinate[9],top_left_y_coordinate[9]=15,topy+(gapy*4)
top_left_x_coordinate[10],top_left_y_coordinate[10]=120,topy+(gapy*4)
--########################################################################################
for i=start_day,number_of_days-(start_day-1) do --start of day repeat, do not edit #######
tlx=top_left_x_coordinate[i] --sets top left x position for each repeat ##################
tly=top_left_y_coordinate[i] --sets top left y position for each repeat ##################
--########################################################################################
out({c=0xA4FFA4,a=1,f="Anonymous Pro:bold",fs=11,x=tlx,y=tly,txt=forecast_day_short[i].." "..forecast_date[i].." "..forecast_month_short[i]})
image({x=tlx,y=tly+5,h=30,w=30,file=weather_icon[i]})
out({c=0xFF8C00,a=1,f="Anonymous Pro:bold",fs=11,x=tlx+35,y=tly+15,txt=high_temp[i].."°"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=tlx+35,y=tly+30,txt=low_temp[i].."°"})
-- out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=tlx,y=tly+50,txt=conditions_short[i]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=tlx,y=tly+50,txt="p: "..precipitation[i].."%"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=tlx,y=tly+65,txt="u: "..humidity[i].."%"})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=tlx,y=tly+80,txt="s: "..sun_rise_24[i]})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=tlx+50,y=tly+80,txt=sun_set_24[i]})
out({c=0xFAFAEC,a=1,f="Anonymous Pro:bold",fs=11,x=tlx+3,y=tly+95,txt="l: "..moon_rise_24[i]})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=11,x=tlx+50,y=tly+95,txt=moon_set_24[i]})
--########################################################################################
end--of forecast repeat section ##########################################################
--########################################################################################
--END OF WEATHER CODE ----END OF WEATHER CODE ----END OF WEATHER CODE ---
--#######################################################################
end--of weather_display function do not edit this line ##################
--#######################################################################~/Il_Tempo/s11template.lua
--[[
The latest script is a lua only weather script. aka: v9000
http://crunchbanglinux.org/forums/topic/16100/weather-in-conky/
the file:
http://dl.dropbox.com/u/19008369/v9000.tar.gz
mrppeachys LUA Tutorial
http://crunchbanglinux.org/forums/topic/17246/how-to-using-lua-scripts-in-conky/
]]
_G.weather_script = function()--#### DO NOT EDIT THIS LINE ##############
--these tables hold the coordinates for each repeat do not edit #########
top_left_x_coordinate={}--###############################################
top_left_y_coordinate={}--###############################################
--#######################################################################
--SET DEFAULTS ##########################################################
--set defaults do not localise these defaults if you use a seperate display script
default_font="Anonymous Pro:bold"--font must be in quotes
default_font_size=11
default_color=0xffffff--white
default_alpha=1--fully opaque
default_image_width=50
default_image_height=50
--END OF DEFAULTS #######################################################
--START OF WEATHER CODE -- START OF WEATHER CODE -- START OF WEATHER CODE
out({c=0x00BFFF,a=1,x=10,y=15,txt=now["date"].." "..now["month_short"].." "..now["year"]..": Portare @ "..now["time_24"]})
image({x=20,y=20,h=40,w=40,file=now["weather_icon"]})
-- Temp / FeelsLike & CONDITIONS TEXT
out({c=0x48D1CC,a=1,f="Digital-7",fs=50,x=80,y=60,txt=now["temp"]})
out({c=0x00BFFF,a=1,f="Digital-7",fs=50,x=140,y=60,txt=now["feels_like"]})
out({c=0xA4FFA4,a=1,x=81,y=72,txt="Temp fv · ic"}) -- temperatura | Wind Chill = freddo da vento = fv | Heat Index = indice di calore = ic
out({c=0x48D1CC,a=1,f="Zekton",fs=18,x=10,y=94,txt=now["conditions_short"]})
-- data titles
-- data output
datay=110 -- y=datay or
datayy=15 -- y=datay+(datayy*1) use 1 or more
out({c=0xFAFAEC,a=1,x=10,y=datay,txt="Fred da v:"}) -- Wind Chill = freddo da vento
out({c=0x48D1CC,a=1,x=70,y=datay,txt=now["wind_chill"].."°"})
out({c=0xFAFAEC,a=1,x=100,y=datay,txt="I da calore:"}) -- Heat Index = indice di calore
out({c=0xFF8C00,a=1,x=165,y=datay,txt=now["heat_index"].."°"})
out({c=0xFAFAEC,a=1,x=10,y=datay+(datayy*1),txt="Oggi Hi·Lo:"}) -- Today High·Low
out({c=0xFF8C00,a=1,x=100,y=datay+(datayy*1),txt=high_temp[1].."°"})
out({c=0x48D1CC,a=1,x=140,y=datay+(datayy*1),txt=low_temp[1].."°"})
out({c=0xFAFAEC,a=1,x=10,y=datay+(datayy*2),txt="Vento:"}) -- Wind
out({c=0x48D1CC,a=1,x=60,y=datay+(datayy*2),txt=now["wind_km"]})
out({c=0x48D1CC,a=1,x=110,y=datay+(datayy*2),txt=now["wind_nesw"]}) --does not translate with neswtext={
out({c=0xFAFAEC,a=1,x=140,y=datay+(datayy*2),txt="@"})
out({c=0x48D1CC,a=1,x=165,y=datay+(datayy*2),txt=now["wind_deg"]})
out({c=0xFAFAEC,a=1,x=10,y=datay+(datayy*3),txt="Umi:"}) --Humidity - Hum: Umidità
out({c=0x48D1CC,a=1,x=60,y=datay+(datayy*3),txt=now["humidity"].."%"})
out({c=0xFAFAEC,a=1,x=110,y=datay+(datayy*3),txt="PR :"}) -- Dew Point . DP: = punto di rugiada
out({c=0x48D1CC,a=1,x=145,y=datay+(datayy*3),txt=now["dew_point"].."°"})
out({c=0xFAFAEC,a=1,x=10,y=datay+(datayy*4),txt="Bar:"}) -- barometer = il barometro
out({c=0x48D1CC,a=1,x=60,y=datay+(datayy*4),txt=now["pressure_mb"]})
out({c=0xFAFAEC,a=1,x=110,y=datay+(datayy*4),txt="Vis:"}) -- visibility = visibilità
out({c=0x48D1CC,a=1,x=145,y=datay+(datayy*4),txt=now["visibility"]})
out({c=0xFAFAEC,a=1,x=10,y=datay+(datayy*5),txt="Ceil:"}) -- ceiling = altitudine massima - (Meteor) livello delle nubi
out({c=0x48D1CC,a=1,x=60,y=datay+(datayy*5),txt=now["ceiling"]})
out({c=0xFAFAEC,a=1,x=10,y=datay+(datayy*6),txt="Precip:"}) -- la precipitazione
out({c=0x48D1CC,a=1,x=60,y=datay+(datayy*6),txt=precipitation[1].."%"})
out({c=0xFAFAEC,a=1,x=110,y=datay+(datayy*6),txt="nuvola:"}) -- cloud = la nuvola
out({c=0x48D1CC,a=1,x=155,y=datay+(datayy*6),txt=cloud_cover[1].."%"})
out({c=0xFAFAEC,a=1,x=10,y=datay+(datayy*7),txt="IUV:"}) -- Ultraviolet Index = Indice UV
out({c=0xA4FFA4,a=1,x=60,y=datay+(datayy*7),txt=uv_index_num[1]})
out({c=0xA4FFA4,a=1,x=110,y=datay+(datayy*7),txt=uv_index_txt[1]})
out({c=0xFAFAEC,a=1,x=10,y=datay+(datayy*8),txt="Sole:"}) -- sun = il sole
out({c=0xFAFAEC,a=1,x=60,y=datay+(datayy*8),txt=sun_rise_24[1]})
out({c=0x48D1CC,a=1,x=120,y=datay+(datayy*8),txt=sun_set_24[1]})
out({c=0xFAFAEC,a=1,x=10,y=datay+(datayy*9),txt="Luna:"}) -- moon = la luna
out({c=0xFAFAEC,a=1,x=60,y=datay+(datayy*9),txt=moon_rise_24[1]})
out({c=0x48D1CC,a=1,x=120,y=datay+(datayy*9),txt=moon_set_24[1]})
out({c=0xFAFAEC,a=1,x=10,y=datay+(datayy*10),txt="Fase:"}) -- moon phases = fase lunare
out({c=0x48D1CC,a=1,x=55,y=datay+(datayy*10),txt=moon_phase[1]})
-- line
image({x=205,y=5,w=1,h=260,file="/home/sector11/Conky/images/cyan-1.png"})
-- 3 hour output
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=12,x=220,y=15,txt="Prossimi"})
out({c=0x48D1CC,a=1,f="Anonymous Pro:bold",fs=12,x=220,y=30,txt=" 3 ore"})
-- 1st hour
out({c=0xA4FFA4,x=220,y=50,txt=now["fc_hour1_time_24"]..":00"})
image({w=30,h=30,x=223,y=55,file=now["fc_hour1_wicon"]}) -- image({w=30,h=30,x=223,y=55,file="/home/sector11/Conky/images/red-1.png"})
out({x=228,y=100,txt=now["fc_hour1_temp"] .."°"})
-- 2nd hour
out({c=0xA4FFA4,x=220,y=datay+(datayy*1),txt=now["fc_hour2_time_24"]..":00"})
image({w=30,h=30,x=223,y=130,file=now["fc_hour2_wicon"]}) -- image({w=30,h=30,x=223,y=130,file="/home/sector11/Conky/images/red-1.png"})
out({x=228,y=180,txt=now["fc_hour2_temp"] .."°"})
-- 3rd hour
out({c=0xA4FFA4,x=220,y=210,txt=now["fc_hour3_time_24"]..":00"})
image({w=30,h=30,x=223,y=215,file=now["fc_hour3_wicon"]}) -- image({w=30,h=30,x=223,y=215,file="/home/sector11/Conky/images/red-1.png"})
out({x=228,y=datay+(datayy*10),txt=now["fc_hour3_temp"] .."°"})
-- line
image({x=275,y=5,w=1,h=260,file="/home/sector11/Conky/images/cyan-1.png"})
--start or weather forecast table section
--set start forecast day
start_day=1
--set total forecast days you want to display
number_of_days=8
topy=15
topyy=135 -- topy+(topyy*1)
topx=285
topxx=137.5
--set coordinates for top lef corners for each repeat
top_left_x_coordinate[1],top_left_y_coordinate[1] =topx ,topy
top_left_x_coordinate[2],top_left_y_coordinate[2] =topx ,150
top_left_x_coordinate[3],top_left_y_coordinate[3] =10 ,290
top_left_x_coordinate[4],top_left_y_coordinate[4] =10+(topxx*1) ,290
top_left_x_coordinate[5],top_left_y_coordinate[5] =10+(topxx*2) ,290
top_left_x_coordinate[6],top_left_y_coordinate[6] =10 ,topy+(topyy*3)
top_left_x_coordinate[7],top_left_y_coordinate[7] =10+(topxx*1) ,topy+(topyy*3)
top_left_x_coordinate[8],top_left_y_coordinate[8] =10+(topxx*2) ,topy+(topyy*3)
--########################################################################################
for i=start_day,number_of_days-(start_day-1) do --start of day repeat, do not edit #######
tlx=top_left_x_coordinate[i] --sets top left x position for each repeat ##################
tly=top_left_y_coordinate[i] --sets top left y position for each repeat ##################
--########################################################################################
out({c=0xA4FFA4,a=1,x=tlx,y=tly,txt=forecast_day_short[i].." "..forecast_date[i].." "..forecast_month_short[i]})
image({x=tlx,y=tly+5,h=30,w=30,file=weather_icon[i]})
out({c=0xFF8C00,a=1,x=tlx+35,y=tly+15,txt=high_temp[i].."°"})
out({c=0x48D1CC,a=1,x=tlx+35,y=tly+30,txt=low_temp[i].."°"})
out({c=0x48D1CC,a=1,x=tlx,y=tly+50,txt=conditions_short[i]})
out({c=0xFAFAEC,a=1,x=tlx,y=tly+65,txt="P: "..precipitation[i].."%"})
out({c=0xA4FFA4,a=1,x=tlx+50,y=tly+65,txt="IUV: "..uv_index_num[i]})
out({c=0xFAFAEC,a=1,x=tlx,y=tly+80,txt="H: "..humidity[i].."%"})
out({c=0xA4FFA4,a=1,x=tlx+50,y=tly+80,txt=uv_index_txt[1]})
out({c=0xFAFAEC,a=1,x=tlx,y=tly+95,txt="S: "..sun_rise_24[i]})
out({c=0x48D1CC,a=1,x=tlx+73,y=tly+95,txt=sun_set_24[i]})
out({c=0xFAFAEC,a=1,x=tlx,y=tly+110,txt="L: "..moon_rise_24[i]})
out({c=0x48D1CC,a=1,x=tlx+73,y=tly+110,txt=moon_set_24[i]})
--########################################################################################
end--of forecast repeat section ##########################################################
--########################################################################################
--END OF WEATHER CODE ----END OF WEATHER CODE ----END OF WEATHER CODE ---
--#######################################################################
end--of weather_display function do not edit this line ##################
--#######################################################################~/Il_Tempo/.ITXX0069I_config.lua
--SETTINGS AND PREFERENCES--SETTINGS AND PREFERENCES--SETTINGS AND PREFERENCES
function weather_settings()--#### DO NOT EDIT THIS LINE #################
--#######################################################################
--[[set update interval. update interval is based on conky cycles
if your conkyrc has an update_interval of 1, ie updates every second
then if you enter 60 below, the script will update every 60 seconds
however, if your conkyrc update_interval is 10, then by setting 60 below,
v9000 will update every 600 seconds (10 minutes)]]
local update_interval=1800 --avoid an interval of 1
--get web address by going to the intellicast site and entering your location in the box
--click on "Extended Forecast" to get the necessary address
local web="http://www.intellicast.com/Local/Forecast.aspx?unit=C&location=ITXX0069"--insert unit=C& after? for C
--set location of weather images (replace "sector11" with your own username)
local weathericons="/home/sector11/Il_Tempo/weathericons/"
--short conditions setup
--this section allows you to set your own shorter terms to replace the terms foud in conditions
--to use for current: now["conditions_short"], now["conditions_short_caps"], now["conditions_short_lc"]
--to use for forecast: conditions_short[n], conditions_short_caps[n], conditions_short_lc[n]
--ALSO USE THIS TABLE TO ENTER CONDITIONS TRANSLATIONS
con_short={--start of table, put entries below in form eg: ["Thunderstorm"]="T.Strm",
["AM Clouds/PM Sun"]="Nuvole Mattutine/Sole Pomeridiano",
["AM Rain/Snow Showers"]="Pioggierella Mattutina",
["AM Showers"]="Rovesci Mattutini",
["AM Snow Showers/Wind"]="Nevicate Mattutine/Vento",
["Broken Clouds"]="Nubi Sparse",
["Few Clouds"]="Poche Nuvole",
["Few Snow Showers"]="Poche Nevicate",
["Isolated Thunderstorms"]="Temporali Isolati",
["Light Rain Late"]="Pioggerella Serale",
["Light Rain/Wind"]="Pioggerella Serale/Vento",
["Moderate Fog"]="Leggera Nebbia",
["Mostly Clear"]="Poche Nuvole",
["Mostly Cloudy"]="Prevalentemente Nuvoloso",
["Mostly Sunny"]="Prevalentemente Soleggiato",
["Partly Cloudy"]="Parzialmente Nuvoloso",
["Rain/Snow Showers"]="Pioggia/Nevicate",
["Scattered Thunderstorms"]="Temporali Sparsi",
["Scattered Clouds"]="Nubi Sparse",
["Scattered Showers"]="Acquazzoni Sparsi",
["Snow Showers Late"]="Nevicate Sparse",
["Snow Showers"]="Nevicate",
["Clear"]="Limpido",
["Cloudy"]="Nuvoloso",
["Haze"]="Foschia",
["Overcast"]="Coperto",
["Showers"]="Rovesci",
["Sunny"]="Soleggiato",
["Thunderstorm"]="Temporali",
["Wind Early"]="Vento Mattutino",
["Wind"]="Ventoso",
}--this bracket closes the tablee
--the script is capable of converting between several unit types
--set how many decimal places you want the conversions to show
local decimal_places=1
--some weather data options need to come with their own units attached as they can be NA on occasion
--set here what you want to have for units, or set "" for nothing
--include spaces, if desired, for formatting purposes.
--NOTE ALSO EDIT THESE SETTINGS FOR TRANSLATION PURPOSES
local visibility_unit=" m" -- migli per ora
local wind_mph_unit=" m"
local wind_km_unit=" k"
local wind_kts_unit=" k"
local ceiling_unit=" f"
local wind_degrees_unit="°"
--do you want the script to use translation tables?
--set 1 if you want to translate, 0 if not.
--the translation tables are located below
local translate=1
--set alerts on or off, set to 0 so that the script does not check for alerts
--set 1 to check for alerts
local alert_check=0
--#######################################################################
--TRANSLATION TABLES, activate by setting translate=1 above
--use con_short table above to translate weather conditions
--edit units settings above to complete translation
--translate NESW text
neswtext={
S="S",
SSW="SSO",
SW="SO",
WSW="OSO",
W="O",
WNW="ONO",
NW="NO",
NNW="NNO",
N="N",
NNE="NNE",
NE="NE",
ENE="ENE",
E="E",
ESE="ESE",
SE="SE",
SSE="SSE",
}--end of N E S W text table
--translate time suffix
tsuffix={
AM="am",
PM="pm",
}--end of time suffix table
--enter translations for uv index text
uvindextext={
["Low"]="basso",
["Moderate"]="Moderato",
["High"]="Alto",
["Very High"]="Molto alta",--format is different because of the space in the text
["Extreme"]="Estrema",
}--end of uv text table
--enter translations for moonpahse
moonphases={
["New"]="Luna Nuova",
["Full"]="Luna Piena",
["First Quarter"]="Primo Quarto",
["Last Quarter"]="Ultimo Quarto",
["Waning Gibbous"]="Gibbosa Calante",
["Waning Crescent"]="Luna Crescente",
["Waxing Crescent"]="Gibbosa Crescente",
["Waxing Gibbous"]="Gibbosa Crescente",
}--end of moon phase table
--enter translations for FULL day names
daynames={
Monday="lunedì",
Tuesday="martedì",
Wednesday="mercoledì",
Thursday="giovedì",
Friday="venerdì",
Saturday="sabato",
Sunday="domenica",
}--end day names table
--enter translations for SHORT day names
dayshort={
Monday="lun",
Tuesday="mar",
Wednesday="mer",
Thursday="gio",
Friday="ven",
Saturday="sab",
Sunday="dom"
}--end short day names table
--enter translation for FULL month names
monthnames={
January="gennaio",
February="febbraio",
March="marzo",
April="aprile",
May="maggio",
June="giugno",
July="luglio",
August="agosto",
September="settembre",
October="ottobre",
November="novembre",
December="dicembre"
}--end of month name translations
--enter translations for SHORT month names
monthshort={
January="gen",
February="feb",
March="mar",
April="mar",
May="mag",
June="gui",
July="lug",
August="ago",
September="set",
October="ott",
November="nov",
December="dic"
}--end of short month name translations
--enter some additional translations
additional={
NA="NA",
Unl="Unl"--for ceiling data option
}--end of additional translations
--END OF TRANSLATION TABLES
--#######################################################################
--NOTE if you make changes to these settings, they will only take effect at the next weather update
--or after killall conky and restart
--#######################################################################
if translate==1 then
return {update_interval,web,weathericons,con_short,decimal_places,visibility_unit,wind_mph_unit,wind_km_unit,wind_kts_unit,ceiling_unit,wind_degrees_unit,translate,alert_check,neswtext,tsuffix,uvindextext,moonphases,daynames,dayshort,monthnames,monthshort,additional}
else
return {update_interval,web,weathericons,con_short,decimal_places,visibility_unit,wind_mph_unit,wind_km_unit,wind_kts_unit,ceiling_unit,wind_degrees_unit,translate,alert_check}
end
end--OF SETTINGS AND PREFERENCES ########################################
--#######################################################################Last edited by Sector11 (2012-03-06 18:00:06)
#! Etiquette | Conky PitStop | VSIDO | Interactive LUA
Weather v9000 | Teo x4 Sites | Arclance | Finnish
Offline
new here and having a problem with my lua setup.
i was running linux mint 12 and it was fine. I switched to lubuntu.
now lua wont work.
Could you post:
the conky file
the LUA script &
the template if you use one
#! Etiquette | Conky PitStop | VSIDO | Interactive LUA
Weather v9000 | Teo x4 Sites | Arclance | Finnish
Offline
I copied the code I put up here, since it worked for you, back in place and it works now as well, plus I edited for the ":00". I fixed the code you mentioned in the v9000.lua script to get today's conditions translating BUT now there is another problem.
It's missing some in the lower part translations.
ARRRRRGGGGGGGGGGGGGGGG!!!!
i think i CAN explain that one
you dont have a translation in the config for PM Showers or Few Showers
you think perhaps the goal of international weather translation was a little on the optimistic side? 
Offline
@mrpeachy
do u have a solution for the 'windy thunderstorms'-problem?
regards, alex
“If you wish to make an apple pie from scratch, you must first invent the universe.” Carl Sagan
Offline
Sector11 wrote:I copied the code I put up here, since it worked for you, back in place and it works now as well, plus I edited for the ":00". I fixed the code you mentioned in the v9000.lua script to get today's conditions translating BUT now there is another problem.
It's missing some in the lower part translations.
ARRRRRGGGGGGGGGGGGGGGG!!!!i think i CAN explain that one
you dont have a translation in the config for PM Showers or Few Showers
you think perhaps the goal of international weather translation was a little on the optimistic side?
I thought I answered this ... ????
I think it's important that people be able to translate to another language, and since an Italian asked for help I asked Deegan for help and got started. Beyond that I think it will be up to the individual users but a few wxamples are a good thing to get things going.
I have the two added now and it works:
["PM Showers"]="Rovesci Pomeridiano",
["Few Showers"]="Poche Rovesci",... may not be absolutely correct BUT it's enough for an Italian to correct.
I also sis not shorten and of the text so there will be problems there, a native speaking Italian will need to do that. Also in the narrow vertical one, I removed the conditions text, the images say enough and they change from day to day.
For mine - in English, I see some repeated information for NOW and [1] so I am going to clean it up.
My wife asked me, "If this is today what is this "Tue" part? And that was when I noticed the double stuff.
Yes, I know, what's now and what is from what they forcasted for today, but I have a new idea for a template. IntelliCast is really a 9 day forecast even though there is "foretasted" info for today.
Time to play.
#! Etiquette | Conky PitStop | VSIDO | Interactive LUA
Weather v9000 | Teo x4 Sites | Arclance | Finnish
Offline
@mrpeachy
do u have a solution for the 'windy thunderstorms'-problem?
regards, alex
Windy Thunderstorms? As in text output or an image?
#! Etiquette | Conky PitStop | VSIDO | Interactive LUA
Weather v9000 | Teo x4 Sites | Arclance | Finnish
Offline
mrpeachy talked about this phanomen some days ago. he said that he had the Condition Thunderstorms/Wind !
extra extra windy?! or wind XXL 
for example:
["Partly Cloudy"]="teilweise bewölkt",
["Partly Cloudy/Wind"]="teilweise wolkig/windig",
its possible that BOTH weatherconditions are the same! it's just a more detailled information!
Last edited by lionhead (2012-03-06 20:59:39)
“If you wish to make an apple pie from scratch, you must first invent the universe.” Carl Sagan
Offline
setherd wrote:new here and having a problem with my lua setup.
i was running linux mint 12 and it was fine. I switched to lubuntu.
now lua wont work.Could you post:
the conky file
the LUA script &
the template if you use one
conky
####
## continuing the work strted ny grae
##
####
## begin setup config
# general startup settings
background yes
update_interval 2.0
text_buffer_size 640
total_run_times 0
## screen setup:
# placement, sizing, font and color info
alignment top_right
gap_x 34
gap_y 10
minimum_size 220 800
maximum_width 220
own_window yes
own_window_hints below,skip_pager,skip_taskbar,undecorated,sticky
# transparency:
own_window_argb_visual yes
own_window_argb_value 64
# font defaults:
use_xft yes
xftfont UbuntuSans:size=8
xftalpha 0.1
override_utf8_locale yes
## NOTE: Other fonts can be called up during the TEXT formatting
# these fonts are found through the normal path, or ~/.fonts
# OpenLogos
## images, buffering, shading
imlib_cache_size 0
double_buffer yes
draw_shades yes
default_shade_color 080808
## misc text formatting
short_units yes
pad_percents 0
border_inner_margin 4
uppercase no
use_spacer right
## outlines and borders
draw_outline no
draw_borders no
draw_graph_borders yes
border_width 1
## stdout/console printing
out_to_ncurses no
out_to_console no
## process settings
top_name_width 12
no_buffers yes
## Colors
color0 White
color1 Gray
color2 Red
color3 Salmon
color4 Yellow
color5 LightSeaGreen
color6 Green
color7 DarkGreen
color8 DarkCyan
color9 Blue
#### end config
#### Lua scripting
## call external lua scripts here
# MrPeachy v9000 weather scripts
lua_load ~/v9000/v9000.lua
lua_draw_hook_pre weather
#lua_load ~/v9000/weather_script.lua
#### Begin display information
## everything below 'TEXT' is drawn on screen
TEXT
####
# Logo and time
####
${voffset 8}${font OpenLogos:size=42}${color7}u${font UbuntuTitleBold:18} ${voffset -48}${pre_exec cat /etc/*release | grep 'RELEASE' | awk -F'=' '{print $2}'}${font}${goto 115}${voffset -4}${font RadioSpace:size=20}${color6}${if_match ${time %l}<=9}${alignc 7}${time %l:%M%p}${else}${if_match ${time %l}>=10}${alignc -1}${time %l:%M%p}${endif}${endif}${font}
${goto 115}${font StyleBats:size=10}${color4}q${font DroidSans:size=8}${color1}${offset 5}Uptime: ${font DroidSans:size=8}${uptime_short}${font}
####
# Calendar
####
${font}
${voffset 2}${color6}${font}${alignc}CALENDAR${font}
${color7}${voffset -8}${hr 1}${font}
${voffset 4}${font Ubuntu:size=8}${color6}${alignc 60}${time %A}${font}
${voffset 0}${font Ubuntu:bold:size=18}${if_match ${time %e}<=9}${color6}${alignc 65}${time %e}${font}${else}${if_match ${time %e}>=10}${color4}${alignc 60}${time %e}${endif}${endif}${font}
${voffset -2}${font Ubuntu:size=7.55}${color6}${alignc 60}${time %B}${font}
${voffset 0}${font Ubuntu:size=7.6}${color6}${alignc 60}${time %Y}${font}
${voffset -73}${font CutOutsFor3DFX:size=62}${color5}${alignc 96}2${font}
${voffset -65}${offset 85}${font DroidSans:size=8}${color6}${execpi 60 VinDSL_Cal_9=`date +%-d`; cal -h | sed -e 's/\r//g' -e 's/^/ /g' -e '1d' -e 's/\<'"$VinDSL_Cal_9"'\>/${color4}&${color6}/'}
####
# CPU Load
####
${voffset -2}${goto 90}${color6}${cpugraph cpu1 20,100}${font}
${voffset -22}${font StyleBats:size=8}${color1}k${font DroidSansFallback:size=8}${color6}${offset 4}CPU${offset 6}${color3}${font DroidSans:size=8}${cpu cpu1}%
CPU TEMP:${GOTO 70}${execi 10 sensors | grep -n 'temp1' | sed -n 2p | awk -F'+' '{print $2}' | awk -F'.' '{print $1}'} ºC
${GOTO 120}HDD TEMP: ${hddtemp /dev/sda}ºC
####
# TOP processes
####
${color6}${voffset 2}${alignc}TOP${font}
${color7}${voffset -8}${hr 1}${font}
${color8}${top_mem pid 1}${goto 60}${top_mem name 1}${alignr}${top_mem mem 1}%${font}
${color8}${top_mem pid 2}${goto 60}${top_mem name 2}${alignr}${top_mem mem 2}%${font}
${color8}${top_mem pid 3}${goto 60}${top_mem name 3}${alignr}${top_mem mem 3}%${font}
${color8}${top_mem pid 4}${goto 60}${top_mem name 4}${alignr}${top_mem mem 4}%${font}
${color8}${top_mem pid 5}${goto 60}${top_mem name 5}${alignr}${top_mem mem 5}%
####
# Network
####
${color6}${font}${alignc}NETWORK${font}
${color7}${voffset -8}${hr 1}${font}
${color6}Net ID: ${wireless_essid eth1}${alignr}Signal Strength: ${wireless_link_qual_perc eth1}%${font}
${color5}Down: ${downspeed eth1}${color2}${alignr}${color3}Up:${upspeed eth1} ${font}
${color6}${downspeedgraph eth1 16,64}${alignr}${color4}${upspeedgraph eth1 16,64}
${voffset 0}${font PizzaDudeBullets:size=9.5}${color6}a${font DroidSans:size=8.65}${color3}${offset 0}Public${offset 0}IP${goto 100}${font DroidSansFallback:size=8.5}WAN${alignr}${font DroidSans:size=8}${execi 1800 wget -q -O - checkip.dyndns.org | sed -e 's/[^[:digit:]\|.]//g'}
${font PizzaDudeBullets:size=9.5}${color6}a${font DroidSans:size=8.65}${color3} Local IP: ${addr eth1}
# Weather
####
${font}
${color6}${voffset -2}${font}${alignc}WEATHER${font}
${color7}${voffset -2}${hr 1}${font}the forums doesn;t like my lua scripts so I am using pastebin.
weather_script lua
http://pastebin.com/wPEmPgvM
v9000 lua
http://pastebin.com/56BC4MqD
I somehow think lua is broken or I am missing some dependency but I don't know what
thanks,
Seth
Offline
mrpeachy talked about this phanomen some days ago. he said that he had the Condition Thunderstorms/Wind !
extra extra windy?! or wind XXL
for example:
["Partly Cloudy"]="teilweise bewölkt",
["Partly Cloudy/Wind"]="teilweise wolkig/windig",its possible that BOTH weatherconditions are the same! it's just a more detailled information!
I like the "Wind XXL" it's funny and very doable if "Strong Wind" or "Very Strong Wind" shows up.
But I regress. I think
["Partly Cloudy"]="teilweise bewölkt",
["Partly Cloudy/Wind"]="teilweise wolkig/windig",
'are' different "Partly Cloudy" with no wind at ground level is just that "Partly Cloudy/Wind" means you feel the wind. (just a guess)
#! Etiquette | Conky PitStop | VSIDO | Interactive LUA
Weather v9000 | Teo x4 Sites | Arclance | Finnish
Offline
I somehow think lua is broken or I am missing some dependency but I don't know what
thanks,
Seth
From what I remember about your output the conky was fine, lets see if it runs here.
@ mrprachy - does v9000 rely on any specific files to be loaded other than having the right conky?
#! Etiquette | Conky PitStop | VSIDO | Interactive LUA
Weather v9000 | Teo x4 Sites | Arclance | Finnish
Offline
Copyright © 2012 CrunchBang Linux.
Proudly powered by Debian. Hosted by Linode.
Debian is a registered trademark of Software in the Public Interest, Inc.