Page 2038 of 2348 FirstFirst ... 1038153819381988202820362037203820392040204820882138 ... LastLast
Results 20,371 to 20,380 of 23480

Thread: Post your .conkyrc files w/ screenshots

  1. #20371

    Re: Post your .conkyrc files w/ screenshots

    Hey everyone I followed the vindsl configuration, and pretty much got everything set up except the freaking calendar. Can anyone please tell me how I can align this. Below is the code. Someone please show me how to align the damn calendar.

    Code:
    ##################################
    ## VinDSL | rev. 11-12-01 20:20 ##
    ##################################
    ##     December 2011 Series     ##
    ##################################
    
    ## ¡PLEASE READ THE FINE PRINT! ##
    
    ####
    ## Development Platforms (current)
    #
    #  Ubuntu 10.10 'Maverick Meerkat' (GNOME 2.28 - Conky 1.8.0)
    #  Ubuntu 12.04 'Precise Pangolin' (GNOME-SHELL - UNITY 2D/3D - Conky 1.8.1)
    #  Screen Resolution: 1280x1024x24 (DELL UltraSharp 1907FP)
    
    ####
    ## Prerequisites (required)
    #
    #  conky-all 1.8.0 or 1.8.1-5
    #  cURL - Command Line Tool
    #  xsltproc - Command Line Tool
    #  UTF-8 Compatible Text Editor
    #
    ## Tips n' Tricks
    ## Several ppl (including myself) have experienced issues with conky-all 1.8.1-6
    ## In every instance, downgrading to conky-all 1.8.1-5 has solved the problem(s).
    ## I recommend using (and pinning) conky-all 1.8.1-5 until things get sorted.
    ## conky-all 1.8.1-5 can be downloaded here: https://launchpad.net/ubuntu/+source/conky-all/1.8.1-5
    
    ####
    ## Installed fonts (required)
    #
    #  ConkyWeather (Stanko Metodiev)
    #  Cut Outs for 3D FX (Fonts & Things)
    #  Droid Font Family (Google Android SDK)
    #  KR A Round (Kat's Fun Fonts)
    #  OpenLogos (Icoma)
    #  PizzaDude Bullets (Jakob Fischer)
    #  Radio Space (Iconian Fonts)
    #  StyleBats (Vinterstille)
    #  Ubuntu Font Family (Canonical Ltd)
    #  Ubuntu Title Bold (Paulo Silva - not included in link below)
    #  Weather (Jonathan Macagba)
    # 
    ## Tips n' Tricks from Mr. Peachy, djyoung4, and 42dorian (Thanks!)
    ## Most necessary fonts can be downloaded here: http://ompldr.org/vOHdoag
    ## Unzip the fonts into your font folder, for example: /home/username/.fonts
    ## Run this command in a terminal (rebuilds font cache file): sudo fc-cache -fv
    
    ####
    ## Use XFT? Required to Force UTF8 (see below)
    #
    use_xft yes
    xftfont DroidSans:size=8.75
    xftalpha 0.1
    
    ####
    ## Force UTF8? Requires XFT (see above)
    ## Displays degree symbol, instead of °, etc.
    #
    override_utf8_locale yes
    
    ####
    ## This buffer is used for text, single lines, output from $exec, and other variables.
    ## Increasing the text buffer size (too high) will drastically reduce Conky's performance.
    ## Decreasing the size (too low) will truncate content and cause strange display output.
    ## Standard text buffer size is 256 bytes (cannot be less). Adjust YOUR buffer wisely!
    #
    text_buffer_size 640
    
    ####
    ## Daemonize Conky, aka 'fork to background'.
    #
    background yes
    
    ####
    ## Update interval in seconds.
    #
    update_interval 2.0
    
    ####
    ## The number of times Conky will update before quitting.
    ## Zero makes Conky run forever.
    #
    total_run_times 0
    
    ####
    ## Create own window in instead of using desktop?
    #
    own_window yes
    own_window_transparent yes
    own_window_type normal
    own_window_class conky-semi
    own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager
    ####
    ## Some distros also require the following 2 lines.
    #
    own_window_argb_visual yes
    own_window_argb_value 255
    
    ####
    ## Force images to redraw when they change.
    #
    imlib_cache_size 0
    
    ####
    ## Use double buffering? Reduces flicker.
    #
    double_buffer yes
    
    ####
    ## Draw shades?
    #
    draw_shades yes
    default_shade_color 292421
    
    ####
    ## Draw outlines?
    #
    draw_outline no
    
    ####
    ## Draw borders around text?
    #
    draw_borders no
    
    ####
    ## Draw borders around graphs?
    #
    draw_graph_borders no
    
    ####
    ## Print text to stdout?
    ## Print text in console?
    #
    out_to_ncurses no
    out_to_console no
    
    ####
    ## Text alignment.
    #
    alignment top_right
    
    ####
    ## Minimum size of the text area.
    ## Syntax: minimum_size [width] [height]
    #
    minimum_size 240 1349
    
    ####
    ## Maximum width of the text area.
    ## Syntax: maximum_width [width]
    #
    maximum_width 240
    
    
    ####
    ## Gap between text and screen borders.
    #
    gap_x 6	  ## Left / Right
    gap_y 32  ## Top / Bottom
    
    ####
    ## Shorten MiB/GiB to M/G in stats.
    #
    short_units yes
    
    ####
    ## Pad % symbol spacing after numbers.
    #
    pad_percents 0
    
    ####
    ## Pad spacing between text and borders.
    #
    border_inner_margin 4
    
    ####
    ## Limit the length of names in "Top Processes".
    #
    top_name_width 10
    
    ####
    ## Subtract file system -/+buffers/cache from used memory?
    ## Set to yes, to produce meaningful physical memory stats.
    #
    no_buffers yes
    
    ####
    ## Set to yes, if you want all text to be in UPPERCASE.
    #
    uppercase no
    
    ####
    ## Number of cpu samples to average.
    ## Set to 1 to disable averaging.
    #
    cpu_avg_samples 2
    
    ####
    ## Number of net samples to average.
    ## Set to 1 to disable averaging.
    #
    net_avg_samples 2
    
    ####
    ## Add spaces to keep things from moving around?
    ## Only affects certain objects.
    #
    use_spacer right
    
    ####
    ## My colors (suit yourself)
    #
    color0 White		#FFFFFF
    color1 Ivory		#FFFFF0
    color2 Ivory2		#EEEEE0
    color3 Ivory3		#CDCDC1
    color4 Tan1		#FFA54F
    color5 Tan2		#EE9A49
    color6 Gray		#7E7E7E
    color7 AntiqueWhite4	#8B8378
    color8 DimGray		#696969
    color9 Tomato		#FF6347
    
    #####
    ## Load Lua for shading (optional)
    ## Set the path to your script here.
    #
    lua_load ~/.conky/draw_bg.lua
    lua_draw_hook_pre draw_bg
    
    ####
    ## Load Lua for bargraphs (required)
    ## Set the path to your script here.
    #
    lua_load ~/.conky/bargraph_small.lua
    lua_draw_hook_post main_bars
    
    TEXT
    ##################################
    ##             LOGO             ##
    ##################################
    ## Uncomment for hard-coded ID (static)
    ${voffset -33}${font OpenLogos:size=103}${color2}v${font}${voffset -76}${goto 179}${font UbuntuTitleBold:size=19.6}${color4}1${offset 1}2${offset 1}.${offset 0}0${offset 0}4${font}
    ####
    ## Uncomment for soft-coded ID (dynamic)
    # ${voffset -33}${font OpenLogos:size=103}${color2}v${font}${voffset -76}${goto 179}${font UbuntuTitleBold:size=19.6}${color4}${pre_exec cat /etc/*release | grep 'RELEASE' | awk -F'=' '{print $2}'}${font}
    ####
    ## Additional ID (branch version, code name, release date, etc.)
    ${voffset -1}${goto 188}${font Ubuntu-B:size=8.1}${color4}alpha 1${font}
    ##################################
    ##            SYSTEM            ##
    ##################################
    ${voffset 7}${font DroidSans:bold:size=8.25}${color4}SYSTEM${offset 8}${color8}${voffset -2}${hr 2}${font}
    # ${voffset 4}${font OpenLogos:size=10}${color2}u${voffset -4}${font DroidSans:size=8.6}${color3}${offset 5}${pre_exec lsb_release -sd || cat /etc/*release}${font}
    ${voffset 2}${offset -2}${font OpenLogos:size=12}${color2}Z${voffset -4}${font DroidSans:size=8.6}${color3}${offset 3}${sysname}${offset 3}${kernel}${alignr}${font DroidSans:size=8.3}${machine}${font}
    ${voffset 2}${font StyleBats:size=10}${color2}q${voffset -1}${font DroidSans:size=8.6}${color3}${offset 5}System${offset 3}Uptime${alignr}${font DroidSans:size=8.3}${uptime_short}${font}
    ${voffset 4}${font StyleBats:size=9.9}${color2}k${voffset -2}${font DroidSansFallback:size=8.39}${color3}${offset 2}CPU1${offset 5}${font DroidSans:size=8.3}${cpu cpu1}%${font}
    ${voffset 2}${font StyleBats:size=9.9}${color2}k${voffset -2}${font DroidSansFallback:size=8.39}${color3}${offset 2}CPU2${offset 5}${font DroidSans:size=8.3}${cpu cpu2}%${font}
    ${voffset 4}${font StyleBats:size=10}${color2}l${voffset -2}${font DroidSansFallback:size=8.3}${color3}${offset 3}RAM${goto 97}${font DroidSans:size=8.3}${mem}${goto 133}/${offset 5}${memmax}${alignr}${memperc}%${font}
    ${voffset 6}${font StyleBats:size=9.9}${color2}x${voffset -2}${font DroidSansFallback:size=8.3}${color3}${offset 4}ROOT${goto 95}${font DroidSans:size=8.3}${fs_used /}${goto 133}/${offset 5}${fs_size /}${alignr}${fs_free_perc /}%${font}
    ##################################
    ##         TOP PROCESSES        ##
    ##################################
    ${voffset 15}${font DroidSans:bold:size=8}${color4}TOP PROCESSES${offset 8}${color8}${voffset -2}${hr 2}${font}
    ${voffset 6}${font StyleBats:size=10}${color1}h${voffset -1}${font DroidSans:size=8.65}${color3}${offset 5}${top_mem name 1}${goto 120}${font DroidSans:size=8.3}${top_mem mem_res 1}${alignr}${top_mem mem 1}%${font}
    ${voffset 1}${font StyleBats:size=10}${color1}h${voffset -1}${font DroidSans:size=8.65}${color3}${offset 5}${top_mem name 2}${goto 120}${font DroidSans:size=8.3}${top_mem mem_res 2}${alignr}${top_mem mem 2}%${font}
    ${voffset 1}${font StyleBats:size=10}${color1}h${voffset -1}${font DroidSans:size=8.65}${color3}${offset 5}${top_mem name 3}${goto 120}${font DroidSans:size=8.3}${top_mem mem_res 3}${alignr}${top_mem mem 3}%${font}
    # ${voffset 1}${font StyleBats:size=10}${color1}h${voffset -1}${font DroidSans:size=8.65}${color3}${offset 5}${top_mem name 4}${goto 120}${font DroidSans:size=8.3}${top_mem mem_res 4}${alignr}${top_mem mem 4}%${font}
    # ${voffset 1}${font StyleBats:size=10}${color1}h${voffset -1}${font DroidSans:size=8.65}${color3}${offset 5}${top_mem name 5}${goto 120}${font DroidSans:size=8.3}${top_mem mem_res 5}${alignr}${top_mem mem 5}%${font}
    # ${voffset 1}${font StyleBats:size=10}${color1}h${voffset -1}${font DroidSans:size=8.65}${color3}${offset 5}${top_mem name 6}${goto 120}${font DroidSans:size=8.3}${top_mem mem_res 6}${alignr}${top_mem mem 6}%${font}
    ##################################
    ##           NETWORK            ##
    ##################################
    ${voffset 4}${font DroidSans:bold:size=8}${color4}NETWORK${offset 8}${color8}${voffset -2}${hr 2}${font}
    ${voffset 4}${font PizzaDudeBullets:size=9.5}${color6}T${font DroidSans:size=8.65}${color3}${offset 5}Download${goto 120}${font DroidSans:size=8.3}${totaldown wlan0}${alignr}${font DroidSans:size=8.3}${downspeed eth0}${font}
    ${voffset 0}${font PizzaDudeBullets:size=9.5}${color6}N${font DroidSans:size=8.65}${color3}${offset 5}Upload${goto 120}${font DroidSans:size=8.3}${totalup wlan0}${alignr}${font DroidSans:size=8.3}${upspeed wlan0}${font}
    ${voffset 4}${font PizzaDudeBullets:size=9.5}${color6}a${font DroidSans:size=8.65}${color3}${offset 5}Private${offset 3}IP${goto 123}${font DroidSansFallback:size=8.5}LAN${alignr}${font DroidSans:size=8.3}${addr wlan0}${font}
    ${voffset 0}${font PizzaDudeBullets:size=9.5}${color6}a${font DroidSans:size=8.65}${color3}${offset 5}Public${offset 7}IP${goto 121}${font DroidSansFallback:size=8.5}WAN${alignr}${font DroidSans:size=8.3}${execi 1800 wget -q -O - checkip.dyndns.org | sed -e 's/[^[:digit:]\|.]//g'}${font}
    ##################################
    ##     WEATHER (Imperial)       ##
    ##################################
    ${voffset 4}${font DroidSans:bold:size=8.25}${color4}WEATHER${offset 8}${color8}${voffset -2}${hr 2}${font}
    ${voffset -55}${font RadioSpace:size=34}${color3}${execi 1800 /home/wayne/.conky/weather/weather.sh "34446" ctbi}${font}${voffset -28}${goto 33}${font Weather:size=42}${color3}y${font}
    ${voffset -38}${font Ubuntu:size=8.63}${color5}${execi 1800 /home/wayne/.conky/weather/weather.sh "34446" ctti}${font}
    ${voffset -39}${font KRARound:size=36}${color3}${goto 195}I${font}
    ${voffset 6}${font Ubuntu:size=23}${color5}${alignc -2}${execi 1800 /home/wayne/.conky/weather/weather.sh "34446" ccb}${font}
    ${voffset 8}${font DroidSansFallback:size=8.63}${color3}${execi 1800 /home/wayne/.conky/weather/weather.sh "34446"}${font}
    ${voffset -57}${font ConkyWeather:size=48}${color6}${alignc -55}${execi 1800 /home/wayne/.conky/weather/weather.sh "34446" cp}${font}
    ${voffset 6}${font DroidSansMono:bold:size=8.62}${color4}${offset 40}${execi 1800 /home/wayne/.conky/weather/weather.sh "34446" dl}${font}
    ${voffset 0}${font ConkyWeather:size=37.9}${color3}${offset 26}${execi 1800 /home/wayne/.conky/weather/weather.sh "34446" fcp}${font}
    ${voffset 0}${font DroidSansFallback:bold:size=8.62}${color4}${offset 28}${execi 1800 /home/wayne/.conky/weather/weather.sh "34446" fcti}${font}
    ##################################
    ##             TIME             ##
    ##################################
    ${voffset 4}${font DroidSans:bold:size=8}${color4}TIME${offset 8}${color8}${voffset -2}${hr 2}${font}
    ${voffset -4}${font RadioSpace:size=32}${color3}${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}
    ##################################
    ##      CALENDAR (5-Line)       ##
    ##################################
    ${voffset 4}${font DroidSans:bold:size=8}${color4}DATE${offset 8}${color8}${voffset -2}${hr 2}${font}
    ${voffset 18}${font DroidSansMono:size=7.55}${color3}${alignc 60}${time %A}${font}
    ${voffset -4}${font DroidSansFallback:bold:size=18}${if_match ${time %e}<=9}${color5}${alignc 65}${time %e}${font}${else}${if_match ${time %e}>=10}${color5}${alignc 60}${time %e}${endif}${endif}${font}
    ${voffset 0}${font DroidSansMono:size=7.55}${color3}${alignc 60}${time %B}${font}
    ${voffset 0}${font DroidSansMono:size=7.6}${color3}${alignc 60}${time %Y}${font}
    ${voffset -83}${font CutOutsFor3DFX:size=67}${color8}${alignc 99}2${font}
    ${voffset -64}${offset 100}${font DroidSansMono:size=7.55}${color3}${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}&${color3}/'}
    ##################################
    ##    BANSHEE (Experimental)    ##
    ##################################
    ${if_running banshee}
    ${voffset -10}${font DroidSans:bold:size=7.75}${color4}BANSHEE${offset 8}${color8}${voffset -2}${hr 2}${font}
    ${voffset 4}${font DroidSans:size=8.25}${color3}${if_match "${execpi 2 expr length "`/usr/bin/banshee --query-artist --query-title --no-present | cut -f1- -d " "`"}" >= "48"}${alignr 15}${scroll 38 4* ${execi 2 banshee --query-artist --query-title --no-present | cut -f2- -d " "}}${font}${else}${execi 2 banshee --query-artist --query-title --no-present | cut -f2- -d " "}${font}${endif}${endif}
    This was pretty good considering I couldn't get the LUA & Cairo stuff to work earlier today. I figured everything else out by reading the how to, but it doesn't really explain the calendar.
    Attached Images Attached Images
    Last edited by ihatethisflavorsomuch; August 24th, 2012 at 07:52 PM.

  2. #20372
    Join Date
    Feb 2010
    Beans
    Hidden!

    Re: Post your .conkyrc files w/ screenshots

    Quote Originally Posted by ihatethisflavorsomuch View Post
    This was pretty good considering I couldn't get the LUA & Cairo stuff to work earlier today. I figured everything else out by reading the how to, but it doesn't really explain the calendar.
    Top of the code reads:
    Code:
    ## Tips n' Tricks
    ## Several ppl (including myself) have experienced issues with conky-all 1.8.1-6
    ## In every instance, downgrading to conky-all 1.8.1-5 has solved the problem(s).
    ## I recommend using (and pinning) conky-all 1.8.1-5 until things get sorted.
    ## conky-all 1.8.1-5 can be downloaded here: https://launchpad.net/ubuntu/+source/conky-all/1.8.1-5
    What conky version are you running?
    Code:
    conky -v
    EDIT:
    This line good for conky v1.8.1-5 and conky v1.9.0-2:
    Code:
    ${voffset -68}${font DroidSansMono:size=7.55}${color3}${execpi 60 VinDSL_Cal_9=`date +%-d`; cal -h | sed -e 's/\r//g' -e 's/^/ /g' -e '1d' -e s/^/"\$\{offset 100"\}/ -e 's/\<'"$VinDSL_Cal_9"'\>/${color4}&${color3}/'}
    Last edited by Sector11; August 24th, 2012 at 08:44 PM.

  3. #20373

    Re: Post your .conkyrc files w/ screenshots

    Quote Originally Posted by Sector11 View Post
    Top of the code reads:
    Code:
    ## Tips n' Tricks
    ## Several ppl (including myself) have experienced issues with conky-all 1.8.1-6
    ## In every instance, downgrading to conky-all 1.8.1-5 has solved the problem(s).
    ## I recommend using (and pinning) conky-all 1.8.1-5 until things get sorted.
    ## conky-all 1.8.1-5 can be downloaded here: https://launchpad.net/ubuntu/+source/conky-all/1.8.1-5
    What conky version are you running?
    Code:
    conky -v
    Conky 1.9.0 Do you think if I downgraded to 1.8.5 that would fix the issue?

  4. #20374
    Join Date
    Feb 2010
    Beans
    Hidden!

    Re: Post your .conkyrc files w/ screenshots

    Quote Originally Posted by ihatethisflavorsomuch View Post
    Conky 1.9.0 Do you think if I downgraded to 1.8.5 that would fix the issue?
    Read my edit above. Keep the conky version you have.

    Code:
    ##################################
    ##      CALENDAR (5-Line)       ##
    ##################################
    ${voffset 4}${font DroidSans:bold:size=8}${color4}DATE${offset 8}${color8}${voffset -2}${hr 2}${font}
    ${voffset 18}${font DroidSansMono:size=7.55}${color3}${alignc 60}${time %A}${font}
    ${voffset -4}${font DroidSansFallback:bold:size=18}${if_match ${time %e}<=9}${color5}${alignc 65}${time %e}${font}${else}${if_match ${time %e}>=10}${color5}${alignc 60}${time %e}${endif}${endif}${font}
    ${voffset 0}${font DroidSansMono:size=7.55}${color3}${alignc 60}${time %B}${font}
    ${voffset 0}${font DroidSansMono:size=7.6}${color3}${alignc 60}${time %Y}${font}
    ${voffset -83}${font CutOutsFor3DFX:size=67}${color8}${alignc 99}2${font}
    ## Uncomment for Conky 1.8.0 & 1.9.0-2 (use mono fonts only)
    ${voffset -68}${font DroidSansMono:size=7.55}${color3}${execpi 60 VinDSL_Cal_9=`date +%-d`; cal -h | sed -e 's/\r//g' -e 's/^/ /g' -e '1d' -e s/^/"\$\{offset 100"\}/ -e 's/\<'"$VinDSL_Cal_9"'\>/${color4}&${color3}/'}
    Attached Images Attached Images
    Last edited by Sector11; August 24th, 2012 at 08:39 PM.

  5. #20375

    Re: Post your .conkyrc files w/ screenshots

    Quote Originally Posted by Sector11 View Post
    Read my edit above. Keep the conky version you have.

    Code:
    ##################################
    ##      CALENDAR (5-Line)       ##
    ##################################
    ${voffset 4}${font DroidSans:bold:size=8}${color4}DATE${offset 8}${color8}${voffset -2}${hr 2}${font}
    ${voffset 18}${font DroidSansMono:size=7.55}${color3}${alignc 60}${time %A}${font}
    ${voffset -4}${font DroidSansFallback:bold:size=18}${if_match ${time %e}<=9}${color5}${alignc 65}${time %e}${font}${else}${if_match ${time %e}>=10}${color5}${alignc 60}${time %e}${endif}${endif}${font}
    ${voffset 0}${font DroidSansMono:size=7.55}${color3}${alignc 60}${time %B}${font}
    ${voffset 0}${font DroidSansMono:size=7.6}${color3}${alignc 60}${time %Y}${font}
    ${voffset -83}${font CutOutsFor3DFX:size=67}${color8}${alignc 99}2${font}
    ## Uncomment for Conky 1.8.0 & 1.9.0-2 (use mono fonts only)
    ${voffset -68}${font DroidSansMono:size=7.55}${color3}${execpi 60 VinDSL_Cal_9=`date +%-d`; cal -h | sed -e 's/\r//g' -e 's/^/ /g' -e '1d' -e s/^/"\$\{offset 100"\}/ -e 's/\<'"$VinDSL_Cal_9"'\>/${color4}&${color3}/'}
    You sure are super swell That worked perfectly. Now to study this code to find out what I was doing wrong. Thank you very much!

  6. #20376
    Join Date
    Feb 2010
    Beans
    Hidden!

    Re: Post your .conkyrc files w/ screenshots

    Quote Originally Posted by ihatethisflavorsomuch View Post
    You sure are super swell That worked perfectly. Now to study this code to find out what I was doing wrong. Thank you very much!
    It's not that you did anything wrong. VinDSL has two lines for the calendar depending on which version of conky you have, unfortunately it doesn't mention conky v1.9.0-2:

    Code:
    ##################################
    ##      CALENDAR (5-Line)       ##
    ##################################
    ${voffset 4}${font DroidSans:bold:size=8}${color4}DATE${offset 8}${color8}${voffset -2}${hr 2}${font}
    ${voffset 18}${font DroidSansMono:size=7.55}${color3}${alignc 60}${time %A}${font}
    ${voffset -4}${font DroidSansFallback:bold:size=18}${if_match ${time %e}<=9}${color5}${alignc 65}${time %e}${font}${else}${if_match ${time %e}>=10}${color5}${alignc 60}${time %e}${endif}${endif}${font}
    ${voffset 0}${font DroidSansMono:size=7.55}${color3}${alignc 60}${time %B}${font}
    ${voffset 0}${font DroidSansMono:size=7.6}${color3}${alignc 60}${time %Y}${font}
    ${voffset -83}${font CutOutsFor3DFX:size=67}${color8}${alignc 99}2${font}
    ####
    ## Uncomment for Conky 1.8.0 (use mono fonts only)
    # ${voffset -68}${font DroidSansMono:size=7.55}${color3}${execpi 60 VinDSL_Cal_9=`date +%-d`; cal -h | sed -e 's/\r//g' -e 's/^/ /g' -e '1d' -e s/^/"\$\{offset 100"\}/ -e 's/\<'"$VinDSL_Cal_9"'\>/${color4}&${color3}/'}
    ####
    ## Uncomment for Conky 1.8.1 (use mono fonts only)
    ${voffset -64}${offset 100}${font DroidSansMono:size=7.55}${color3}${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}&${color3}/'}
    I just used the line you didn't use and it worked with v1.9.0-2.

    Suggestion: comment your code as such:
    Code:
    ## Uncomment for Conky 1.8.0 & 1.9.0-2 (use mono fonts only)
    so others will know if they use your code as well.

  7. #20377
    Join Date
    Oct 2009
    Location
    Under a rock
    Beans
    Hidden!

    Re: Post your .conkyrc files w/ screenshots

    @ihatethisflavorsomuch
    if you want a bit more control and varity to your calendar i have a lua version
    - use any font you want
    - alter spacing and format
    - more variety with colors

    here is the FUNCTION
    this is not a standalone script

    open up one of the scripts you already have loaded and paste this into the very bottom OUTSIDE of any code that is there
    eg paste into the bottom of draw_bg.lua
    Code:
    function conky_luacal(caltab) -- {x=,y=,tf="",tfs=,tc=,ta=,bf="",bfs=,bc=,ba=,hf="",hfs=,hc=,ha=,sp="",gt=,gh=,gv=,sd=}
    local function rgb_to_r_g_b(col,alp)
    return ((col / 0x10000) % 0x100) / 255, ((col / 0x100) % 0x100) / 255, (col % 0x100) / 255, alp
    end
    if conky_window == nil then return end
    local cs = cairo_xlib_surface_create(conky_window.display, conky_window.drawable, conky_window.visual, conky_window.width, conky_window.height)
    local cr = cairo_create(cs)
    --####################################################################################################
    if caltab.x==nil then
    caltab=loadstring("return" .. caltab)()
    end
    local cal_x=caltab.x
    local cal_y=caltab.y
    local tfont=caltab.tf        or "mono"
    local tfontsize=caltab.tfs    or 12
    local tc=caltab.tc        or 0xffffff
    local ta=caltab.ta        or 1
    local bfont=caltab.bf        or "mono"
    local bfontsize=caltab.bfs    or 12
    local bc=caltab.bc        or 0xffffff
    local ba=caltab.ba        or 1
    local hfont=caltab.hf        or "mono"
    local hfontsize=caltab.hfs    or 12
    local hc=caltab.hc        or 0xff0000
    local ha=caltab.ha        or 1
    local spacer=caltab.sp        or " "
    local gaph=caltab.gh        or 20
    local gapt=caltab.gt        or 15
    local gapl=caltab.gv        or 15
    local sday=caltab.sd        or 0
    --convert colors
    --local font=string.gsub(font,"_"," ")
    local tred,tgreen,tblue,talpha=rgb_to_r_g_b(tc,ta)
    --main body text color
    local bred,bgreen,bblue,balpha=rgb_to_r_g_b(bc,ba)
    --highlight text color
    local hred,hgreen,hblue,halpha=rgb_to_r_g_b(hc,ha)
    --###################################################
    --calendar calcs
    local year=os.date("%G")
    local today=tonumber(os.date("%d"))
    local t1 = os.time( {    year=year,month=03,day=01,hour=00,min=0,sec=0} );
    local t2 = os.time( {    year=year,month=02,day=01,hour=00,min=0,sec=0} );
    local feb=(os.difftime(t1,t2))/(24*60*60)
    local monthdays={ 31, feb, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 }
    local day=tonumber(os.date("%w"))+1-sday
    local day_num = today
    local remainder=day_num % 7
    local start_day=day-(day_num % 7)
    if start_day<0 then start_day=7+start_day end     
    local month=os.date("%m")
    local mdays=monthdays[tonumber(month)]
    local x=mdays+start_day
    local dnum={}
    local dnumh={}
    if mdays+start_day<36 then 
    dlen=35
    plen=29 
    else 
    dlen=42 
    plen=36
    end
    for i=1,dlen do
        if i<=start_day then 
        dnum[i]="  " 
        else 
        dn=i-start_day
            if dn=="nil" then dn=0 end
            if dn<=9 then dn=(spacer .. dn) end
            if i>x then dn="" end
            dnum[i]=dn
            dnumh[i]=dn
            if dn==(spacer .. today) or dn==today then
            dnum[i]=""
            end 
            if dn==(spacer .. today) or dn==today then
            dnumh[i]=dn
            place=i 
            else dnumh[i]="  " 
            end 
        end
    end--for
    cairo_select_font_face (cr, tfont, CAIRO_FONT_SLANT_NORMAL, CAIRO_FONT_WEIGHT_NORMAL);
    cairo_set_font_size (cr, tfontsize);
    cairo_set_source_rgba (cr,tred,tgreen,tblue,talpha)
    if tonumber(sday)==0 then
    dys={"SU","MO","TU","WE","TH","FR","SA"}
    else
    dys={"MO","TU","WE","TH","FR","SA","SU"}
    end
    --draw calendar titles
    for i=1,7 do
    cairo_move_to (cr, cal_x+(gaph*(i-1)), cal_y)
    cairo_show_text (cr, dys[i])
    cairo_stroke (cr)
    end
    --draw calendar body
    cairo_select_font_face (cr, bfont, CAIRO_FONT_SLANT_NORMAL, CAIRO_FONT_WEIGHT_NORMAL);
    cairo_set_font_size (cr, bfontsize);
    cairo_set_source_rgba (cr,bred,bgreen,bblue,balpha)
    for i=1,plen,7 do
    local fn=i
        for i=fn,fn+6 do
        cairo_move_to (cr, cal_x+(gaph*(i-fn)),cal_y+gapt+(gapl*((fn-1)/7)))
        cairo_show_text (cr, dnum[i])
        cairo_stroke (cr)
        end
    end
    --highlight
    cairo_select_font_face (cr, hfont, CAIRO_FONT_SLANT_NORMAL, CAIRO_FONT_WEIGHT_NORMAL);
    cairo_set_font_size (cr, hfontsize);
    cairo_set_source_rgba (cr,hred,hgreen,hblue,halpha)
    for i=1,plen,7 do
    local fn=i
        for i=fn,fn+6 do
        cairo_move_to (cr, cal_x+(gaph*(i-fn)),cal_y+gapt+(gapl*((fn-1)/7)))
        cairo_show_text (cr, dnumh[i])
        cairo_stroke (cr)
        end
    end
    --#########################################################################################################
    caltab=nil
    dlen=nil
    plen=nil
    cairo_destroy(cr)
    cairo_surface_destroy(cs)
    cr=nil
    return ""
    end-- end main function###################################################################################
    save the file
    then to use it, the lua is already loaded and you activate the calendar function BELOW TEXT like this
    Code:
    ${lua luacal {settings}}
    setting instructions:
    Code:
    #${lua luacal {x=,y=,tf="",tfs=,tc=,ta=,bf="",bfs=,bc=,ba=,hf="",hfs=,hc=,ha=,sp="",gh=,gt=,gv=,sd=}}
    #    x=x position top left
    #    y=y position top left
    #    tf=title font, eg "mono" must be in quotes
    #    tfs=title font size
    #    tc=title color
    #    ta=title alpha
    #    bf=body font, eg "mono" must be in quotes
    #    bfs=body font size
    #    bc=body color
    #    ba=body alpha
    #    hf=highlight font, eg "mono" must be in quotes
    #    hfs=highlight font size
    #    hc=highlight color
    #    ha=highlight alpha
    #    sp=spacer, eg " " ... 0,1 or 2 spaces can help with positioning of non-monospaced fonts
    #    gt=gap from title to body
    #    gh=gap horizontal between columns
    #    gv=gap vertical between rows
    #    sd=start day, 0=Sun, 1=Mon
    edit - fixed a typo in this line
    #${lua luacal {x=,y=,tf="",tfs=,tc=,ta=,bf="",bfs=,bc=,ba=,hf="" ,hfs=,hc=,ha=,sp="",gh=,gt=,gv=,sd=}}

    here is an example with some non-monospaced fonts

    Last edited by mrpeachy; August 25th, 2012 at 01:11 AM.

  8. #20378
    Join Date
    Feb 2010
    Beans
    Hidden!

    Re: Post your .conkyrc files w/ screenshots

    Quote Originally Posted by mrpeachy View Post
    here is an example with some non-monospaced fonts

    I have to admit I do like that - I have to try it.

    If I add that to 'draw-bk.lua' as you say and don't use

    Code:
    ${lua luacal {settings}}
    it will do nothing.

    Will it interfere with CPU usage?
    Any memory leakage?

  9. #20379
    Join Date
    Oct 2009
    Location
    Under a rock
    Beans
    Hidden!

    Re: Post your .conkyrc files w/ screenshots

    Quote Originally Posted by Sector11 View Post
    I have to admit I do like that - I have to try it.

    If I add that to 'draw-bk.lua' as you say and don't use

    Code:
    ${lua luacal {settings}}
    it will do nothing.
    correct

    Will it interfere with CPU usage?
    no, unless you call the function as described, the code will not run

    Any memory leakage?
    none as far as i am aware
    the function doesnt use any conky_parse commands
    and everything that can be localised has been localised
    also these lines do a lot to prevent memory leaks
    Code:
    cairo_destroy(cr)
    cairo_surface_destroy(cs)
    cr=nil
    EDIT - also i didnt include the code for the calendar i posted

    Code:
    TEXT
    ${lua luacal {x=10,y=100,tf="Purisa",tfs=24,tc=0xf67e16,ta=1,bf="First Order",bfs=26,bc=0xecd32a,ba=1,hf="Purisa",hfs=18,hc=0xf67e16,ha=1,sp=" ",gh=40,gt=20,gv=20,sd=0}}
    Last edited by mrpeachy; August 25th, 2012 at 02:08 AM.

  10. #20380
    Join Date
    Feb 2010
    Beans
    Hidden!

    Re: Post your .conkyrc files w/ screenshots

    @ mrpeachy

    Thanks time to play.

Page 2038 of 2348 FirstFirst ... 1038153819381988202820362037203820392040204820882138 ... LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •