You are not logged in.

#1 2011-02-01 10:42:47

Spot
Member
From: The Heart of Europe
Registered: 2008-12-20
Posts: 68

conky-lua isn't working...

My lua script isn't working...

The simple Lua-File for getting started:

function rahmen()

local boxes_settings={
{},
}

end

My conkyrc

alignment top_middle
short_units
use_xft yes
xftfont Monospace:size=9
gap_y 5
xftalpha 0.8
update_interval 10
double_buffer yes
own_window_transparent yes
own_window_argb_visual yes
lua_load ~/rahmen.lua
lua_draw_hook_post conky_rahmen

TEXT
.....

Conky is compiled correctly:

X11:
  * Xdamage extension
  * XDBE (double buffer extension)
  * Xft
  * ARGB visual

Music detection:
  * MPD
  * MOC

General:
  * math
  * hddtemp
  * portmon
  * Curl
  * RSS
  * wireless
  * support for IBM/Lenovo notebooks
  * config-output
  * Imlib2
  * apcupsd
  * iostats
  * ncurses
  * Lua

  Lua bindings:
   * Cairo
   * Imlib2

Whats wrong with my configs ?

Last edited by Spot (2011-02-01 12:10:58)

Offline

#2 2011-02-01 21:59:24

ryuslash
Member
Registered: 2010-10-11
Posts: 58
Website

Re: conky-lua isn't working...

Firstly you seem to have the names the wrong way around, conky_rahmen should be the function name and rahmen the value for lua_draw_hook_post

And I'll admit I have no experience with lua in conky (only tried it out for a couple of minutes the other day, my pc went crazy so I stopped), but I don't see boxes_settings doing anything...

Offline

#3 2011-02-02 16:32:07

renato_garcia
Member
From: Brazil
Registered: 2009-08-14
Posts: 24

Re: conky-lua isn't working...

In the file rahmen.lua, the function rahmen() would be conky_rahmen().
In the "lua_draw_hook_post conky_rahmen", the "conky_" part is optional. If it is not there, the conky will concatenate this prefix in the function name.

Offline

#4 2011-02-02 19:18:55

Spot
Member
From: The Heart of Europe
Registered: 2008-12-20
Posts: 68

Re: conky-lua isn't working...

@ryuslash

The lua-script should draw a backround with 50% opacity on the conky window.

New extended lua script:

function conky_rahmen()

local boxes_settings={

corners={ {"circle",1}
           {"circle",1}
           {"circle",40}
           {"circle",40}},
         border=3
}

end

My source: http://u-scripts.blogspot.com/2011/01/b … et_27.html

I tried all combinations of conky_rahmen/rahmen() and lua_draw_hook_post (conky_)rahmen" but nothing works...

Interessting, conky now shows a error message regarding the lua script:

Conky: llua_do_call: function conky_rahmen execution failed: attempt to call a nil value

Last edited by Spot (2011-02-02 19:21:53)

Offline

#5 2011-02-04 20:15:54

Spot
Member
From: The Heart of Europe
Registered: 2008-12-20
Posts: 68

Re: conky-lua isn't working...

Does anyone has an ideo how to solve this problem ?
Is my lua script wrong ? Syntax sux ?

Offline

#6 2011-02-08 15:14:28

Spot
Member
From: The Heart of Europe
Registered: 2008-12-20
Posts: 68

Re: conky-lua isn't working...

The lua-script should only draw a little border around the conky-line.

2010-12-31-141004_1680462o.png

Should I use another code ?
Could the hidden lua file be a problem ?

Offline

Board footer

Powered by FluxBB