From 8d4f8607dc1558ce73eb4c376bdbf78ddb65da83 Mon Sep 17 00:00:00 2001 From: Christian Wieninger Date: Sun, 11 Nov 2007 15:40:28 +0100 Subject: Initial commit --- COPYING | 340 + HISTORY | 1089 +++ HISTORY.DE | 844 ++ INSTALL | 36 + INSTALL.DE | 22 + MANUAL | 1 + Makefile | 225 + README | 1 + README.DE | 1 + README.Translators | 44 + afuzzy.c | 271 + afuzzy.h | 65 + blacklist.c | 762 ++ blacklist.h | 100 + buildutil/pot2i18n.pl | 157 + changrp.c | 528 ++ changrp.h | 110 + conf/epgsearchcats.conf-epgdata | 50 + conf/epgsearchcats.conf-tvm2vdr-hoerzu | 54 + conf/epgsearchcats.conf-tvm2vdr-tvmovie | 48 + conf/epgsearchconflmail.templ | 58 + conf/epgsearchmenu.conf | 37 + conf/epgsearchupdmail-html.templ | 157 + conf/epgsearchupdmail.templ | 68 + conflictcheck.c | 648 ++ conflictcheck.h | 307 + conflictcheck_thread.c | 156 + conflictcheck_thread.h | 52 + conflictcheckonly.c | 227 + createcats.c | 348 + distance.c | 175 + distance.h | 47 + doc-src/de/epgsearch.1.txt | 1187 +++ doc-src/de/epgsearch.conf.5.txt | 142 + doc-src/de/epgsearchblacklists.conf.5.txt | 72 + doc-src/de/epgsearchcats.conf.5.txt | 140 + doc-src/de/epgsearchchangrps.conf.5.txt | 73 + doc-src/de/epgsearchcmds.conf.5.txt | 78 + doc-src/de/epgsearchdirs.conf.5.txt | 97 + doc-src/de/epgsearchmenu.conf.5.txt | 133 + doc-src/de/epgsearchswitchtimers.conf.5.txt | 75 + doc-src/de/epgsearchtemplates.conf.5.txt | 60 + doc-src/de/epgsearchuservars.conf.5.txt | 188 + doc-src/de/noannounce.conf.5.txt | 53 + doc-src/de/timersdone.conf.5.txt | 55 + doc-src/en/createcats.1.txt | 120 + doc-src/en/epgsearch.1.txt | 1116 +++ doc-src/en/epgsearch.4.txt | 880 ++ doc-src/en/epgsearch.conf.5.txt | 145 + doc-src/en/epgsearchblacklists.conf.5.txt | 71 + doc-src/en/epgsearchcats.conf.5.txt | 133 + doc-src/en/epgsearchchangrps.conf.5.txt | 65 + doc-src/en/epgsearchcmds.conf.5.txt | 73 + doc-src/en/epgsearchdirs.conf.5.txt | 103 + doc-src/en/epgsearchmenu.conf.5.txt | 144 + doc-src/en/epgsearchswitchtimers.conf.5.txt | 73 + doc-src/en/epgsearchtemplates.conf.5.txt | 59 + doc-src/en/epgsearchuservars.conf.5.txt | 182 + doc-src/en/noannounce.conf.5.txt | 71 + doc-src/en/timersdone.conf.5.txt | 52 + doc/de/epgsearch.1.txt | 1072 +++ doc/de/epgsearch.conf.5.txt | 144 + doc/de/epgsearchblacklists.conf.5.txt | 72 + doc/de/epgsearchcats.conf.5.txt | 140 + doc/de/epgsearchchangrps.conf.5.txt | 71 + doc/de/epgsearchcmds.conf.5.txt | 77 + doc/de/epgsearchdirs.conf.5.txt | 97 + doc/de/epgsearchmenu.conf.5.txt | 134 + doc/de/epgsearchswitchtimers.conf.5.txt | 72 + doc/de/epgsearchtemplates.conf.5.txt | 59 + doc/de/epgsearchuservars.conf.5.txt | 189 + doc/de/noannounce.conf.5.txt | 56 + doc/de/timersdone.conf.5.txt | 55 + doc/en/createcats.1.txt | 115 + doc/en/epgsearch.1.txt | 999 ++ doc/en/epgsearch.4.txt | 856 ++ doc/en/epgsearch.conf.5.txt | 145 + doc/en/epgsearchblacklists.conf.5.txt | 75 + doc/en/epgsearchcats.conf.5.txt | 134 + doc/en/epgsearchchangrps.conf.5.txt | 67 + doc/en/epgsearchcmds.conf.5.txt | 74 + doc/en/epgsearchdirs.conf.5.txt | 104 + doc/en/epgsearchmenu.conf.5.txt | 148 + doc/en/epgsearchswitchtimers.conf.5.txt | 72 + doc/en/epgsearchtemplates.conf.5.txt | 61 + doc/en/epgsearchuservars.conf.5.txt | 182 + doc/en/noannounce.conf.5.txt | 73 + doc/en/timersdone.conf.5.txt | 56 + docsrc2html.sh | 42 + docsrc2man.sh | 60 + epgsearch.c | 648 ++ epgsearch.h | 56 + epgsearchcats.c | 146 + epgsearchcats.h | 70 + epgsearchcfg.c | 112 + epgsearchcfg.h | 148 + epgsearchext.c | 1559 ++++ epgsearchext.h | 231 + epgsearchonly.c | 145 + epgsearchservices.h | 49 + epgsearchsetup.c | 987 ++ epgsearchsetup.h | 132 + epgsearchsvdrp.c | 1306 +++ epgsearchtools.c | 1015 ++ epgsearchtools.h | 154 + html/de/epgsearch.1.html | 1369 +++ html/de/epgsearch.conf.5.html | 168 + html/de/epgsearchblacklists.conf.5.html | 101 + html/de/epgsearchcats.conf.5.html | 163 + html/de/epgsearchchangrps.conf.5.html | 100 + html/de/epgsearchcmds.conf.5.html | 109 + html/de/epgsearchdirs.conf.5.html | 124 + html/de/epgsearchmenu.conf.5.html | 153 + html/de/epgsearchswitchtimers.conf.5.html | 102 + html/de/epgsearchtemplates.conf.5.html | 87 + html/de/epgsearchuservars.conf.5.html | 206 + html/de/noannounce.conf.5.html | 85 + html/de/timersdone.conf.5.html | 86 + html/en/createcats.1.html | 145 + html/en/epgsearch.1.html | 1311 +++ html/en/epgsearch.4.html | 912 ++ html/en/epgsearch.conf.5.html | 172 + html/en/epgsearchblacklists.conf.5.html | 100 + html/en/epgsearchcats.conf.5.html | 157 + html/en/epgsearchchangrps.conf.5.html | 95 + html/en/epgsearchcmds.conf.5.html | 105 + html/en/epgsearchdirs.conf.5.html | 129 + html/en/epgsearchmenu.conf.5.html | 162 + html/en/epgsearchswitchtimers.conf.5.html | 102 + html/en/epgsearchtemplates.conf.5.html | 86 + html/en/epgsearchuservars.conf.5.html | 201 + html/en/noannounce.conf.5.html | 97 + html/en/timersdone.conf.5.html | 83 + i18n-generated.h | 12779 ++++++++++++++++++++++++++ i18n-template.h | 39 + i18n.c | 32 + i18n.h | 39 + log.h | 104 + mail.c | 459 + mail.h | 106 + main.c | 53 + mainmenushortcut.c | 170 + mainmenushortcut.h | 67 + man/de/epgsearch.1.gz | Bin 0 -> 17924 bytes man/de/epgsearch.conf.5.gz | Bin 0 -> 4308 bytes man/de/epgsearchblacklists.conf.5.gz | Bin 0 -> 2946 bytes man/de/epgsearchcats.conf.5.gz | Bin 0 -> 4075 bytes man/de/epgsearchchangrps.conf.5.gz | Bin 0 -> 2941 bytes man/de/epgsearchcmds.conf.5.gz | Bin 0 -> 3000 bytes man/de/epgsearchdirs.conf.5.gz | Bin 0 -> 3285 bytes man/de/epgsearchmenu.conf.5.gz | Bin 0 -> 4044 bytes man/de/epgsearchswitchtimers.conf.5.gz | Bin 0 -> 2908 bytes man/de/epgsearchtemplates.conf.5.gz | Bin 0 -> 2740 bytes man/de/epgsearchuservars.conf.5.gz | Bin 0 -> 4376 bytes man/de/noannounce.conf.5.gz | Bin 0 -> 2536 bytes man/de/timersdone.conf.5.gz | Bin 0 -> 2469 bytes man/en/createcats.1.gz | Bin 0 -> 3487 bytes man/en/epgsearch.1.gz | Bin 0 -> 15282 bytes man/en/epgsearch.4.gz | Bin 0 -> 13785 bytes man/en/epgsearch.conf.5.gz | Bin 0 -> 4198 bytes man/en/epgsearchblacklists.conf.5.gz | Bin 0 -> 2850 bytes man/en/epgsearchcats.conf.5.gz | Bin 0 -> 3856 bytes man/en/epgsearchchangrps.conf.5.gz | Bin 0 -> 2738 bytes man/en/epgsearchcmds.conf.5.gz | Bin 0 -> 2798 bytes man/en/epgsearchdirs.conf.5.gz | Bin 0 -> 3292 bytes man/en/epgsearchmenu.conf.5.gz | Bin 0 -> 4328 bytes man/en/epgsearchswitchtimers.conf.5.gz | Bin 0 -> 2785 bytes man/en/epgsearchtemplates.conf.5.gz | Bin 0 -> 2624 bytes man/en/epgsearchuservars.conf.5.gz | Bin 0 -> 4085 bytes man/en/noannounce.conf.5.gz | Bin 0 -> 2836 bytes man/en/timersdone.conf.5.gz | Bin 0 -> 2400 bytes md5.c | 320 + md5.h | 118 + menu_announcelist.c | 207 + menu_announcelist.h | 53 + menu_blacklistedit.c | 460 + menu_blacklistedit.h | 55 + menu_blacklists.c | 186 + menu_blacklists.h | 41 + menu_commands.c | 329 + menu_commands.h | 53 + menu_conflictcheck.c | 450 + menu_conflictcheck.h | 84 + menu_deftimercheckmethod.c | 187 + menu_deftimercheckmethod.h | 69 + menu_dirselect.c | 254 + menu_dirselect.h | 71 + menu_event.c | 245 + menu_event.h | 115 + menu_favorites.c | 191 + menu_favorites.h | 41 + menu_main.c | 519 ++ menu_main.h | 63 + menu_myedittimer.c | 490 + menu_myedittimer.h | 66 + menu_quicksearch.c | 340 + menu_quicksearch.h | 39 + menu_recsdone.c | 212 + menu_recsdone.h | 67 + menu_search.c | 255 + menu_search.h | 43 + menu_searchactions.c | 200 + menu_searchactions.h | 45 + menu_searchedit.c | 1142 +++ menu_searchedit.h | 126 + menu_searchresults.c | 891 ++ menu_searchresults.h | 147 + menu_searchtemplate.c | 252 + menu_searchtemplate.h | 46 + menu_switchtimers.c | 247 + menu_switchtimers.h | 54 + menu_templateedit.c | 320 + menu_templateedit.h | 37 + menu_timersdone.c | 222 + menu_timersdone.h | 62 + menu_whatson.c | 802 ++ menu_whatson.h | 84 + noannounce.c | 177 + noannounce.h | 64 + patches/MainMenuHooks-v1_0.patch | 155 + patches/timercmd-0.1_1.3.23.diff | 178 + patches/timercmd-0.1_1.3.25.diff | 142 + patches/vdr-replace-schedulemenu.diff | 33 + po/ca_ES.po | 1599 ++++ po/cs_CZ.po | 1597 ++++ po/da_DK.po | 1597 ++++ po/de_DE.po | 1641 ++++ po/el_GR.po | 1597 ++++ po/es_ES.po | 1596 ++++ po/et_EE.po | 1597 ++++ po/fi_FI.po | 1645 ++++ po/fr_FR.po | 1632 ++++ po/hr_HR.po | 1598 ++++ po/hu_HU.po | 1597 ++++ po/it_IT.po | 1598 ++++ po/nl_NL.po | 1598 ++++ po/nn_NO.po | 1597 ++++ po/pl_PL.po | 1596 ++++ po/pt_PT.po | 1596 ++++ po/ro_RO.po | 1597 ++++ po/ru_RU.po | 1596 ++++ po/sl_SI.po | 1597 ++++ po/sv_SE.po | 1597 ++++ po/tr_TR.po | 1596 ++++ quickepgsearch.c | 142 + rcfile.c | 104 + rcfile.h | 59 + recdone.c | 451 + recdone.h | 81 + recstatus.c | 186 + recstatus.h | 49 + scripts/autotimer2searchtimer.pl | 277 + scripts/convert_epgsearchdone_data.pl | 95 + scripts/convert_info_vdr.pl | 78 + scripts/epg2autotimer.sh | 32 + scripts/epg2master-timer.sh | 37 + scripts/epg2taste.sh | 26 + scripts/epgsearchcmds-fin.conf | 26 + scripts/epgsearchcmds-french.conf | 38 + scripts/epgsearchcmds.conf | 26 + scripts/mtdone2epgsearchdone.sh | 117 + scripts/recordingdone.sh | 163 + scripts/recrep.sh | 71 + scripts/rememberevent.sh | 56 + scripts/sendEmail.pl | 1873 ++++ scripts/timercmds-auxinfo.sh | 60 + scripts/timerrep.sh | 61 + scripts/undoneepgsearch.sh | 200 + searchtimer_thread.c | 887 ++ searchtimer_thread.h | 73 + services.c | 270 + services.h | 163 + source/vdr-epgsearchclient-0.0.1.tgz | Bin 0 -> 10188 bytes svdrpclient.h | 169 + switchtimer.c | 170 + switchtimer.h | 55 + switchtimer_thread.c | 130 + switchtimer_thread.h | 46 + templatefile.c | 315 + templatefile.h | 84 + timer_thread.c | 106 + timer_thread.h | 59 + timerdone.c | 211 + timerdone.h | 65 + uservars.c | 346 + uservars.h | 705 ++ varparser.c | 184 + varparser.h | 67 + vdr-epgsearch-0.9.24.beta9.tgz | Bin 0 -> 684338 bytes 289 files changed, 98611 insertions(+) create mode 100644 COPYING create mode 100644 HISTORY create mode 100644 HISTORY.DE create mode 100644 INSTALL create mode 100644 INSTALL.DE create mode 120000 MANUAL create mode 100644 Makefile create mode 120000 README create mode 120000 README.DE create mode 100644 README.Translators create mode 100644 afuzzy.c create mode 100644 afuzzy.h create mode 100644 blacklist.c create mode 100644 blacklist.h create mode 100755 buildutil/pot2i18n.pl create mode 100644 changrp.c create mode 100644 changrp.h create mode 100644 conf/epgsearchcats.conf-epgdata create mode 100644 conf/epgsearchcats.conf-tvm2vdr-hoerzu create mode 100644 conf/epgsearchcats.conf-tvm2vdr-tvmovie create mode 100644 conf/epgsearchconflmail.templ create mode 100644 conf/epgsearchmenu.conf create mode 100644 conf/epgsearchupdmail-html.templ create mode 100644 conf/epgsearchupdmail.templ create mode 100644 conflictcheck.c create mode 100644 conflictcheck.h create mode 100644 conflictcheck_thread.c create mode 100644 conflictcheck_thread.h create mode 100644 conflictcheckonly.c create mode 100644 createcats.c create mode 100644 distance.c create mode 100644 distance.h create mode 100644 doc-src/de/epgsearch.1.txt create mode 100644 doc-src/de/epgsearch.conf.5.txt create mode 100644 doc-src/de/epgsearchblacklists.conf.5.txt create mode 100644 doc-src/de/epgsearchcats.conf.5.txt create mode 100644 doc-src/de/epgsearchchangrps.conf.5.txt create mode 100644 doc-src/de/epgsearchcmds.conf.5.txt create mode 100644 doc-src/de/epgsearchdirs.conf.5.txt create mode 100644 doc-src/de/epgsearchmenu.conf.5.txt create mode 100644 doc-src/de/epgsearchswitchtimers.conf.5.txt create mode 100644 doc-src/de/epgsearchtemplates.conf.5.txt create mode 100644 doc-src/de/epgsearchuservars.conf.5.txt create mode 100644 doc-src/de/noannounce.conf.5.txt create mode 100644 doc-src/de/timersdone.conf.5.txt create mode 100644 doc-src/en/createcats.1.txt create mode 100644 doc-src/en/epgsearch.1.txt create mode 100644 doc-src/en/epgsearch.4.txt create mode 100644 doc-src/en/epgsearch.conf.5.txt create mode 100644 doc-src/en/epgsearchblacklists.conf.5.txt create mode 100644 doc-src/en/epgsearchcats.conf.5.txt create mode 100644 doc-src/en/epgsearchchangrps.conf.5.txt create mode 100644 doc-src/en/epgsearchcmds.conf.5.txt create mode 100644 doc-src/en/epgsearchdirs.conf.5.txt create mode 100644 doc-src/en/epgsearchmenu.conf.5.txt create mode 100644 doc-src/en/epgsearchswitchtimers.conf.5.txt create mode 100644 doc-src/en/epgsearchtemplates.conf.5.txt create mode 100644 doc-src/en/epgsearchuservars.conf.5.txt create mode 100644 doc-src/en/noannounce.conf.5.txt create mode 100644 doc-src/en/timersdone.conf.5.txt create mode 100644 doc/de/epgsearch.1.txt create mode 100644 doc/de/epgsearch.conf.5.txt create mode 100644 doc/de/epgsearchblacklists.conf.5.txt create mode 100644 doc/de/epgsearchcats.conf.5.txt create mode 100644 doc/de/epgsearchchangrps.conf.5.txt create mode 100644 doc/de/epgsearchcmds.conf.5.txt create mode 100644 doc/de/epgsearchdirs.conf.5.txt create mode 100644 doc/de/epgsearchmenu.conf.5.txt create mode 100644 doc/de/epgsearchswitchtimers.conf.5.txt create mode 100644 doc/de/epgsearchtemplates.conf.5.txt create mode 100644 doc/de/epgsearchuservars.conf.5.txt create mode 100644 doc/de/noannounce.conf.5.txt create mode 100644 doc/de/timersdone.conf.5.txt create mode 100644 doc/en/createcats.1.txt create mode 100644 doc/en/epgsearch.1.txt create mode 100644 doc/en/epgsearch.4.txt create mode 100644 doc/en/epgsearch.conf.5.txt create mode 100644 doc/en/epgsearchblacklists.conf.5.txt create mode 100644 doc/en/epgsearchcats.conf.5.txt create mode 100644 doc/en/epgsearchchangrps.conf.5.txt create mode 100644 doc/en/epgsearchcmds.conf.5.txt create mode 100644 doc/en/epgsearchdirs.conf.5.txt create mode 100644 doc/en/epgsearchmenu.conf.5.txt create mode 100644 doc/en/epgsearchswitchtimers.conf.5.txt create mode 100644 doc/en/epgsearchtemplates.conf.5.txt create mode 100644 doc/en/epgsearchuservars.conf.5.txt create mode 100644 doc/en/noannounce.conf.5.txt create mode 100644 doc/en/timersdone.conf.5.txt create mode 100755 docsrc2html.sh create mode 100755 docsrc2man.sh create mode 100644 epgsearch.c create mode 100644 epgsearch.h create mode 100644 epgsearchcats.c create mode 100644 epgsearchcats.h create mode 100644 epgsearchcfg.c create mode 100644 epgsearchcfg.h create mode 100644 epgsearchext.c create mode 100644 epgsearchext.h create mode 100644 epgsearchonly.c create mode 100644 epgsearchservices.h create mode 100644 epgsearchsetup.c create mode 100644 epgsearchsetup.h create mode 100644 epgsearchsvdrp.c create mode 100644 epgsearchtools.c create mode 100644 epgsearchtools.h create mode 100644 html/de/epgsearch.1.html create mode 100644 html/de/epgsearch.conf.5.html create mode 100644 html/de/epgsearchblacklists.conf.5.html create mode 100644 html/de/epgsearchcats.conf.5.html create mode 100644 html/de/epgsearchchangrps.conf.5.html create mode 100644 html/de/epgsearchcmds.conf.5.html create mode 100644 html/de/epgsearchdirs.conf.5.html create mode 100644 html/de/epgsearchmenu.conf.5.html create mode 100644 html/de/epgsearchswitchtimers.conf.5.html create mode 100644 html/de/epgsearchtemplates.conf.5.html create mode 100644 html/de/epgsearchuservars.conf.5.html create mode 100644 html/de/noannounce.conf.5.html create mode 100644 html/de/timersdone.conf.5.html create mode 100644 html/en/createcats.1.html create mode 100644 html/en/epgsearch.1.html create mode 100644 html/en/epgsearch.4.html create mode 100644 html/en/epgsearch.conf.5.html create mode 100644 html/en/epgsearchblacklists.conf.5.html create mode 100644 html/en/epgsearchcats.conf.5.html create mode 100644 html/en/epgsearchchangrps.conf.5.html create mode 100644 html/en/epgsearchcmds.conf.5.html create mode 100644 html/en/epgsearchdirs.conf.5.html create mode 100644 html/en/epgsearchmenu.conf.5.html create mode 100644 html/en/epgsearchswitchtimers.conf.5.html create mode 100644 html/en/epgsearchtemplates.conf.5.html create mode 100644 html/en/epgsearchuservars.conf.5.html create mode 100644 html/en/noannounce.conf.5.html create mode 100644 html/en/timersdone.conf.5.html create mode 100644 i18n-generated.h create mode 100644 i18n-template.h create mode 100644 i18n.c create mode 100644 i18n.h create mode 100644 log.h create mode 100644 mail.c create mode 100644 mail.h create mode 100644 main.c create mode 100644 mainmenushortcut.c create mode 100644 mainmenushortcut.h create mode 100644 man/de/epgsearch.1.gz create mode 100644 man/de/epgsearch.conf.5.gz create mode 100644 man/de/epgsearchblacklists.conf.5.gz create mode 100644 man/de/epgsearchcats.conf.5.gz create mode 100644 man/de/epgsearchchangrps.conf.5.gz create mode 100644 man/de/epgsearchcmds.conf.5.gz create mode 100644 man/de/epgsearchdirs.conf.5.gz create mode 100644 man/de/epgsearchmenu.conf.5.gz create mode 100644 man/de/epgsearchswitchtimers.conf.5.gz create mode 100644 man/de/epgsearchtemplates.conf.5.gz create mode 100644 man/de/epgsearchuservars.conf.5.gz create mode 100644 man/de/noannounce.conf.5.gz create mode 100644 man/de/timersdone.conf.5.gz create mode 100644 man/en/createcats.1.gz create mode 100644 man/en/epgsearch.1.gz create mode 100644 man/en/epgsearch.4.gz create mode 100644 man/en/epgsearch.conf.5.gz create mode 100644 man/en/epgsearchblacklists.conf.5.gz create mode 100644 man/en/epgsearchcats.conf.5.gz create mode 100644 man/en/epgsearchchangrps.conf.5.gz create mode 100644 man/en/epgsearchcmds.conf.5.gz create mode 100644 man/en/epgsearchdirs.conf.5.gz create mode 100644 man/en/epgsearchmenu.conf.5.gz create mode 100644 man/en/epgsearchswitchtimers.conf.5.gz create mode 100644 man/en/epgsearchtemplates.conf.5.gz create mode 100644 man/en/epgsearchuservars.conf.5.gz create mode 100644 man/en/noannounce.conf.5.gz create mode 100644 man/en/timersdone.conf.5.gz create mode 100644 md5.c create mode 100644 md5.h create mode 100644 menu_announcelist.c create mode 100644 menu_announcelist.h create mode 100644 menu_blacklistedit.c create mode 100644 menu_blacklistedit.h create mode 100644 menu_blacklists.c create mode 100644 menu_blacklists.h create mode 100644 menu_commands.c create mode 100644 menu_commands.h create mode 100644 menu_conflictcheck.c create mode 100644 menu_conflictcheck.h create mode 100644 menu_deftimercheckmethod.c create mode 100644 menu_deftimercheckmethod.h create mode 100644 menu_dirselect.c create mode 100644 menu_dirselect.h create mode 100644 menu_event.c create mode 100644 menu_event.h create mode 100644 menu_favorites.c create mode 100644 menu_favorites.h create mode 100644 menu_main.c create mode 100644 menu_main.h create mode 100644 menu_myedittimer.c create mode 100644 menu_myedittimer.h create mode 100644 menu_quicksearch.c create mode 100644 menu_quicksearch.h create mode 100644 menu_recsdone.c create mode 100644 menu_recsdone.h create mode 100644 menu_search.c create mode 100644 menu_search.h create mode 100644 menu_searchactions.c create mode 100644 menu_searchactions.h create mode 100644 menu_searchedit.c create mode 100644 menu_searchedit.h create mode 100644 menu_searchresults.c create mode 100644 menu_searchresults.h create mode 100644 menu_searchtemplate.c create mode 100644 menu_searchtemplate.h create mode 100644 menu_switchtimers.c create mode 100644 menu_switchtimers.h create mode 100644 menu_templateedit.c create mode 100644 menu_templateedit.h create mode 100644 menu_timersdone.c create mode 100644 menu_timersdone.h create mode 100644 menu_whatson.c create mode 100644 menu_whatson.h create mode 100644 noannounce.c create mode 100644 noannounce.h create mode 100644 patches/MainMenuHooks-v1_0.patch create mode 100644 patches/timercmd-0.1_1.3.23.diff create mode 100644 patches/timercmd-0.1_1.3.25.diff create mode 100644 patches/vdr-replace-schedulemenu.diff create mode 100644 po/ca_ES.po create mode 100644 po/cs_CZ.po create mode 100644 po/da_DK.po create mode 100644 po/de_DE.po create mode 100644 po/el_GR.po create mode 100644 po/es_ES.po create mode 100644 po/et_EE.po create mode 100644 po/fi_FI.po create mode 100644 po/fr_FR.po create mode 100644 po/hr_HR.po create mode 100644 po/hu_HU.po create mode 100644 po/it_IT.po create mode 100644 po/nl_NL.po create mode 100644 po/nn_NO.po create mode 100644 po/pl_PL.po create mode 100644 po/pt_PT.po create mode 100644 po/ro_RO.po create mode 100644 po/ru_RU.po create mode 100644 po/sl_SI.po create mode 100644 po/sv_SE.po create mode 100644 po/tr_TR.po create mode 100644 quickepgsearch.c create mode 100644 rcfile.c create mode 100644 rcfile.h create mode 100644 recdone.c create mode 100644 recdone.h create mode 100644 recstatus.c create mode 100644 recstatus.h create mode 100755 scripts/autotimer2searchtimer.pl create mode 100755 scripts/convert_epgsearchdone_data.pl create mode 100755 scripts/convert_info_vdr.pl create mode 100755 scripts/epg2autotimer.sh create mode 100755 scripts/epg2master-timer.sh create mode 100755 scripts/epg2taste.sh create mode 100755 scripts/epgsearchcmds-fin.conf create mode 100755 scripts/epgsearchcmds-french.conf create mode 100755 scripts/epgsearchcmds.conf create mode 100755 scripts/mtdone2epgsearchdone.sh create mode 100755 scripts/recordingdone.sh create mode 100755 scripts/recrep.sh create mode 100755 scripts/rememberevent.sh create mode 100755 scripts/sendEmail.pl create mode 100755 scripts/timercmds-auxinfo.sh create mode 100755 scripts/timerrep.sh create mode 100755 scripts/undoneepgsearch.sh create mode 100644 searchtimer_thread.c create mode 100644 searchtimer_thread.h create mode 100644 services.c create mode 100644 services.h create mode 100755 source/vdr-epgsearchclient-0.0.1.tgz create mode 100644 svdrpclient.h create mode 100644 switchtimer.c create mode 100644 switchtimer.h create mode 100644 switchtimer_thread.c create mode 100644 switchtimer_thread.h create mode 100644 templatefile.c create mode 100644 templatefile.h create mode 100644 timer_thread.c create mode 100644 timer_thread.h create mode 100644 timerdone.c create mode 100644 timerdone.h create mode 100644 uservars.c create mode 100644 uservars.h create mode 100644 varparser.c create mode 100644 varparser.h create mode 100644 vdr-epgsearch-0.9.24.beta9.tgz diff --git a/COPYING b/COPYING new file mode 100644 index 0000000..f90922e --- /dev/null +++ b/COPYING @@ -0,0 +1,340 @@ + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc. + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Lesser General Public License instead.) You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) year name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + , 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. diff --git a/HISTORY b/HISTORY new file mode 100644 index 0000000..32504f1 --- /dev/null +++ b/HISTORY @@ -0,0 +1,1089 @@ +VDR Plugin 'epgsearch' Revision History +--------------------------------------- +2007-xx-xx: Version 0.9.24 +new: +- new SVDRP command 'LSCC' that returns the results of a timer conflict + check. See the MANUAL for details about the format of the result list. +- the EPG command 'Search in recordings' now evaluates the info.vdr instead of the + recordings path name and also does fuzzy searching, suggested by Mase@vdrportal +- search timers with action 'switch only' and switch timers now have an additional + option 'unmute sound' which unmutes audio at the event, if it was off, suggested + by Michael Brückner +- speedup in searching and search timer updates (about 25%) +fixes: +- shifting the time display: the start time now only gets displayed in + 'Overview - Now' instead of a progressbar, if there's not already a start time + in the menu template ('%time%') as in the default template, + thanks to Getty@vdrportal for reporting +- fixed some issues regarding GPL, thanks to Thomas G�nther for reporting +- fixed a crash when no EPG is present, thanks to Petri Helin for providing a patch +- the default value for maximum duration is now '23:59' to avoid problems with + external tools, thanks to ralf-naujokat@bugtracker for reporting (bug-id #371) +- after an EPG change of less then 10 minutes epgsearch modified a timer instead of + creating a new one. This caused problems with events with less then 10 minutes. The + tolerance is therefore now min(, 10 min). Thanks to Janne Liimatainen + for reporting. +- fixed some translations, thanks to ramirez@vdrportal for reporting +- speed improvement when scrolling through EPG menus, thanks to ramirez@vdrportal for + reporting +- fixed a crash, when SIGINT is signaled while background threads startup +- channel group separators in 'Overview Now/Next/...' are now hidden if they are + empty like in ':@30', thanks to Ulf Kiener for providing a patch + +2007-09-02: Version 0.9.23 +new: +- full support for new i18n system in vdr>=1.5.7, but keeps fully backwards + compatible +- when using extended EPG categories one can now also compare by value, e.g. + to search for events after some year. + Therefore new searchmodes (10 which means '<', 11 which means '<=', ...) + were introduced in the file epgsearchcats.conf. Example: + + # 'until year' + 3|Year|until year||11 + # 'from year' + 12|Year|from year||13 + + One could use this also to search for a specific season of a series, if this + data is part of the EPG. See the section in the documentation + for a complete list of all search modes. +- The edit menu for search timers has now a switch 'Ignore missing categories' for + extended EPG categories. If set to 'Yes' this tells epgsearch that a missing EPG + category should not exclude an event from the results. Caution: Using this without + any other criterions could flood your timers. +- Search timers have now an 'auto delete' feature. The edit menu therefor provides: + * after x recordings, or + * after x days after first recording + Only complete recordings are counted. The deletion of the search timer is executed + directly after the end of the corresponding recording +- new action "Create a copy" in menu Search/Actions to create and edit a copy of the + current search, suggested by Michael Br�ckner. +- the option "use as search timer" has now a third value 'user defined' besides 'yes' + and 'no', that allows specifying a time margin where the search timer is active, + suggested by jo01@vdrportal +- the progressbar now displays the start time instead of an empty bar, when + shifting to future events, thanks to zulu@vdrportal for providing a patch. +- menu "show timers created" shows now summary for the timers done with 'Ok'. + Also the shortcuts '1..9' for the EPG-commands are available. +- built-in pin-plugin patch (no more need to patch epgsearch). Activate + it by compiling with 'USE_PINPLUGIN' in VDR's Make.config (as already done in + VDR extension patch) +- built-in graphtft-plugin patch (no more need to patch epgsearch). Activate + it by compiling with 'USE_GRAPHTFT' in VDR's Make.config (as already done in + VDR extension patch) +- update of finnish translation, thanks to Rolf Ahrenberg +- update of french translation, thanks to Patrice Staudt +- added file README.Translators with notes for translators +fixes: +- fixed a bug in timer creation after navigating through the summary menu, + thanks to Rolf Ahrenberg for reporting +- Label "Record" or "Timer" in menu summary fixed with respect to existing timer. +- fixed switch timers in the case when EPG has changed, thanks to Juergen Urban + for providing a patch +- fixed some compiler warnings in g++-4.2, thanks to Michael Br�ckner for reporting +- added "," to the allowed characters for a search timer, thanks to Mike Constabel for + reporting. + +2007-05-27: Version 0.9.22 +new: +- new option in timer conflict check "When a recording starts": + This performs a conflict check when any recording starts and informs + about it via OSD if the conflict is within the next 2h. So also timers not + created with epgsearch are checked, the same for instant recordings. +- new service interface "Epgsearch-services-v1.0": This allows other plugins + to access and manage many components of epgsearch as searchtimers, setup + values,... and execute tasks like searching for repeats (Have a look at + services.h for more information). +- new project homepage: http://winni.vdr-developer.org/epgsearch, many thanks + to Thomas Keil, sorry, only german at the moment ;) +- update for finnish translation, thanks to Rolf Ahrenberg +fixes: +- complete rewrite of the summary menu and its navigation to avoid problems + with skins and fix some other bugs. +- when testing for repeats now also the comparison with the done-file only + checks the alphanumeric portions of title and episode +- fixed another issue with quotes when calling commands for EPG events +- some license changes and additions for integration in Debian repositories +- fixed a bug in displayed time, when using user defined times and shifting + with FRew/FFwd, thanks to Torsten Weigelt for reporting +- the aux info about the channel was not added in 'one press timer creation'. + Thanks to Rolf Ahrenberg for providing a patch. + +2007-04-29: Version 0.9.21 +new: +- support for the new MainMenuHooksPatch. This replaces the + vdr-replace-schedulemenu patch. The new patch is used by other plugins too, + so from now on only one patch is needed. The old patch is still supported, + but this will be removed in the next releases. +- announcements of broadcasts via OSD have been completely redesigned. Instead + of displaying them event by event, you get now + "x new broadcast(s) found! Show them?". Pressing 'Ok' shows a menu of all + events with the usual functions as in other EPG menus. With "Edit" you can + modify the announce settings (like "announce again: yes/no" or announce again + after day x). +- timer conflict notifications via OSD can now be supressed while replaying. + Nevertheless, if a conflict comes up within the next 2 hours the message gets + still displayed. +- all addon plugins (epgsearchonly, quickepgsearch, conflictcheckonly) now + have a setup option to toggle the main menu entry on/off, thanks to Tobias + Grimm for providing a patch. +- channel name in aux info of manual timers, thanks to Rolf Ahrenberg for + providing a patch. +- new script undoneepgsearch.sh to undo a timer within the recordings menu, + more info at: + http://www.vdr-portal.de/board/thread.php?postid=574109#post574109 + Thanks to the author Christian Jacobsen +- update for french translation, thanks to Patrice + Staudt +- update for finnish translation, thanks to Rolf Ahrenberg +- menu 'timer conflicts details' now also shows the date of the conflict in + menu title, suggested by Rusk@vdrportal. +- the password for mail authentication is now hidden in the OSD, i.e. + represented with '***...' +- the setup for mail notifications now also has a "Send to" address, because + some providers don't allow the same address for sender and recipient. + If "Send to" is not set, epgsearch automatically uses the sender address as + recipient. +- when testing for repeats (with feature 'Avoid repeats') epgsearch now only + compares the alphanumeric portions of title and episode and ignores the case + too. Suggested by chello@vdrportal. +- thanks to Rolf Ahrenberg for finnish translation update +- added '&' to the set of valid chars for search terms +fixes: +- the tags stored in the aux info of the timers created with search timers + conform now to correct XML syntax (no capitals, no blanks). E.g. "Search timer" + will be changed to "searchtimer". So don't wonder if the first search timer + update will modify all existent timers created with search timers. Thanks to + Rolf Ahrenberg for reporting. +- update of recordingdone.sh because of the previous changes, thanks to + Mike Constabel for providing a patch +- fixed a segfault in the case of misconfigured extended EPG categories. +- scrolling text items now works again, if your skin supports this. + Thanks to ufauser@vdrportal for reporting. +- setup option "Use search timers" now always gets automatically enabled, if + one toggles a search to 'active' or manually starts a search timer update. +- fixed handling of double quotes in title/episode when passed to userdefined + EPG commands, thanks to Mike Constabel for reporting. +- fixed menu handling in search timer templates menu, thanks to wombel@vdrportal + for reporting. + +2007-01-30: Version 0.9.20 +new: +- support for vdr-1.5.0. Note: the CA support in the timer conflict check is + highly experimental because I have no CAMs to test it! +- epgsearch can now also modify manual timers according to EPG changes. When + using epgsearch's own timer edit menu you can select between + * no check + * by event ID + * by channel/time + Please refer to the README (1.4.4 Setup/Timer Programming/Default timer check + method) for further notes. +- the timespan used in the favorites menu can now be adjusted via + setup. Default is 24h. +- Event announcements: If the user presses one of the keys 'Ok', '0', ... '9' + while the announcement of an event is displayed, he will be asked if further + announcements of this event should be disabled for ever (user hit '0' or + 'Ok') or for the next 'x' days (user hit '1' to '9'). After pressing 'Ok' + again, this setting will be stored. +- With the new setup option "No announcements when replaying" you can now + suppress any announcements of broadcasts when you currently replay + anything. Suggested by Andreas Mair. +- Besides the done file for recordings there is now a done file for timers + (timersdone.conf). This allows deleting timers without getting them again + with the next search timer update. With the new menu 'Show timers created' + in Search/Actions one can edit this list. The whole feature can be disabled + in the search timers setup. Note: the done list is only populated with + timers that were newly created with this release. +- new addon plugin 'quickepgsearch': it creates a main menu entry 'Quick + search' and can be used to search for any event in the EPG. Include it with + '-Pquickepgsearch' , suggested by SurfaceCleanerZ@vdrportal. +- new setup option "Limit channels from 1 to" to speed up epgsearchs call. If + the current channel is above the limit, all channels will be + displayed. Suggested by Uwe@vdrportal. +- new SVDRP commands: + * 'LSRD' returns a list of all recording directories used + in existing recordings, timers, search timers or as specified in + epgsearchdirs.conf + * 'LSTT [ID]' to list all search templates, or the one with the passed ID + (format is the same as epgsearch.conf) + * 'NEWT ' to add a new search template + REMARK: the value of element ID is ignored. epgsearch will always + assign the next free ID + * 'DELT ' to delete the search template with ID + * 'EDIT ' to modify an existing search template + * 'DEFT [ID]' returns the ID of the default search template. When passing an + ID it activates the corresponding template as default. +- modified SVDRP commands: + * 'DELS [ID] [DELT]' now also deletes created timers for search with ID when + passing the optional 'DELT'. +- you can now also use sendmail for mail delivery besides the script + sendemail.pl (-> setup), suggested by Patrick Cernko +- new variables: + * '%timespan%' to be used in menus or mails. It will be replaced + with the timespan from now to the begin of an event (e.g. 'in 15m'). It is + now used in the default menu template of the favorites menu, where the date + field was removed. + * '%length%' for the length of a broadcast in seconds. +- thanks to Rolf Ahrenberg for finnish translation update +fixes: +- manually created timers are now neither deleted nor modified by any search + timers. +- the addon conflictcheckonly was compiled even if WITHOUT_CONFLICTCHECKONLY + was defined in the Makefile, thanks to Ronny Kornexl for reporting. +- search term and directory support now the characters '�' (only for language + german) and '@'. +- 'avoid repeats' had a bug (in some special cases) that created a timer for any + later repeat instead of the first event. +- a search with "Use day of week" AND "Use time" where "Start before" is after + midnight now also matches events on the next day til "Start + before". E.g. "Start after 22:00" and "Start before 03:00" on monday will + also match an event at 01:00 at tuesday. +- already recording timers are now modified only, if the timers stop time has + changed (e.g. by an EPG update), thanks to Mike Constabel for reporting. +- fixed a bug in evaluation of user variables, thanks to Mike Constabel for + reporting and remote debugging +- fixed a bug in conflict mail notification concerning timers without assigned + events + +2006-10-27: Version 0.9.19 +new: +- if search results of different searches intersect, now only the search that + initially created a corresponding timer may modify it. +- new variables: + * '%search.query%' to be used in the recording directory of a search + timer. Will be substituted to the query of a search timer. + * '%videodir%' VDR video directory (e.g. /video) + * '%plugconfdir%' VDR plugin config directory (e.g. /etc/vdr/plugins) + * '%epgsearchdir%' epgsearchs config directory + (e.g. /etc/vdr/plugins/epgsearch) +- the syntax of the 'system' command within a user variable has changed to be + more flexible. It's now: + %uservar%=system(/path/to/script[, parameters]) + where the optional 'parameters' can now be any expression using other + variables except directly using conditional expressions or other system + calls. +- update for french translation, thanks to Patrice Staudt +fixes: +- VPS timers created by search timers are now always updated to their VPS time, + even if the user has changed start/stop time. +- after editing the setup any menu templates defined in epgsearchmenu.conf + were reset to defaults, thanks to s.krueger@vdrportal for reporting. +- existing VDR serial timers are not modified anymore to regular timers by the + search timer update. + +2006-10-01: Version 0.9.18 +new: +- IMPORTANT!!! PLEASE READ THIS!: epgsearch expects it's conf files now in a + separate configuration directory 'epgsearch' and not in the general plugin + configuration directory as with previous versions! Please create this + directory in your plugins configuration directory and move all + epgsearch-files to it before running this version. Like this: + + mkdir /etc/vdr/plugins/epgsearch + mv /etc/vdr/plugins/epgsearch*.* /etc/vdr/plugins/epgsearch + mv /etc/vdr/plugins/.epgsearch* /etc/vdr/plugins/epgsearch + + This is only important if you don't already use epgsearchs '--config' or + '-c' parameter. + +- new 'Favorites menu' besides 'Now' and 'Next': This menu can show a list of + all your favorite broadcasts for the next 24h. To enable it activate 'Show + favorites menu' in the setup. To let epgsearch know what your favorites are + create/edit some searches and enable 'Use in favorites menu'. +- new setup option for timer conflict check: 'After each timer + programming'. This performs a conflict check after each manual timer + programming and - if the new/modified timer is involved in a conflict - pops + up an OSD message about it. +- new email notifications about search timer updates or timer + conflicts with a customizable mail content. Please refer to the MANUAL + section 'Email notification' for further details. +- epgsearch has now a set of man pages. A very BIG thanks to Mike Constabel + (vejoun@vdrportal) who did the complete job of rewriting/correcting and + formatting the current docs. The man pages cover the README's, MANUAL and a + documentation of all conf's that epgsearch uses. Available for german and + english. Install them with 'make install-doc' in epgsearch's src-directory. +- you can now define your own variables to be used in the default recordings + directory, search timer recording directory or your own menu + templates. Since this is quite complex please refer to the MANUAL section + 'User defined variables'. Just an example to see what is possible: + # Weekday, Date, Time + %DateStr%=%time_w% %date% %time% + # Themes or Subtitle or Date + %ThemesSubtitleDate1%=%Subtitle% ? %Subtitle% : %DateStr% + %ThemesSubtitleDate%=%Themes% ? %Themes% : %ThemesSubtitleDate1% + # Calls this script to get a recording path + %DocuScript%=system(doku.pl,%Title%,%Subtitle%,%Episode%,%Themes%,%Category%,%Genre%) + %Docu%=%DocuScript% +- key 'Ok' can now also be configured to switch to a channel instead of + displaying the summary, suggested by malachay@vdrportal. +- if a timer was created by a search timer then epgsearch's own timer edit + menu now displays the name of the search timer in a non selectable item at + the bottom of the menu. +- when an event is announced via search timers you can now create a timer for + it, when you press the red key while the announce is visible, suggested by + Andreas Mair +- if search timers are disabled by setup then creating/editing a search timer + now automatically activates them in setup, suggested by Andreas Mair. +- you can now use more than one menu template for search results, please refer + to the MANUAL section "Customizing the EPG menus". +- the check for a complete recording now also accepts short breaks (< 2s, + e.g. a channel pid change) +- new SVDRP commands: + * LSTC [channel group name] + list all channel groups or if given the one with name 'group name' + * NEWC + create a new channel group, format as in epgsearchchangrps.conf + * EDIC + modify an existing channel group, format as in epgsearchchangrps.conf + * DELC + delete an existing channel group + * RENC + rename an existing channel group + * 'LSTB [ID]' to list all blacklists, or the one with the passed ID + (format is the same as epgsearchblacklists.conf, see MANUAL) + * 'NEWB ' to add a new blacklist + REMARK: the value of element ID is ignored. epgsearch will always + assign the next free ID + * 'DELB ' to delete the blacklist with ID + * 'EDIB ' to modify an existing blacklist + * 'QRYS < ID(s) >' to get the results for a search with the given + ID. Multiple IDs can also be passed and have to be separated with '|'. + * 'QRYS ' to get the results for a search with the given + search settings. + * 'QRYF [hours]' to get the results for the favorites menu. The optional + parameter specifies the number of hours to evaluate and defaults to 24h. + * 'LSTE [ID] to get the extended EPG categories defined in epgsearchcats.conf + or the one with the given ID. + * 'MODS ID ON|OFF' turns on/off the option 'Use as search timer'. + * 'SETP option' returns the current value of the setup option (see MANUAL). +- epgsearch has now a bug tracking system (german) and a mailing list + (english) + http://www.vdr-developer.org/mantisbt + http://www.vdr-developer.org/mailman/listinfo/epgsearch + thanks to the providers of developer.org +- new service interface "Epgsearch-switchtimer-v1.0" to access and manage + switch timers, thanks to Dirk Leber for his extension. +- update for french translation (including setup help!), thanks to Patrice + Staudt +- thanks to Rolf Ahrenberg for finnish translation update +- thanks to Mike Constabel for providing a HTML update mail template + (conf/epgsearchupdmail-html.templ) +fixes: +- the first day of a repeating timer is now taken into consideration in the + timer conflict check, thanks to zimuland@vdrportal for reporting +- fixed search timer update for VPS timers, thanks to Chello and + oholler@vdrportal for reporting. +- fixed handling of the sign '|' when changing the search type of a search + timer, thanks to Chello@vdrportal for reporting +- changed some default search mode values in the epgsearchcats.conf samples for + multiple selection +- removed extra line feeds in SVDRP response of LSTS, thanks to Andreas Mair + for reporting +- channel criterion 'no pay tv' in search timers was ignored, thanks to + Andreas Mair for reporting +- fixed initial min/max values for search criterion 'duration', thanks to + Mike Constabel for reporting +- fixed a bug when selecting the conflict check 'after each search timer + update' in setup, thanks to Ronny Kornexl for reporting +- some changes for thread safeness +- added '--remove-destination' to the Makefile as introduced in vdr-1.4.2-3 + +2006-08-07: Version 0.9.17d (maintenance release) +fixes: +- fixed a wrong usage of 'cPlugin::ConfigDirectory' in search timer thread, + thanks to Udo Richter and Petri Hintukainen for reporting + +2006-06-12: Version 0.9.17c +fixes: +- fixed a problem with multiple selection of extended epg category values, + thanks to Christian Jacobsen for reporting +- another compilation fix for linvdr, thanks to toxic-tonic@vdrportal + +2006-06-10: Version 0.9.17b +fixes: +- fixed some problems with repeating timers in timer conflict check, thanks to + Peter Juenger for reporting +- fixed a crash in timer conflict check when there was an active recording on + a device provided by a plugin (e.g. pvr, streamdev), thanks to Gerhard + Steiner for reporting. + +2006-06-06: Version 0.9.17a +fixes: +- menu 'timer conflicts' automatically returned if there where periodic + timers, thanks to lostinspc@vdrportal +- fixed some compiling problems with gcc-2.95 and gcc-4.1.0, thanks to + ferdi03@vdrportal, smudo81@vdrportal, toxic-tonic@vdrportal + +2006-06-05: Version 0.9.17 +- dropped support for vdr < 1.3.46 :-( +- changed logic in jumping through menus with user-defined times: you can now + also access times on next day, if they are less then 20 hours in the + future. Thanks to egal@vdrportal and CKone@vdrportal. +- epgsearch has now its own timer conflict check which can be customized by + setup regarding relevant priorities, the time span to check or the relevant + conflict duration. There is also a conflict manager in Search/Actions that + can be used to resolve conflicts. Many thanks to Mike Constabel for heavy + testing ;-) +- if there is a timer conflicts notification via OSD, you can now press 'Ok' to + go directly to the timer conflicts overview. +- if you like to have a separate main menu entry for the timer conflict check + use '-P conflictcheckonly' which comes as 'mini'-plugin with epgsearch and + simply calls epgsearch's conflict menu. conflictcheckonly has a setup option + to display an info about the last conflict check directly in its main menu + entry. +- setup is now completely restructured and has now something like an 'online' + help. +- menu 'switch timers' now also displays the channel number +- input logic for extended EPG categories changed to allow multiple values. +- added script 'timercmds-auxinfo.sh' that displays the aux info (e.g. the + search timer responsible for the timer) in VDR's timer menu (requires the + timercmd patch), thanks to the author Mike Constabel +- user-defined EPG times with empty description get now their associated time + as description, suggested by Thiemo Gehrke +- new service interface "Epgsearch-conflictmenu-v1.0" to call epgsearch's + conflict menu from other plugins. +- new service interface "Epgsearch-lastconflictinfo-v1.0" to get an info about + the last conflict check result. +- epgsearchmenu.conf is not more reloaded with every plugin call, since this is + only useful when testing the conf file. To activate the permanent + reload again, pass the new start parameter '-r' or '--reloadmenuconf' in + your runvdr +- thanks to Rolf Ahrenberg for finnish translation update +- added HISTORY.DE (german HISTORY) +fixes: +- loading epgsearchmenu.conf now falls back to menu defaults, if the conf file + contains any errors. +- fixed handling of '%' in LSTS in SVDRP for vdr > 1.3.44, thanks to Mike + Constabel +- fixed loading epgsearchmenu.conf for epgsearchonly and service interface + "Epgsearch-searchmenu-v1.0", thanks to Daniel Dorau for reporting. +- fixed display update in menu 'Search templates', thanks to Mike Constabel +- fixed a bug when deleting associated timers of a search timer when there + are no timers present, thanks to Patrick Koppen for reporting. +- hopefully fixed a bug when adding a search entry to templates, thanks to + Patrick Koppen for reporting. + +2006-04-18: Version 0.9.16 (maintenance release) +fixes: +- the display of 'Overview - Now' was broken, when using progressbar and + channel numbers in default menu look. Thanks to Gerhard Steiner for + reporting this one. +- when using small OSD fonts, the progressbars where flickering because of 1 + pixel line height. Thanks to holymoly and TomG@vdrportal. +- support for the APIVERSION define as introduced in vdr-1.3.47 + +2006-04-14: Version 0.9.15 +new: +- the EPG menus can now be customized with the file epgsearchmenu.conf (sample + file in 'conf' subdirectory), e.g. the entry: + MenuWhatsOnNow=%chnr%:3|%progrt2s%:5| %time% %t_status%:8|%category%:6| %title% ~ %subtitle%:35 + creates a menu line starting with the channel number, followed by a progress + bar in text2skin style, the start time, the timer status, the EPG category + (like "movie") and finally the title and subtitle. + You can customize each menu ('What's on now, next, other times, schedule and + search results with a separate line). Please refer to the MANUAL for more + information. +- IMPORTANT change to search timers: epgsearch now removes timers, that are + not needed anymore (if vdr >= 1.3.44). These are: + * timers, that are no more valid because of EPG changes. This should avoid + the double recordings after an EPG change. + * timers, that do not match the search criterions after a change of the + search timer. So you don't have to remove them manually anymore. + If the user has modified start or stop of such a timer, it will be kept. +- new search mode 'fuzzy' in searches. This performs a fuzzy search + applying an algorithm like it's used in agrep. The error tolerance can be + set with the edit field 'Tolerance'. +- added the 'one press' timer creation feature in EPG menus as introduced in + vdr-1.3.38 with one small difference: If the event is already running or + about to start within MarginStart + 2 minutes, the timer edit menu will be + popup to allow editing the file/directory entry, because this cannot be + changed when the recording immediatly starts. Else, the timer is created + immediately. Can be turned off in setup. +- with the red button in epgsearch's own timer edit menu one can now delete an + existing timer, suggested by Rolf Ahrenberg. +- if the main menu entry is not hidden, it's name can now be set by setup. + (Note: when changing the name to something different than the default, it is + no more dependent on the OSD language) +- changed the default main menu entry from 'Search' to 'Program guide' +- some people requested a separate main menu entry for epgsearch's search + menu. Therefore I've added a little plugin called 'epgsearchonly' that + simply calls epgsearch's search menu. It's main menu entry is + 'Search'. Compilation of epgsearchonly is automatically done, but can be + switched off in the Makefile when uncommenting the line + #WITHOUT_EPGSEARCHONLY=1. To use it simply put '-P epgsearchonly' to your + VDR start script. (requires >= vdr-1.3.30) +- new service interface "Epgsearch-searchmenu-v1.0" to call epgsearch's search + menu from other plugins. +- new action 'Delete created timers?' for search entries to delete all timers + created from the current search timer. Does not affect recording timers. +- When deleting a search, you can now decide if all timers created from this + search should also be deleted. +- If the user modifies the start/stop time of a timer created by epgsearch + this timer will not be changed anymore(only vdr >= 1.3.44 ) +- If an event is currently recorded, the status flag in the EPG menus is now + 'R' instead of 'T' +- Support for wareagle-icon-patch (activate it by adding the line + 'WarEagleIcons=1' to epgsearchmenu.conf) +- Progressbar in Now/Next beautified when using setup option 'graphical', + inspired by Nordlichts-EPG-Plugin +- new setup option to show/hide radio channels in the EPG menus, suggested by + Patrice Staudt. +- new service interface "Epgsearch-searchresults-v1.0", that returns a result + list of events matching a given search, suggested by Andreas Brugger +- removed some special setup options, because their function can also be + realized with a customized menu now: + * "show progress bar in 'Next'", in default menu now off + * "display width for progressbar", in default menu now 4 + * "show short channel name", in default now always short + * "Show episode text in schedules", now always displayed +- update for finnish translation, thanks to Rolf Ahrenberg +- aux field is now formatted in full XML style (if vdr >= 1.3.44). As a result + of this, an updated recordingdone.sh is provided in the 'scripts' + subdirectory. Thanks to Mike Constabel for providing a patch. +- search timer update now always runs in low priority, suggested by Christian + Jacobsen +- new SVDRP command 'FIND'. This allows searching an event and returns a list + of results consisting of 'NEWT' lines, that can be used to immediately + create a timer for a result. Suggested by Lari Tuononen +fixes: +- thanks to Darren Salt for patches for g++ 4.1 and some things concerning + thread safeness and code review +- fixed some memory leaks +- fixed calling user defined EPG commands, thanks to rzndl@vdrportal +- fixed blacklist match for search timers, thanks to Christian Jacobsen +- make sure that the episode name of a timer is less then + MAX_SUBTITLE_LENGTH, thanks to Mike Constabel +- speedup for search timer update + +2006-03-05: Version 0.9.14a +fixes: +- EPG command 'mark as already recorded' crashed, thanks to Mike Constabel for + reporting this + +2006-03-04: Version 0.9.14 +new: +- when disabling/enabling a search timer you can now decide if the associated + timers should also be disabled/enabled. +- new built-in EPG command 'Create blacklist' to create a blacklist from any + EPG menu. +- the summary of an entry in the menu 'recordings done' has now an additional + button 'Aux info', that displays the content of the aux field. +- update for the script recordingdone.sh to work also with vdr-1.3.44, thanks + to Mike Constabel for his changes. +- conversion scripts for upgrade to vdr-1.3.44: Because of the different + handling of auxiliary info (summary -> aux) some features of epgsearch won't + work with recordings made before vdr-1.3.44. This applies to the + done-Feature and to the automatic deletion of recordings. Without using + these scripts you will simply have some more recordings. So you actually + don't have to apply them, but when using them, all works fine. Thanks to + Mike Constable for providing them. + * new script convert_info_vdr.pl. This converts the info file of recordings + made before vdr-1.3.44 and moves epgsearch aux data to the new aux field. + * new script convert_epgsearchdone_data.pl. This converts the + epgsearchdone.data file adding an 'aux' section to it. +- update for script mtdone2epgsearchdone.sh, thanks to Christian Jacobsen +- update for french translation, thanks to Patrice Staudt +- update for finnish translation, thanks to Rolf Ahrenberg +fixes: +- done-feature was broken with vdr-1.3.44, thanks to Mike Constabel for + reporting this +- another fix of high cpu load in search timer thread, thanks to + sledgehammer@vdrportal for reporting this +- automatic linking after extracting the tarball removed again, requested by + distribution maintainers. +- fixed some compiler warnings when using -Wformat=2, thanks to Darren Salt for + reporting and providing a patch + +2006-02-28: Version 0.9.13 +new: +- support for vdr-1.3.44: works now, but: because of the summary/aux changes + in vdr-1.3.44 the additional info about the search timer, that triggered a + timer/recording, or the recording channel is currently not available. This + info is now stored in the new aux field of timers/recordings. +- blacklists: you can now maintain one or more blacklists and select them + within a search or search timer. A blacklist works like a normal + search and defines events that should be ignored in a search or search + timer. Blacklists can be managed from setup or with the new search action + 'Show blacklists' or directly when editing a search. Within a search you can + select one or more or all blacklists. If any search result is also contained + in a black list result set it will be skipped. +- the switchtimer background thread is now only active, while there are any + active switch timers. +- when you unpack the tar file, the necessary link is now automatically + created (like text2skin) +- the result list of repeats of an event now omits the currently running + event, suggested by Ronny Kornexl +- thanks for beta testing to Mike Constabel +- update for finnish translation, thanks to Rolf Ahrenberg +fixes: +- the setup option 'Add episode to manual timers' was not stored + +2006-02-12: Version 0.9.12 +new: +- new feature 'pause when ... recordings exist" for search timers. If + the given number (>0) of recordings exist, then the search timer + will not create further timers. After deleting one or more + recordings new timers are generated again. +fixes: +- fixed a crash when surfing to a channel without epg in schedule + menu + +2006-02-08: Version 0.9.11a +fixes: +- high cpu load fixed + + +2006-02-07: Version 0.9.11 +new: +- support for vdr-1.3.42 +- new feature switch timers: add an event with the new epg command + 'Add to switch list' to the switch list and epgsearch will switch + the channel one minute before the event starts. The current content + of the switch list can be controlled within the search menu with the + new action 'Show switch list'. If there is a switch timer for an + event its menu item is labeled with 'S', if there is no real timer. +- switch timers also for search timers: a search timer can now be + configured to 'switch only'. Its search results are then added to + the switch list and epgsearch will switch to the found events one + minute before they start. There will be no real timer for such a + search timer. +- search criterion 'Use channel' has now an additional value 'only + FTA' to search in non encrypted channels only +- new setup option 'Show day separators' for menu 'Schedule', that + displays an additional line at day break. +- epgsearch has now a SVDRP interface with the following commands + (requires vdr > 1.3.30): + * 'LSTS [ID]' to list all searches, or the one with the passed ID + (format is the same as epgsearch.conf, see MANUAL) + * 'NEWS ' to add a new search + REMARK: the value of element ID is ignored. epgsearch will always + assign the next free ID + * 'DELS ' to delete the search with ID + * 'EDIS ' to modify an existing search + * 'UPDS [OSD]' to update the search timers. Passing the optional keyword + 'OSD' pops up an OSD message after the update has finished. + * 'UPDD' to reload the file epgsearchdone.data, e.g. after an + external tool has modified it. + * 'SETS ' to activate or cancel the search timer background + thread. +- since setup gets too big it has now the modes 'Standard' and + 'Extended'(toggled with key 'red'), suggested by Rolf Ahrenberg +- update for finnish translation, thanks to Rolf Ahrenberg +- update for italian translation, thanks to reelbox users +- update for french translation, thanks to Patrice Staudt +- new dutch translation, thanks to reelbox users +- using 127.0.0.1 instead of resolving 'localhost' for SVDRP, + suggested by Thiemo Gehrke +- added script recordingdone.sh for your reccmds.conf to add a + recording to epgsearch's done file, thanks to Patrice Staudt, + Christian Jacobsen and Mike Constabel +- added script mtdone2epgsearchdone.sh to move recordings from + mastertimer's done file to epgsearch's done file, thanks to + Christian Jacobsen. +- thanks to Mike Constabel and Andreas Brugger for testing and bug + reports +fixes: +- fixed a bug after using templates, thanks to Christian Jacobsen + + +2006-01-15: Version 0.9.10 +new: +- update of all schedule and search result menus after + creating/changing a timer, as introduced in vdr-1.3.38 +- button 'Record' now labeled with 'Record' or 'Timer' depending on + existing timer for the event, as introduced in vdr-1.3.38 +- epgsearch's own timer edit menu now displays the recording device + number for a currently recording timer +- new setup option: 'Add episode to manual timers' + affects adding the subtitle to the timer file in manual timer + programming. The setting 'smart' skips the subtitle if the event has + more that 80 min. +- search edit menu for search timers changed for future extensions: + 'Action' now selects the job to do for the search results, currently + 'record' (default) or 'announce only' +- thanks to Rolf Ahrenberg for finnish translation update +fixes: +- in vdr-1.3.38 some translations were broken +- updated the timercmds-patches to work with vdr-1.3.38 + +2006-01-08: Version 0.9.9 +new: +- support for vdr-1.3.38 +- search templates: the settings of a search are often quite the same + as already done with other searches. You can now create templates + that can be selected when editing a search (with key blue). A + template can also be set as default. A new search will then get the + default settings automatically. +- extended setup with 'search templates' to manage the new templates +- new action 'Use as template' to copy a search to the templates +- setup option to display the subtitle in the schedules, thanks to + Darren Salt for his patch +- extension of feature 'Delete recordings after ... days' with 'Keep + ... recordings'. This will asure, that last x recordings will not be + deleted, even if they are expired. +fixes: +- the search timer feature 'Delete recordings after + ... days' also deleted recordings that were edited. fixed now. + +2005-11-27: Version 0.9.8 +new: +ATTENTION: this version converts epgsearch.conf (the file that stores + the searches) to a NEW FORMAT. A backup of the old file is stored as + epgsearch.conf.bak. If you switch back to an older version you have + to move the backup file back to epgsearch.conf. +- new feature 'avoid repeats' for search timers, aka 'done' + feature (please read the README before using it!). A special thanks + to Mike Constabel (vejoun@vdrportal) for many hours of testing and + bug reports. + * timer preview + * recognition of broken recordings + * fuzzy event comparision +- the menu of search results for a search timer with 'avoid repeats' + has an additional mode for key 'blue' to preview the timers, that + will be programmed with it. +- new setup option to display channels without EPG in 'What's on...', + idea from 'Nordlicht's EPG plugin' +- new setup option to show channel separators in 'What's on...', + idea from 'Nordlicht's EPG plugin' +- new feature 'Delete recordings after ... days'. This removes a + recording automatically after the given days. It's a nice thing for + e.g. news recordings (like Tagesschau), that are only interesting for + a few days +- the timer summary now contains additional information about the + event: event title, subtitle (if present) at the top, the name and + ID of the search timer, that triggered the timer, and also the + recording channel (after the real summary) at the bottom +- the summary of timers that are manually programmed now also contains + info about title, subtitle (if present) and the recording channel +- 'Execute' in searches menu has been replaced with 'Actions' that + list a menu consisting of + * Execute search + * Use as search timer on/off + * Trigger search timer update + * Show recordings done + You can also use the short keys to trigger the corresponding action + without opening this menu +- introduced a logfile (default file is + plugin-configdir/epgsearch.log, but can be specified with + commandline option '-l /path/to/logfile'. Commandline option '-v n' + specifies the verbose level of the logfile. n=0 means no logging, + allowed values are n=0(default),1(standard),2(extended),3(for + debug). +- setup has now a default recording directory entry, that is used in + manual timer programming. It supports also entries like + '%Category%~%Genre%'. The directory gets automatically replaced with + the values of the event (but only if all variables were replaced). +- depending on the calling menu the event menu (summary) now labels + the buttons green/yellow with the previous/next channel or the start + of the previous/next event, suggested by Andreas Brugger +- the channel number is now also listed in menu 'search results', if + the setup option 'show channel numbers' is set, suggested by Gerhard + Steiner. +- short keys (1,2,...) to EPG commands are now also availabe in the + EPG summary menu, suggested by Frank Kr�mmelbein +- if VDR version >= 1.3.31 then setup has now an option to choose + between epgsearch's timer edit menu and VDR's built-in menu (useful + when using a patched VDR timer edit menu, suggested by Frank + Kr�mmelbein) +- if a subtitle is present the menu for manual timer programming now + always adds the subtitle to the timer file as default, suggested by + Gerhard Steiner +- optimized the splitting of the directory and file entry when + re-editing a timer in manual programming, thanks to Andreas Brugger +- the EPG menus now always display a subtitle in the form 'title ~ + subtitle' if present +- new service 'Epgsearch-updatesearchtimers-v1.0' to trigger a search + timer update +- if a search timer update is triggered from the actions menu then an + osd message is displayed when it has finished (also when using the + service 'Epgsearch-updatesearchtimers-v1.0' optional) +- the menu of search timers now displays the number of (active) + searchtimers in its title +- now checking if manual timer programming has failed and display an osd + message in that case (needs vdr >= 1.3.30 to work) +- thanks to Rolf Ahrenberg for updating the finnish translation +- thanks to Mike Constabel for corrections in READMEs and MANUAL +fixes: +- epgsearch now exits to main menu when not called directly via a + short key, thanks to Andreas Brugger +- fixed editing menu search term in english translation +- fixed sorting search timer list after editing a search timer, thanks + to Mike Constabel +- fixed menu navigation with respect to empty schedules, thanks to + Darren Salt for his patch +- fixed misaligned search entries in searches menu, thanks to Andreas + Brugger + +2005-09-04: Version 0.9.7 +new: +- changes in the events summary now also trigger a timer update +fixes: +- fixed a memory leak in search timers with regular expressions, + thanks to TomG@vdrportal +- fixed channel name display in color buttons when a channel separator + exists, thanks to viking@vdrportal + + +2005-08-27: Version 0.9.6 + +new: +- search criterion 'use channel' extended by 'channel groups'. Channel + groups can be managed with their own menu and allow a much more + flexible way to select channels for the search procedure. +- epgsearch now exposes its extended timer edit menu and searching the + epg as services to other plugins (s. MANUAL or contact me, if you + are interested) +- if a timer is programmed for an event (searchtimer or manual + programming) then the summary is now also passed to the timer (allows + displaying the summary pressing 'ok' in timer menu), thanks to + TomG@vdrportal +- after toggling the color buttons with '0' in the schedule menu the + yellow/green button now move to the schedule of the + previous/next channel +- added a patch from Uwe/egal@vdrportal that replaces vdr's + standard schedule menu with the epgsearch plugin. Also big thanks to + Uwe for the changes in epgsearch. After patching VDR you have to + activate the patch in epgsearch's setup. +- after editing a new search, its entry now gets correctly sorted in + the list of all searches, thanks to Mike Constabel +- added Gerhard Steiner's timercmd patch for vdr >= 1.3.25 +- a 'back' in the start menu now always closes the osd (should solve + some trouble with the submenu patch) +- events without title are now ignored, regardless of the search + criteria, thanks to Mike Constabel +- new EPG variable '%channel%', that can be used in directory entries + and gets replaced with the channels name +- recording margins in search timers can now be negative (allows + intentional cutting the begin/end of recording), suggested by Mike + Constabel +- extended EPG categories are now compared case insensitive +- updated finnish translation, thanks to Rolf Ahrenberg + +fixes: +- '.epgsearchrc' now too is expected in the config path specified + with -c (if given), thanks to Ronny Kornexl +- fixed programming of timers with empty file and directory, thanks to + Andreas Brugger +- fixed search timer programming in case of midnight between start and + stop time +- fixed directory selection when listing of dirs is empty, thanks to + harvey@vdrportal +- (de)activating a searchtimer with '0' did not store, thanks to Mike + Constabel +- fixed menu navigation (green-yellow-yellow-green displayed the + summary instead of 'whats on now'), thanks to Mike Constabel + + +2005-07-02: Version 0.9.5 +- epgsearch has now its own menu for standard timer editing with the + following extensions (timer programming is based on SVDRP, so this should + be configured!): + * additional item 'directory' with selection of existing + directories with key 'blue' (also supports EPG + variables like "%category%" when using ext. EPG info) + * item 'file' can be extended with subtitle (if present) pressing + key 'blue' + * item 'file' and 'directory' can be reset to standard pressing key + 'yellow' + * when editing weekdays then item 'day' can be customized with a submenu + for arbitrary weekdays selection +- menu 'userdefined days of week' for search timers now starts with + 'Monday' instead of 'Sunday' +- menu 'Select directory' now lists distinct items of the following sources: + * current recording directories + * current timer directories + * directories used in search timers + * directories specified in epgsearchdirs.conf + key 'yellow' can be used to change the depth of the directory listing. +- Progressbar in 'Next' can now be switched on/off with its own setup item. +- support for language dependent commands for EPG (default loading + uses epgsearchcmds.conf, if there is no epgsearchcmds-XXX.conf, + where XXX is the language code as shown in i18n.c, see MANUAL) +- directly calling a command with key '1'..'9' will now go back to the + calling menu after execution instead of displaying menu 'commands' +- added a commandline option '-c' or '--config' to specify the plugins + own config directory (option). +- added commandline help for 'vdr --help +- thanks again to Mike Constabel (vejoun@vdrportal) for great beta + testing and suggestions, and to Rolf Ahrenberg for finnish translation. + + +2005-05-24: Version 0.9.4 +- support for extended EPG info (categories) in search timers (please + refer to the README 'Using extended EPG info'). +- added a submenu to select an existing directory when editing a + search timer. This menu can also be extended with entries in the file + epgsearchdirs.conf +- usage of variables like "%Genre%" or "%Category% in the directory + entry of a search timer. These are replaced with the current extended + EPG info when a timer is created. +- key '0' in search menu now toggles the flag 'use as search timer' +- fixed compilation for vdr < 1.3.18 (thanks to TomG@vdrportal) +- updated script rememberevent.sh (thanks to Ronny Kornexl for + complete rewrite and extensions) +- added script epg2master-timer.sh for the commands menu, that adds an event to + master-timer, thanks to the author Christian Jacobsen / Viking (vdrportal) +- some changes to compile with bigpatch +- removed font patch for progressbar, since runtime patch seems to + work fine +- added a script timerrep.sh to search the repeats of a timer from timer menu + (requires the timercmds.conf-patch from Gerhard Steiner, see dir patches) +- updated/rearranged README(.DE) and added also a MANUAL (only english) for + detailed info about some topics, since README gets too big. +- Added a description of the format of epgsearch.conf to MANUAL +- fixed a bug with buttons display in search timer edit menu +- a special thanks to Mike Constabel (vejoun@vdrportal) for great beta + testing and suggestions, and to Rolf Ahrenberg for finnish translation. + +2005-04-14: Version 0.9.3 +- implemented direct SVDRP communication (no more need for + svdrpsend.pl. For now, the old external method can still be used when you pass + it with -f as parameter, if you omit -f the internal method is used) +- added buttons '<<' and '>>' in detailed epg view (summary) to jump + to the previous/next event of the menu behind (schedule, now, next, + ..., search results) +- new feature to use epgsearch for searching from other plugins + or scripts (see the README 'Usage from other plugins or scripts') +- shifting displayed time with FF, FR or by toggling with '0' is now + also available in schedule menu +- added a setup option to set a default for handling pay tv channels + when searching (does not affect search timers) +- fixed day check in searchtimer scan with respect to changes in + vdr-1.3.23 +- changed detection of existing timers to reduce superfluous timer + modifications. +- added channel name and subtitle to parameters for custom commands +- small change in input logic of 'from channel' when editing a search entry +- updated screen shots on project homepage + +2005-03-20: Version 0.9.2 +- update for vdr-1.3.23 + +2005-03-19: Version 0.9.1 +- french translation update, thanks to Patrice Staudt +- fixed a problem with priority and lifetime when modifying a + timer + +2005-03-19: Version 0.9.0 +- new search mode 'regular expressions' (POSIX(default) or Perl compatible by + compiler switch HAVE_PCREPOSIX in the Makefile, see README - Installation) +- new search mode 'match exactly' to simplify matching of short search terms +- new option for search timers: 'only annouce' will not add a timer, + but display an OSD message about the found event +- new progressbar in 'what's on next', that displays the time span to + the next event (0 minutes(=100%) to max. 30 minutes(=0%)) +- timer conficts can now be checked in the background and are + displayed via OSD after each search timer scan (requires a recent + timeline plugin running) +- key blue in search results now toggles between "only FTA" and "all + channels" (to hide results from pay tv channels) +- removed some superfluous search timer modifications +- finnish translation, thanks to Rolf Ahrenberg +- updated README and added a description of the search process +- shifted version number to allow subversions + +2005-02-15: Version 0.0.8 +- added support for VPS in search timers +- channels of search timers are now stored with ID rather than number + (avoids editing your searches after channel modifications) +- corrections in the english version, thanks to Darren Salt +- fixed a bug in criterion duration +- fixed channel selection when shifting displayed time, thanks to + Ronny Kornexl +- put some space between progressbar and event info (TtV*) for text2skin 1.0 +- fixed compilaton problems in vdr-1.3.10 +- switch display in search results to 'episode name only' with key + yellow +- fixed width of start time, when displaying channel number, thanks to + Gerhard Steiner + +2005-01-22: Version 0.0.7 +- Start menu can now be setup between 'schedule' and 'now' +- runtime patch for progressbar (no need to patch vdr anymore, experimental) +- Added lifetime, priority and margins for start and stop for + searchtimers +- Added new font-patch for vdr-1.3.18 +- new: italian translation, thanks to Sean Carlos +- french translation, thanks to Patrice Staudt +- finnish translation by Rolf Ahrenberg +- search term can now be empty to search for anything, that matches + other criterions searchtimers +- Fixed editing of criterion 'to channel', thanks to gunnar@vdrportal + +2005-01-11: Version 0.0.6 +- now compiles also with vdr-1.3.18 +- Search criterion 'channel' can now be a range of channels (thanks to + gunnar@vdrportal) +- Setup option 'short channel names' for display in 'now', + 'next',... (only available for >= vdr-1.3.15, thanks to dido@vdrportal) +- french translation, thanks to Patrice Staudt +- added external trigger to force a search scan (e.g. at shutdown, + thanks to Ronny Kornexl) +- fixed display of color keys while editing search term and directory + (thanks to Ronny Kornexl) +- recordings found with 'search in recordings' can now be replayed + from result list +- fixed menu switching now-program-now (thanks to dido@vdrportal) + +2005-01-03: Version 0.0.5 +- time in 'now', 'next',... can now be shifted with FastFwd and + FastRew or with Green/Yellow when toggling with '0' (see README) +- search results now display 't' ,'T', if there is already a timer for + an entry, thanks to LordPSI@vdrportal. +- translation of new things to finnish (as always thanks to Rolf Ahrenberg) +- sorting by channel in repeatings should work now, thanks to + LordPSI@vdrportal. +- fixed searching in mode 'one word', thanks to LordPSI@vdrportal +- fixed key blue and red in an empty search list, thanks to Ronny Kornexl +- fixed compilation problem with vdr-1.3.10, thanks to + rockclimber@vdrportal +- fixed some function calls to thread safeness (thanks to ?) +- fixed graphical progressbar, thanks to white_@vdrportal +- rewritten the README's + +2004-11-30: Version 0.0.4 +- New feature 'search timers' (like vdradmins 'auto timers', see the + readme, thanks to Rolf Ahrenberg for idea and code review) +- Progressbar can now be set to graphical bars in setup (you have to + apply a vdr-patch for this, see README, thanks to Uwe/egal from vdrportal for + creating the needed fonts) +- Added builtin command to commands menu to create a search from epg entry +- Added builtin command to commands menu to switch to channel of + selected entry +- Added builtin command to commands menu to search the current epg + entry in recordings (thanks to Adreas Kool for his patch) +- Key "Blue" can now also be customized by setup (switch/search) +- Key '0' toggles key mapping of red and blue key (thanks to Roman + (Uatschitchun) from vdrportal for his idea) +- Added 'day(s) of week' as search criterion +- Executing a command on an epg entry now only closes command menu, + not the whole plugin +- Display of channel number in "what's on" controlled by setup +- fixed column display to prevent cutting of channel name +- fixed selection of current channel in "what's on now" (thanks to Leo + from vdrportal for reporting this) +- button 'ok' in empty search results jumps back to search list + +2004-11-08: Version 0.0.3 +- Added an ASCII-based progress bar to the 'what's on now' view of the + schedules. (Usage and display width customizable by setup). +- Added up to 4 user defined times besides "now" and "next" + (you can use this for example for "primetime" or "late night") +- Renamed plugin main entry from "EPG search" to "Search" +- Added duration to search criterions +- Added commands menu in 'search results' list +- Behaviour of red key is now the same in 'search results' as + in main menu of the plugin. +- Updated history and readme's + +2004-09-11: Version 0.0.2 +- New feature for executing commands on epg items (see README) +- Added script epg2autotimer.sh to create autotimers from epg +- Added finnish translation (thanks to Rolf Ahrenberg, also for code review) +- Behaviour of red key can now be switched by setup form "Standard" to + "Commands". +- code is now more structured +- BUGFIX: Blue key for switching in summary should work now + (thanks to Sir James Lachtveel and others for reporting this one) +2004-08-15: Version 0.0.1 +- Initial revision. diff --git a/HISTORY.DE b/HISTORY.DE new file mode 100644 index 0000000..0b62cf2 --- /dev/null +++ b/HISTORY.DE @@ -0,0 +1,844 @@ +VDR Plugin 'epgsearch' Revision History +--------------------------------------- + +2007-xx-xx: Version 0.9.24 +neu: +- neuer SVDRP-Befehl 'LSCC', der das Ergebnis einer Timerkonfliktprüfung + zurückgibt. Zum Format der Ergebnisliste bitte ins MANUAL schauen. +- der EPG-Befehl 'Suche in Aufnahmen' wertet nun die info.vdr anstelle des + Aufnahmepfades aus und macht zusätzlich eine fuzzy-Suche, vorgeschlagen von + Mase@vdrportal +- Suchtimer mit Aktion 'Nur umschalten' und Switchtimer haben jetzt eine weitere + Option 'Ton anschalten', wodurch der Ton beim Umschalten aktiviert wird, falls + er aus war, vorgeschlagen von Michael Brückner +- Die Suche und damit das Suchtimer-Update sind nun etwa 25% schneller +fixes: +- Shiften der Uhrzeit: die Startzeit wird jetzt nur noch dann anstelle des + Fortschrittsbalken angezeigt, wenn in der Menüvorlage nicht bereits eine + Startzeit enthalten ist ("%time%"), so wie in der Standardvorlage. Danke + an Getty@vdrportal für den Hinweis. +- einige Punkte bzgl. GPL korrigiert, Danke an Thomas Günther für den Hinweis. +- Crash behoben bei nicht vorhandenem EPG, Danke an Petri Helin für einen Patch. +- Der Standardwert für die maximale Dauer ist nun '23:59' um Probleme mit + externen Tools zu vermeiden, Danke an ralf-naujokat@bugtracker für den + Hinweis (bug-id #371) +- bei EPG-Änderungen mit weniger als 10 Minuten hat epgsearch bisher einen Timer + modifiziert anstatt einen neuen anzulegen. Das verursachte jedoch Probleme mit + Sendungen unter 10 Minuten Länge. Die Toleranz ist deshalb nun + min(, 10 min). Danke an Janne Liimatainen für den Hinweis. +- einige Übersetzungen korrigiert, Danke an ramirez@vdrportal für den Hinweis. +- Scrollgeschwindigkeit in den EPG-Menüs verbessert, Danke an ramirez@vdrportal + für den Hinweis. +- Absturz behoben, wenn SIGINT während des Startens der Background-Threads + signalisiert wird. +- Kanalgruppen-Separatoren in 'Übersicht Jetzt/Nächste/...' werden nun ausgeblendet, + wenn sie leer sind, wie in ':@30', Danke an Ulf Kiener für einen entspr. Patch. + + +2007-09-02: Version 0.9.23 +neu: +- unterstützt das neue i18n-System in vdr>=1.5.7, ist aber weiterhin + abwärtskompatibel +- bei den erweiterten EPG-Kategorien kann nun auch wertmäßig verglichen werden, + z.B. um nach Sendungen nach einem bestimmten Jahr zu suchen. Dazu wurden neue + Suchmodi für die epgsearchcats.conf eingeführt (10 entspricht '<', 11 entspricht + '<=', ...) Beispiel: + + # 'bis Jahr' + 3|Year|bis Jahr||11 + # 'ab Jahr' + 12|Year|ab Jahr||13 + + Denkbar wäre auch die Suche nach einer bestimmten Staffel einer Serie, falls + dies im EPG enthalten ist. Eine vollständige Liste der Suchmodi ist im Bereich + in der Dokumentation aufgeführt +- Neuer Schalter "Ignoriere fehlende Kategorien" im Edit-Menü eines Suchtimers + bei den erweiterten EPG-Kategorien: Wenn 'Ja' gewählt ist, verhindert das, dass + eine Sendung aus dem Suchergebnis ausgeschlossen wird, falls die entsprechende + Kategorie nicht im EPG vorhanden ist. Vorsicht: Ohne weitere Suchkriterien kann + das zu einer Flut von Timern führen. +- Suchtimer können jetzt automatisch gelöscht werden. Im Edit-Menü gibt es dafür: + * nach x Aufnahmen, oder + * nach x Tagen nach erster Aufnahme + gezählt werden nur erfolgreiche Aufnahmen. Das Löschen erfolgt direkt nach dem + Ende der entsprechenden Aufnahme. +- Neue Aktion "Kopie anlegen" im Menü Suche/Aktionen zum Anlegen und Editieren einer + Kopie der aktuellen Suche, vorgeschlagen von Michael Brückner. +- Die Option "Verw. als Suchtimer" hat nun einen dritten Wert 'benutzerdef.' neben + 'Ja' und 'Nein', mit dem man über die Taste 'Blau' ein Zeitfenster angeben kann, + in dem der Suchtimer aktiv sein soll. Vorgeschlagen von jo01@vdrportal. +- Der Fortschrittsbalken zeigt nun die Startzeit anstelle eines leeren Balkens + an, wenn man zu einer noch nicht laufenden Sendung shiftet, Danke an + zulu@vdrportal für den Patch. +- Das Menü "Zeige erstellte Timer" zeigt nun mit 'Ok' die Inhaltsangabe der + erstellten Timer. Ebenfalls funktionieren die Kurztasten '1..9' für die EPG- + Befehle. +- eingebauter pin-plugin patch (epgsearch muss nicht mehr gepatcht werden) + Zum Aktivieren bitte mit 'USE_PINPLUGIN' in VDR's Make.config kompilieren + (ist mit VDR extension patch bereits automatisch der Fall) +- eingebauter graphtft-plugin patch (epgsearch muss nicht mehr gepatcht werden) + Zum Aktivieren bitte mit 'USE_GRAPHTFT' in VDR's Make.config kompilieren + (ist mit VDR extension patch bereits automatisch der Fall) +- Update der finnischen Übersetzung, Danke an Rolf Ahrenberg +- Update der französischen Übersetzung, Danke an Patrice Staudt +fixes: +- Fehler beim Anlegen eines Timers korrigiert, nachdem man durch die Inhalts- + angabe navigiert hat, danke an Rolf Ahrenberg für den Hinweis. +- Beschriftung "Aufnehmen" bzw. "Timer" im Menü Inhaltsangabe je nach vorhandenem + Timer korrigiert. +- Fehler bei Umschalttimern und geändertem EPG behoben, Danke an Juergen Urban + für einen Patch +- einige Compiler-Warnungen in g++-4.2 gefixed, Danke an Michael Brückner für den + Hinweis. +- "," als erlaubtes Zeichen für Suchtimer hinzugefügt, Danke an Mike Constabel für + den Hinweis. + + +2007-05-27: Version 0.9.22 +neu: +- neue Option in der Timerkonflikt-Prüfung "Beim Beginn einer Aufnahme": + Dadurch wird beim Start einer Aufnahme eine Konfliktprüfung durchgeführt und + per OSD über Konflikte informiert, wenn der Konflikt innerhalb der nächsten + 2h auftritt. Somit werden also auch Timer überwacht, die nicht innerhalb + epgsearch programmiert wurden, ebenso Sofortaufnahmen. +- Neues Service-Interface "Epgsearch-services-v1.0": Damit können andere + Plugins auf viele Komponenten von epgsearch wie z.B. Suchtimer, Setup-Werte, + ... zugreifen, diese verwalten und Aufgaben wie 'Nach Wiederholung suchen' + ausführen (Mehr dazu in services.h). +- Neue Projekt-Homepage: http://winni.vdr-developer.org/epgsearch, vielen Dank + an Thomas Keil +- Update der finnischen Übersetzung, Danke an Rolf Ahrenberg. +fixes: +- vollständige Neuentwicklung des Menüs zur Inhaltsangabe und dessen Navi- + gation, um Probleme mit Skins zu vermeiden und andere Bugs zu beheben. +- beim Test auf Wiederholungen wird nun auch im Vergleich mit dem Done-File + nur der alphanumerische Teil von Titel und Episode verwendet. +- weiteres Problem mit Anführungszeichen beim Aufrunf von EPG-Befehlen + korrigiert. +- Lizenzänderungen und -ergänzungen für den Einzug ins Debian-Repository +- Fehler in der Zeitanzeige bei benutzerdef. Zeiten in Verbindung mit Zeit- + sprung mit FRew/FFwd behoben, Danke an Torsten Weigelt für den Hinweis +- Die Zusatzinfo über den Kanal wurde bei 'Timer mit 'Aufnehmen' sofort anlegen' + nicht erzeugt. Danke an Rolf Ahrenberg für den Patch. + +2007-04-29: Version 0.9.21 +neu: +- Unterstützung für den MainMenuHooksPatch. Dieser löst den + vdr-replace-schedulemenu-Patch ab. Der neue Patch wird auch von anderen + Plugins verwendet. Somit ist dafür nur noch ein Patch notwendig. Der alte + Patch wird vorübergehend ebenfalls noch unterstützt. +- Die Sendungs-Ankündigungen per OSD wurden vollständig überarbeitet. Statt + einer Anzeige jeder einzelnen Sendung erhält man nun + "x neue Sendungen gefunden! Anzeigen?". Mit 'Ok' wird ein Menü aller Sendungen + eingeblendet, das die üblichen Funktionen anderer EPG-Menüs hat. Mit "Editieren" + kann man die Ankündigungs-Einstellungen verändern (z.B. "Erneut ankündigen: + ja/nein" oder erst wieder nach Tag x ankündigen). +- Timer-Konflikt-Benachrichtigungen per OSD können nun während einer Wieder- + gabe unterdrückt werden. Die Benachrichtigung erfolgt aber trotzdem, wenn + der nächste Konflikt innerhalb der nächsten 2 Stunden liegt. +- alle sub-Plugins (epgsearchonly, quickepgsearch, conflictcheckonly) haben + nun eine Setupoption zum Ein-/Ausschalten des Hauptmenüeintrags. Danke an + Tobias Grimm für den Patch. +- Kanalname in der Aux-Info von manuellen Timern, Danke an Rolf Ahrenberg + für den Patch. +- neues Skript undoneepgsearch.sh zum Rücksetzen eines Timers im Aufnahmemenü. + Mehr dazu unter: + http://www.vdr-portal.de/board/thread.php?postid=574109#post574109 + Danke an den Author Christian Jacobsen +- Update der französischen Übersetzung, Danke an Patrice Staudt. +- Update der finnischen Übersetzung, Danke an Rolf Ahrenberg. +- Im Menü 'Timer-Konflikt-Details' wird im Titel nun auch das Datum des + Konflikts angezeigt, vorgeschlagen von Rusk@vdrportal. +- Das Passwort für die Mail-Authentifizierung wird im OSD nun versteckt + angezeigt, d.h. mit '***...' +- Das Setup für Mail-Benachrichtigungen hat nun auch ein "Senden an"-Feld, + weil einige Provider keine Mails mit gleichem Sender/Empfänger akzeptieren. + Falls das Feld nicht besetzt ist, benutzt epgsearch automatisch den Sender + als Empfänger. +- Beim Prüfen auf Wiederholung (beim Feature "Wiederholung vermeiden") vergleicht + epgsearch nun nur noch die alphanumerischen Teile von Titel und Episode und + ignoriert dabei auch die Groß-/Kleinschreibung. Vorschlag von chello@vdrportal. +- Danke an Rolf Ahrenberg für das Update der finnischen Übersetzung +- '&' zu den erlaubten Zeichen eines Suchbegriffs hinzugefügt +fixes: +- Die Tags in der Aux-Info von Timern, die per Suchtimer erzeugt wurden, sind nun + XML-konform (keine Großbuchstaben oder Leerzeichen). Z.B. wird aus "Search timer" + nun "searchtimer". Also nicht wundern, wenn beim ersten Suchtimer-Update alle + Timer aktualisiert werden, die von Suchtimern angelegt wurden. Danke an Rolf + Ahrenberg für den Hinweis. +- Update von recordingdone.sh wegen der vorherigen Änderung, Danke an Mike Constabel + für einen entsprechenden Patch. +- segfault bei falsch konfigurierten erw. EPG-Kategorien behoben. +- Scrollende Menütexte funktionieren nun wieder, wenn der gewählte Skin das + unterstützt. Danke an ufauser@vdrportal für den Hinweis. +- Die Setup-Option "Verw. Suchtimer" wird nun automatisch aktiv, wenn ein + Suchtimer aktiv gesetzt wird oder ein manuelles Suchtimer-Update gestartet + wird. +- Behandlung von Anführungszeichen in Titel/Untertitel bei Übergabe an benutzerdef. + EPG-Befehle korrigiert, Danke an Mike Constabel für den Hinweis. +- Handling im Suchtimer-Vorlagenmenü korrigiert, Danke an wombel@vdrportal für den + Hinweis. + + +2007-01-30: Version 0.9.20 +neu: +- Unterstützung von vdr-1.5.0: Hinweis: Der CA-Support im Timerkonflikt-Check + ist ziemlich experimentell, weil ich es mangels CAMs nicht testen kann. +- epgsearch kann nun auch manuell programmierte Timer auf EPG-Änderungen + überwachen. Wenn epgsearch's eigenes Timer-Edit-Menü benutzt wird, stehen + folgende Methoden zur Auswahl: + * ohne Überwachung + * anhand Sendungskennung + * anhand Kanal/Uhrzeit + Mehr dazu in der README.DE + (unter 1.4.4 Setup/Timer-Programmierung/Standard-Timer-Prüfmethode) +- die im Favoritenmenü verwendete Zeitspanne kann jetzt über das Setup + angepaßt werden. Standard sind 24h. +- Sendungs-Ankündigungen: Wenn während der Ankündigung einer Sendung eine der + Tasten '0', ... '9' oder 'Ok' gedrückt wird, wird nachgefragt, ob zukünftige + Ankündigungen vollständig (bei den Tasten '0' oder 'Ok') oder nur für die + nächsten x Tage (bei den Tasten '1' bis '9') unterdrückt werden + sollen. Bestätigt man diese Abfrage durch ein erneutes 'Ok', wird die + Einstellung entsprechend übernommen. +- Mit der neuen Setup-Option "Keine Ankündigungen bei Wiedergabe" können + Ankündigungen von Sendungen während einer Wiedergabe nun abgeschaltet werden. + Vorgeschlagen von Andreas Mair. +- Neben der Erledigt-Liste für Aufnahmen gibt es nun auch eine für Timer + (timersdone.conf). Damit können nun Timer gelöscht werden, ohne dass diese + mit dem nächsten Suchtimer-Update wieder neu angelegt werden. Mit dem neuen + Menü 'Zeige erzeugte Timer' unter Suche/Aktionen kann diese Liste bearbeitet + werden. Das ganze Verfahren kann im Suchtimer-Setup auch abgeschaltet + werden. Achtung: Diese Timer-Erledigungsliste wird nur mit Timern gefüllt, + die ab dieser Version neu angelegt wurden. +- neues Zusatzplugin 'quickepgsearch': Dieses erstellt einen Hauptmenüeintrag + "Schnellsuche", der dazu dient einfach nach einem beliebigen Begriff im EPG + zu suchen. Mit '-Pquickepgsearch' einbinden. Vorgeschlagen von + SurfaceCleanerZ@vdrportal. +- neue Setup-Option "Kanäle begrenzen von 1 bis" zur Beschleunigung von + epgsearch's Aufruf. Ist der aktuelle Kanal über dem Limit werden alle Kanäle + angezeigt. Vorgeschlagen von Uwe@vdrportal. +- neue SVDRP-Befehle: + * 'LSRD' liefert eine Liste aller Verzeichnisse zurück, die aktuell bei + Aufnahmen, Timern, Suchtimern oder in epgsearchdirs.conf verwendet + werden. + * 'LSTT [ID]' liefert alle Such-Vorlagen, oder die Vorlage mit der + angegebeenen ID (Format wie in epgsearch.conf). + * 'NEWT ' zum Anlegen einer neuen Suchvorlage. + * 'DELT ' zum Löschen der Suchvorlage mit der angegebenen ID. + * 'EDIT ' zum Ändern einer Suchvorlage. + * 'DEFT [ID]' liefert die aktuelle Standard-Suchvorlage. Wird eine ID + übergeben wird die zugehörige Suchvorlage zur Standard-Suchvorlage. +- geänderte SVDRP-Befehle: + * 'DELS [ID] [DELT]' löscht nun neben der Suche auch zugehörige Timer, wenn + das optionale 'DELT' mitübergeben wird. +- man kann nun neben dem Skript sendemail.pl auch sendmail für den Mailversand + verwenden (->Setup), vorgeschlagen von Patrick Cernko +- Neue Variablen: + * '%timespan%' zur Verwendung in Menüs oder Mails. Zurückgegeben + wird die Zeitspanne von Jetzt bis zum Beginn einer Sendung (z.B. 'in + 15m'). Die Variable wird nun im Standard-Menütemplate des Favoritenmenüs + verwendet, in dem das Datumsfeld entfernt wurde. + * '%length%' für die Länge einer Sendung in Sekunden. +- Danke an Rolf Ahrenberg für das Update der finnischen Übersetzung +fixes: +- manuell programmierte Timer werden durch Suchtimer nun weder gelöscht noch + geändert. +- das Zusatzplugin conflictcheckonly wurde kompiliert auch wenn + WITHOUT_CONFLICTCHECKONLY im Makefile gesetzt war, Danke an Ronny Kornexl + für den Hinweis. +- Für Suchbegriff und Verzeichnis gibt es nun auch die Zeichen 'ß' (nur bei + Sprache Deutsch) und '@'. +- Bei Verwendung von 'Wiederholung verm.' war es in bestimmten Fällen möglich, + dass nicht die Erstausstrahlung, sondern eine Wiederholung programmiert + wurde. +- Eine Suche mit "Verw. Wochentag" UND "Verw. Uhrzeit", bei der "Start vor:" + nach Mitternacht liegt, findet nun auch Sendungen des nächsten Tages bis + "Start vor:", z.B. "Start nach 22:00" und "Start vor 03:00" am Montag findet + nun auch eine Sendung um 01:00 am Dienstag. +- bereits aufnehmende Timer werden nun nur noch aktualisiert, falls sich die + Stopzeit des Timers (z.B. wegen EPG-Update) ändert, Danke an Mike Constabel + für den Hinweis. +- Fehler beim Auswerten von Uservariablen behoben, Danke an Mike Constabel für + den Hinweis und für's remote debugging. +- Fehler bei Timerkonflikt-Mails im Zusammenhang mit Timern ohne zugeordneten + Event behoben. + +2006-10-27: Version 0.9.19 +- neu: + wenn sich die Suchergebnisse unterschiedlicher Suchen überschneiden, wird + der zugehörige Timer nun nur noch von der Suche aktualisiert, die ihn + ursprünglich angelegt hat. +- neue Variablen: + * '%search.query%' für die Verwendung im Aufnahmeverzeichnis eines + Suchtimers. Diese wird mit dem Suchbegriff eines Suchtimers ersetzt. + * '%videodir%' VDR Videoverzeichnis (z.B. /video) + * '%plugconfdir%' VDR plugin Konfigurationsverzeichnis + (z.B. /etc/vdr/plugins) + * '%epgsearchdir%' epgsearchs Konfigurationsverzeichnis + (z.B. /etc/vdr/plugins/epgsearch) +- die Syntax des 'system'-Kommandos innerhalb einer Uservariable hat sich + geändert, um die Parameter flexibler übergeben zu können. Sie lautet nun: + %uservar%=system(/path/to/script[, parameters]) + wobei das optionale 'parameters' ein beliebiger Ausdruck unter Verwendung + weiterer Uservariablen sein kann. Ausnahme: es dürfen nicht direkt weitere + system-Calls oder bedingte Ausdrücke verwendet werden. +- Update der französischen Übersetzung, Danke an Patrice Staudt +fixes: +- VPS-Timer, die von Suchtimern angelegt wurden, werden nun immer auf Ihre + VPS-Zeit aktualisiert, selbst wenn der Anwender Start- und/oder Stopzeit + verändert hat. +- nach Änderungen im Setup wurden Menü-Templates aus epgsearchmenu.conf wieder + auf den Standard zurückgesetzt, Danke an s.krueger@vdrportal für den + Hinweis. +- vorhandene VDR-Wiederholungstimer werden durch das Suchtimer-Update nicht + mehr zu normalen Timern abgeändert. + +2006-10-01: Version 0.9.18 +neu: +- WICHTIG!!! BITTE LESEN!: epgsearch erwartet seine conf-Dateien nun in einem + eigenen Konfig-Verzeichnis 'epgsearch' innerhalb des + Plugin-Konfig-Verzeichnis und nicht mehr wie bisher direkt im + Plugin-Konfig-Verzeichnis. Bitte legt dieses Verzeichnis an und verschiebt + alle epgsearch-Dateien dorthin, bevor Ihr diese Version verwendet. Etwa so: + + mkdir /etc/vdr/plugins/epgsearch + mv /etc/vdr/plugins/epgsearch*.* /etc/vdr/plugins/epgsearch + mv /etc/vdr/plugins/.epgsearch* /etc/vdr/plugins/epgsearch + + Wer bereits epgsearch's '--config' oder '-c' Parameter verwendet hat, für den + ist das nicht weiter wichtig. + +- 'Favoriten-Menü' neben 'Jetzt' and 'Nächste': Dieses Menü kann eine Liste + der Lieblingssendungen der nächsten 24h zeigen. Dazu zunächst im Setup + 'Zeige Favoriten-Menü' aktivieren. Um epgsearch zu sagen, was die + Lieblingssendungen sind, dann Suchen anlegen/editieren und dort 'In + Favoritenmenü verw.' auswählen. +- neue Setup-Option für den Timer-Konflikt-Check: 'Nach jeder + Timer-Programmierung'. Das bewirkt eine Konfliktprüfung nach jeder manuellen + Timer-Programmierung und erzeugt sofort eine OSD-Nachricht, falls der + neue/geänderte Timer in einen Konflikt verwickelt ist. +- neue Email-Benachrichtigungen über Suchtimer-Updates oder + Timer-Konflikte. Der Inhalt der Mails kann beliebig gestaltet werden. Bitte + im MANUAL-Abschnitt 'Email notification' für weitere Details nachlesen. +- epgsearch hat jetzt einen Satz von man-Pages. Ein GROSSES Danke an Mike + Constabel (vejoun@vdrportal), der die ganze Arbeit des Umschreibens, + Korrigierens und Formattieren gemacht hat. Die man-Pages enthalten die + README's, das MANUAL, sowie eine Beschreibung aller conf's, die epgsearch + verwendet. Das alles auf DE/EN. Einfach mit 'make install-doc' im + epgsearch-src-Verzeichnis einrichten. +- man kann jetzt eigene Variablen definieren um diese im + Standard-Aufnahme-Verzeichnis, im Suchtimer-Aufnahme-Verzeichnis oder in den + Menü-Templates zu verwenden. Nachdem das Ganze etwas komplex ist, bitte den + Abschnitt 'User defined variables' im MANUAL lesen. Hier nur ein Beispiel was + möglich ist: + # Weekday, Date, Time + %DateStr%=%time_w% %date% %time% + # Themes or Subtitle or Date + %ThemesSubtitleDate1%=%Subtitle% ? %Subtitle% : %DateStr% + %ThemesSubtitleDate%=%Themes% ? %Themes% : %ThemesSubtitleDate1% + # Calls this script to get a recording path + %DocuScript%=system(doku.pl,%Title%,%Subtitle%,%Episode%,%Themes%,%Category%,%Genre%) + %Docu%=%DocuScript% +- Taste 'Ok' kann jetzt auch so konfiguriert werden, dass der Kanal gewechselt + wird anstelle der Anzeige der Inhaltsanzeige. Vorschlag von malachay@vdrportal +- wenn ein Timer von einem Suchtimer erzeugt wurde, wird nun in epgsearch's + eigenem Timer-Edit-Menü der Name der Suche am Ende in einem nicht + selektierbaren Feld angezeigt. +- wenn eine Sendung via Suchtimer angekündigt wird, kann man nun dafür einen + Timer erzeugen, wenn man während der Ankündigung die rote Taste drückt, + vorgeschlagen von Andreas Mair. +- Wenn Suchtimer im Setup abgeschaltet sind, dann bewirkt ein Anlegen/Ändern + eines Suchtimers nun auch eine automatische Aktivierung im Setup, + vorgeschlagen von Andreas Mair. +- man kann jetzt mehr als ein Menü-Template für die Suchergebnisse + verwenden. (s. MANUAL, Abschnitt "Customizing the EPG menus") +- die Prüfung auf Vollständigkeit einer Aufnahme erlaubt nun auch kurze + Unterbrechungen (unter 2s, z.B. bei einem Kanal-PID-Wechsel). +- neue SVDRP-Befehle: + * LSTC [channel group name] + zeigt alle Kanalgruppen an oder nur die optional angegebene + * NEWC + erstellt eine neue Kanalgruppe, Format wie in epgsearchchangrps.conf + * EDIC + ändert eine vorhandene Kanalgruppe, Format wie in epgsearchchangrps.conf + * DELC + löscht eine vorhandene Kanalgruppe + * RENC + benennt eine Kanalgruppe um + * LSTB [ID] zeigt alle Ausschlusslisten an, oder nur diejenige mit der + angegebenen ID (Format ist dasgleiche wie in epgsearchblacklists.conf, + s. MANUAL) + * NEWB zum Anlegen einer neuen Blacklist + Anmerkung: der Wert ID wird ignoriert und von epgsearch automatisch vergeben. + * DELB zum Löschen einer Blacklist mit der angegebenen ID + * EDIB zum Ändern einer Blacklist + * 'QRYS < ID(s) >' liefert die Ergebnisse einer Suche mit der angegebenen ID + zurück. Es können auch mehrere IDs übergeben werden, getrennt durch '|'. + (s. MANUAL) + * 'QRYS ' liefert die Ergebnisse einer Suche mit den angegebenen + Werten zurück. + * 'QRYF [hours]' liefert die Ergebnisse des Favoriten-Menüs (s. MANUAL). Der + optionale Parameter gibt die Anzahl der auszuwertenden Stunden + an. Standardwert ist 24h. + * 'LSTE [ID] liefert die erweiterten EPG-Kategorien, wie sie in + epgsearchcats.conf definiert sind, oder nur diejenige mit der angegebenen + ID. + * 'MODS ID ON|OFF' schaltet die Option 'als Suchtimer verw.' ein/aus. + * 'SETP option' liefert den aktuellen Wert einer Setup-Option (s. MANUAL). +- epgsearch hat jetzt ein Bug-Tracking-System (deutsch) und eine Mailinglist + (englisch): + http://www.vdr-developer.org/mantisbt + http://www.vdr-developer.org/mailman/listinfo/epgsearch + Danke an die Betreiber von developer.org +- neues Service-Interface "Epgsearch-switchtimer-v1.0" zum Zugriff und zur + Verwaltung der Umschaltlisten (switch timer). Danke an Dirk Leber für die + Erweiterung. +- Update für die französische Übersetzung (mit Setup-Hilfe!), Danke an Patrice + Staudt +- Danke an Rolf Ahrenberg für das Update der finnischen Übersetzung +fixes: +- der erste Tag eines Wiederholungstimers wird nun beim Timer-Konflikt-Check + berücksichtigt, Danke an zimuland@vdrportal für den Hinweis +- Suchtimer-Update für VPS-Timer korrigiert, Danke an Chello und + oholler@vdrportal für den Hinweis +- Behandlung des Zeichens '|' beim Wechsel des Suchmodus einer Suche + korrigiert, Danke an Chello@vdrportal für den Hinweis +- einige Suchmodi in den epgsearchcats.conf-Beispielen für die Mehrfachauswahl + geändert. +- zusätzliche Linefeeds in der SVDRP-Antwort von LSTS entfernt, Danke an + Andreas Mair für den Hinweis +- Kanal-Kriterium 'ohne Pay-TV' wurde ignoriert, Danke an Andreas Mair für den + Hinweis +- Min/Max-Initial-Werte für Suchkriterium "Dauer" korrigiert, Danke an Mike + Constabel für den Hinweis +- einen Bug bei der Auswahl der Konfliktprüfung nach jedem Suchtimer-Update + behoben, Danke an Ronny Kornexl für den Hinweis +- '--remove-destination' ins Makefile integriert, wie in vdr-1.4.2-3 + eingeführt. + +2006-08-07: Version 0.9.17d (maintenance release) +fixes: +- falsche Verwendung von 'cPlugin::ConfigDirectory' im Suchtimer-Thread + korrigiert, Danke an Udo Richter und Petri Hintukainen für den Hinweis + +2006-06-12: Version 0.9.17c +fixes: +- Problem mit Mehrfachauswahl bei erweiterten EPG-Kategorie-Werten behoben, + Danke an Christian Jacobsen für den Hinweis +- Nochmal ein Fix für den gcc unter linvdr, Danke an toxic-tonic@vdrportal + +2006-06-10: Version 0.9.17b +fixes: +- einige Probleme mit Wiederholungstimer im Timer-Konflit-Check behoben, Danke + an Peter Juenger für den Hinweis +- Crash beim Konflikt-Check behoben bei einer aktiven Aufnahme auf einem + Gerät, das über ein Plugin zur Verfügung gestellt wird (z.B. pvr, + streamdev), Danke an Gerhard Steiner für den Hinweis. + +2006-06-06: Version 0.9.17a (bug fix release) +- Menü 'Timer-Konlfikte' wurde automatisch geschlossen, wenn + Wiederholungstimer existierten, Danke an lostinspc@vdrportal +- einige Compiler-Probleme mit gcc-2.95 und gcc-4.1.0 behoben, Danke an + ferdi03@vdrportal, smudo81@vdrportal, toxic-tonic@vdrportal + +2006-06-05: Version 0.9.17 +- Kein Support mehr für vdr < 1.3.46 :-( +- Die Logik beim Springen durch die benutzerdef. EPG-Zeiten hat sich geändert: + Es können jetzt auch Zeiten des nächsten Tages erreicht werden, wenn diese + nicht mehr als 20 Stunden in der Zukunft liegen. Danke an egal@vdrportal und + CKone@vdrportal. +- epgsearch hat jetzt einen eigenen Timer-Konflikt-Check, der über das Setup + angepasst werden kann. Einstellbar sind relevante Prioritäten, die + Zeitspanne der Prüfung und die relevante Dauer eines Konflikts. Begleitet + wird dieser Check von einem "Konflikt-Manager" unter Suchen/Aktionen, der + bei der Auflösung von Konflikten hilft. Vielen Dank an Mike Constabel für + seine ausführlichen Tests. +- Falls über einen Konflikt per OSD eine Nachricht erfolgt, kann nun mit 'Ok' + direkt in die Konflikt-Übersicht des Konflikt-Managers gewechselt werden. +- Falls jemand für die Konfliktprüfung einen eigenen Hauptmenü-Eintrag opfern + will, kann dazu das Mini-Plugin 'conflictcheckonly' verwenden, das + automatisch mitkompiliert wird. Wie üblich mit '-Pconflictcheckonly' + einbinden. conflictcheckonly hat eine Setup-Option, mit der Informationen + über den letzten Check direkt im Hauptmenü angezeigt werden. +- Das Setup ist nun vollständig umgekrempelt (in Kategorien) und hat nun + soetwas wie eine 'Online'-Hilfe, die die einzelnen Punkte näher erklärt. +- Im Menü 'Umschalttimer' wird nun auch die Kanalnummer angezeigt. +- Die Eingabe-Logik bei den erweiterten EPG-Kategorien für eine Suche hat sich + geändert um eine Mehrfachauswahl von Kategorien zu erlauben. +- Neues Skript 'timercmds-auxinfo.sh' zur Anzeige der Aux-Infos (z.B. welcher + Suchtimer hat diesen Timer erzeugt?) im VDR-Timer-Menü (erfordert den + timercmd-Patch), Danke an den Author Mike Constabel. +- bei benutzer-def. EPG-Zeiten mit leerer Beschreibung wird nun die Uhrzeit + als Beschreibung verwendet, vorgeschlagen von Thiemo Gehrke +- Neues Service-Interface "Epgsearch-conflictmenu-v1.0" zum Aufruf der + Timer-Konlfikt-Übersicht durch andere Plugins +- Neues Service-Interface "Epgsearch-lastconflictinfo-v1.0" zur Abfrage der + Ergebnisse des letzten Konfliktchecks durch andere Plugins. +- epgsearchmenu.conf wird nun nicht mehr bei jedem Plugin-Aufruf neu geladen, + weil das nur zum Testen eines conf-Files sinnvoll ist. Um das permanente + Neuladen trotzdem zu aktivieren, kann man als Plugin-Parameter '-r' oder + '--reloadmenuconf' in der runvdr angeben. +- Danke an Rolf Ahrenberg für das Update der finnischen Übersetzung +- HISTORY.DE hinzugefügt +fixes: +- Beim Laden der epgsearchmenu.conf wird im Fehlerfall nun auf ein + Default-Menü geschaltet. +- Behandlung von '%' in LSTS für SVDRP bei vdr > 1.3.44 korrigiert, Danke an + Mike Constabel +- Rechtzeitiges Laden der epgsearchmenu.conf für epgsearchonly und das + Service-Interface "Epgsearch-searchmenu-v1.0", Danke an Daniel Dorau für den + Hinweis. +- Menü-Anzeigefehler in 'Suchvorlagen' korrigiert, Danke an Mike Constabel +- Bug beim Löschen zugehöriger Timer eines Suchtimers behoben, wenn es + überhaupt keine Timer gibt, Danke an Patrick Koppen für den Hinweis. +- hoffentlich :-) einen Bug beim Übernehmen einer Suche in die Vorlagen + behoben, Danke an Patrick Koppen für den Hinweis. + +2006-04-18: Version 0.9.16 (maintenance release) +fixes: +- Die Anzeige in 'Übersicht - Jetzt' war fehlerhaft, wenn Fortschrittsbalken und Kanalnummern im Standard-Menü-Look aktiv waren. + Danke an Gerhard Steiner. +- Bei Verwendung von kleinen OSD-Fonts hat der Fortschrittsbalken geflimmert, weil er nur 1 Pixel hoch war. + Danke an holymoly und TomG@vdrportal. +- support für das APIVERSION-Define, das mit vdr-1.3.47 eingeführt wurde. + +2006-04-14: Version 0.9.15 +neu: +- die EPG-Menüs können nun über die Datei epgsearchmenu.conf in Aussehen und Inhalt konfiguriert werden + (Beispiel im 'conf'-Unterverzeichnis), z.B. erzeugt der Eintrag: + + MenuWhatsOnNow=%chnr%:3|%progrt2s%:5| %time% %t_status%:8|%category%:6| %title% ~ %subtitle%:35 + + im Menü 'Übersicht Jetzt' Einträge die mit der Kanalnummer beginnen, gefolgt von einem Fortschrittsbalken + im text2skin-Stil, der Startzeit, dem Timerstatus, der EPG-Kategorie (z.B. 'Spielfilm') sowie schließlich Titel + und Untertitel. + Jedes Menü ('Übersicht Jetzt', 'Nächste', benutzerdef. Zeiten, 'Programm' und 'Suchergebnisse' kann mit einer + eigenen Zeile angepaßt werden. Weitere Infos dazu im MANUAL. + +- WICHTIGE Änderung bei Suchtimern: epgsearch entfernt nun Timer, die nicht mehr notwendig sind (ab vdr >= 1.3.44). + Darunter fallen: + * Timers, die aufgrund von EPG-Änderungen nicht mehr gültig sind. Damit sollten die doppelten Aufnahmen vermieden + werden, die es bisher evtl. bei einer EPG-Änderung gab + * Timers, bei denen die Suchkriterien nicht mehr stimmen, z.B. nach Änderung im Suchtimer. Derartige Timer müssen + also nicht mehr manuell gelöscht werden. + Ausnahme: Timer, deren Start/Stop-Zeit manuell geändert wurde. Diese werden nicht gelöscht oder verändert. +- Neuer Such-Modus 'unscharf': Damit wird eine 'Fuzzy'-Suche durchgeführt, die einen Algorithmus verwendet, wie er + auch bei agrep benutzt wird. Die Fehler-Toleranz kann im Feld 'Toleranz' eingestellt werden. +- Neue Setup-Option "Timer mit 'Aufnehmen' sofort anlegen", wie in vdr-1.3.38 eingeführt. Bei Drücken von 'Aufnehmen' + wird damit sofort ein Timer angelegt. Kleine Abweichung zur VDR-Logik: Wenn die Sendung bereits läuft oder innerhalb + der nächsten Vorlauf-Puffer-Minuten +2 beginnt, wird trotzdem das Timer-Edit-Menü angezeigt, damit man noch Änderungen + z.B. beim Verzeichnis vornehmen kann, was bei einer lfd. Aufnahme ja nicht mehr geht. Die ganze Logik kann per Setup + auch wieder abgeschaltet werden, zumindest mir ist die alte lieber ;-) +- Bei Verwendung von epgsearch Timer-Edit-Menü gibts nun auch einen Löschen-Button, um einen Timer ohne Umweg über das + Timer-Menü löschen zu können, vorgeschlagen von Rolf Ahrenberg. +- Wenn der Hauptmenüeintrag von epgsearch nicht ausgeblendet ist, kann der anzuzeigende Name nun per Setup eingestellt + werden. (Anmerkung: ändert man den Eintrag abweichend zur Standard-Vorgabe, ist dieser nicht mehr sprachabhängig) +- Der Standard-Menü-Eintrag lautet jetzt nicht mehr 'Suche' sondern 'Programmführer' +- einige Leute wollten einen eigenen Hauptmenü-Eintrag für epgsearch's Suchen-Menü. Deshalb gibt's nun ein Mini-Plugin + names 'epgsearchonly' das einfach dieses Menü aufruft. Sein Hauptmenu-Eintrag lautet 'Suche'. Übersetzt wird es automatisch + mit epgsearch. Man kann das aber auch im Makefile abschalten, indem man + #WITHOUT_EPGSEARCHONLY=1 auskommentiert. Zur Verwendung einfach '-P epgsearchonly' ins VDR-Startskript eintragen + (ab vdr-1.3.30) +- Neues Service-Interface "Epgsearch-searchmenu-v1.0" um epgsearch's Suchmenu aufzurufen (genau das macht epgsearchonly ;-) ) +- Neue Aktion 'Erstellte Timer löschen?' um alle Timer eines Suchtimers zu entfernen. Betrifft nicht aufnehmende Timer. +- Beim Löschen einer Suche erfolgt nun eine Abfrage, ob alle zugehörigen Timer ebenfalls gelöscht werden sollen. +- Wenn die Start/Stop-Zeit eines Timers, der per Suchtimer angelegt wurde, manuell verändert wird, wird dieser Timer von + epgsearch nicht mehr angefaßt (ab vdr-1.3.44 ) +- Eine Sendung, die gerade aufgenommen wird, hat in den EPG-Menüs nun ein 'R' statt eines 'T'. +- Unterstützung des wareagle-icon-patch (kann in der epgsearchmenu.conf mit 'WarEagleIcons=1' aktiviert werden) +- Fortschrittsbalken in Jetzt/Nächste 'verschönert' (bei Verwendung der Setup-Option 'graphisch'), + angelehnt an Nordlichts-EPG-Plugin +- Neue Setup-Option um Radio-Kanäle in den EPG-Menüs zu unterdrücken, vorgeschlagen von Patrice Staudt. +- Neues Service-Interface "Epgsearch-searchresults-v1.0", das die Suchergebnisse einer übergebenen Suche zurückliefert, + vorgeschlagen von Andreas Brugger +- Damit das Setup nicht platzt, wurden einige Optionen entfernt, weil diese mit dem konfigurierbaren Menü nun genauso machbar + sind: + * "Zeige Fortschrittsbalen in 'Nächste', default ist 'nein' + * "Anzeigenbreite für Fortschrittsbalken", default ist 4 + * "Zeige kurze Kanalnamen", default ist 'ja' + * "Zeige Untertitel in EPG-Menüs', default ist 'ja' +- Update der finnischen Übesetzung, Danke an Rolf Ahrenberg +- Das Aux-Feld eines Timers wird nun komplett im XML-Stil gefüllt (ab vdr-1.3.44). Deshalb gibt es auch ein Update für die + recordingdone.sh im 'scripts'-Unterverzeichnis. Danke an Mike Constabel für den Patch des Skripts. +- Das Suchtimer-Update läuft nun immer mit niedriger Priorität, vorgeschlagen von Christian Jacobsen +- neues SVDRP-Kommando 'FIND'. Damit kann ein Sendung gesucht werden. Zurückgeliefert wird eine Ergebnisliste bestehend aus + 'NEWT'-Zeilen, die somit direkt zum Programmieren des Timers verwendet werden können. Vorgeschlagen ovn Lari Tuononen. +fixes: +- Danke an Darren Salt für einige Patches im Zusammenhang mit g++ 4.1, Thread safeness und code review +- einige Speicherlecks geflickt. +- Korrektur für Aufruf von benutzerdef. EPG-Befehlen, Danke an rzndl@vdrportal +- Korrektur für blacklist-Suche bei Suchtimern, Danke an Christian Jacobsen +- der Episoden-Name eines Timer ist nun max. MAX_SUBTITLE_LENGTH lang, Danke an Mike Constabel +- Geschwindigkeit des Suchtimer-Updates etwas verbessert (~15%) + + +2006-03-05: Version 0.9.14a +fixes: +- EPG-Befehl 'als bereits aufgezeichnet markieren' hat einen Absturz verursacht, Danke an Mike Constabel für den Hinweis + +2006-03-04: Version 0.9.14 +neu: +- beim Aktivieren/Deaktivieren eines Suchtimers kann man nun angeben, ob die zugehörigen Timer + ebenfalls aktiviert/deaktiviert werden sollen. +- Neuer EPG-Befehl 'Ausschlussliste anlegen' zum Anlegen einer Ausschlussliste aus einem EPG-Menü. +- Die Inhaltsangabe eines Eintrags im Menü 'Erledigte Aufnahmen' hat nun einen zusätzlichen Button + 'Zusatzinfo', der den Inhalt des Aux-Feld (in vdr-1.3.44 eingeführt) anzeigt, falls verfügbar. +- Update für das Skript recordingdone.sh, funktioniert nun auch mit vdr-1.3.44, Danke an Mike Constabel + für die Anpassungen. +- Konvertierungsskripts für das Upgrade auf vdr-1.3.44: Aufgrund der geänderten Behandlung der + Zusatzinfos in der Inhaltsangabe (summary -> aux) funktionieren einige Suchtimer-Features nicht mit + Aufnahmen die vor dem Umstieg auf vdr-1.3.44 gemacht wurden. Das betrifft das done-Feature und das + automatische Löschen von Aufnahmen. Wer die Skripts nicht anwendet, hat einfach einige überflüssige + Aufnahmen mehr ;-). Muss also nicht unbedingt gemacht werden, aber mit den Skripts läuft alles wie + gewohnt. Danke an Mike Constabel, der die Skripts gebaut hat. + * neues Skript convert_info_vdr.pl. Dieses konvertiert das Info-File von Aufnahmen und verschiebt die + Zusatzinfo von epgsearch in das aux-Feld. + * neues Skript convert_epgsearchdone_data.pl. Dieses konvertiert die Datei epgsearchdone.data, indem es + einen Aux-Abschnitt hinzufügt. +- Update für das Skript mtdone2epgsearchdone.sh, Danke an Christian Jacobsen. +- Update der französischen Übersetzung, Danke an Patrice Staudt +- Update der finnischen Übersetzung, Danke an Rolf Ahrenberg +fixes: +- Das done-Feature funktioniert nun auch mit vdr-1.3.44, Danke an Mike Constabel +- fix für hohe CPU-Last durch Suchtimer-Thread im 30sek-Abstand, Danke an sledgehammer@vdrportal +- Das automatische Verlinken des Tarballs wurde wieder entfernt, gewünscht von Distri-Maintainern +- einige Compiler-Warnings gefixed bei Verwendung von -Wformat=2, Danke an Darren Salt für den Hinweis und + einen Patch + +2006-02-28: Version 0.9.13 +neu: +- Unterstützung für vdr-1.3.44: funktioniert nun, aber: wegen der Änderung summary -> aux + in vdr-1.3.44 sind die Zusatzinfo über den Suchtimer, der den Timer/die Aufnahme erzeugt + hat, im Moment nicht mehr verfügbar. Diese werden jetzt im neuen Aux-Feld des Timers/der + Aufnahme gespeichert. +- Ausschlusslisten: man kann nun eine oder mehrere Ausschlusslisten anlegen und diese innerhalb + einer Suche oder eines Suchtimers auswählen. Eine Ausschlussliste arbeitet wie eine normale Suche + und legt die Sendungen fest, die in einer Suche oder einem Suchtimer ignoriert werden sollen. + Ausschlusslisten können im Setup oder in der neuen Such-Aktion 'Ausschlusslisten anzeigen' sowie + direkt beim Editieren einer Suche verwaltet werden. In der Suche selbst können eine, mehrere oder + alle Ausschlusslisten ausgewählt werden. Falls ein Suchergebnis auch in einer der gewählten + Ausschlusslisten enthalten ist, wird es ignoriert. +- Der Hintergrund-Thread für die Umschalttimer läuft jetzt nur noch, wenn auch ein Umschalttimer aktiv ist. +- Beim entpacken des tar-Files wird der Link zu epgsearch-x.x.x nun automatisch erzeugt (wie bei text2skin) +- Die Ergebnisliste bei "Wiederholungen anzeigen" zeigt nun nicht mehr auch die laufende Sendung an, + Vorschlag von Ronny Kornexl +- Danke fürs Betatesten an Mike Constabel +- Danke fürs Update der finnischen Übersetzung an Rolf Ahrenberg +fixes: +- die Setup-Option 'Untertitel in manuellen Timern' wurde nicht gespeichert. + +2006-02-12: Version 0.9.12 +neu: +- Neues Feature 'Pause, wenn ... Aufnahmen exist." für Suchtimer. Sobald die + angegebene Anzahl (>0) von Aufnahmen existiert, erzeugt epgsearch keine + weiteren Timer mehr für diesen Suchtimer. Erst wenn eine oder mehrere Auf- + nahmen gelöscht wurden, werden erneut Timer angelegt. +fixes: +- Absturz beim Navigieren zu einem Kanal ohne EPG im Programme-Menü behoben + +2006-02-08: Version 0.9.11a +fixes: +- hohe CPU-Last im 5 Sekunden-Takt beseitigt + +2006-02-07: Version 0.9.11 +neu: +- Unterstützung von vdr-1.3.42 +- Neues Feature 'Umschalttimer': mit dem neuen EPG-Befehl 'In/Aus Umschalt- + liste' kann eine Sendung in eine Umschaltliste aufgenommen werden. VDR + schaltet dann kurz (einstellbar) vor Beginn zu dieser Sendung um. Der Inhalt + der Umschaltliste kann über 'Suche/Aktionen/Umschaltliste anzeigen' kontrolliert + und geändert werden. Falls eine Sendung in der Umschaltliste ist, wird Sie in + den Menüs mit einem 'S' markiert (falls kein echter Timer dafür existiert). +- Umschalttimer auch für Suchtimer: Ein Suchtimer kann ebenfalls als Umschalt- + timer verwendet werden (Aktion: nur umschalten). Sobald Suchergenisse vorliegen + werden diese in die Umschaltliste aufgenommen. Es wird kein echter Timer erzeugt. +- Suchkriterium 'Verwende Kanal' hat nun einen weiteren Wert 'nur FTA', um die Suche + auf alle nicht verschlüsselten Programme einzuschränken. +- Neue Setup-Option 'Zeige Tagesseparatoren', zur Anzeige von Trennlinien zwischen + den Tagen im Menu Programm +- epgsearch hat jetzt ein SVDRP-Interface mit folgenden Befehlen + (ab vdr > 1.3.30): + * 'LSTS [ID]' zeigt alle Suchen an, oder nur diejenige mit der angegebenen ID + (Format ist dasgleiche wie in epgsearch.conf, s. MANUAL) + * 'NEWS ' zum Anlegen einer neuen Suche + Anmerkung: der Wert ID wird ignoriert und von epgsearch automatisch vergeben. + * 'DELS ' zum Löschen einer Suche mit der angegebenen ID + * 'EDIS ' zum Ändern einer Suche + * 'UPDS [OSD]' zum Starten eines Suchtimer-Updates. Wird der optionale Parameter + 'OSD' angegeben, informiert das OSD, wann das Update beendet ist. + * 'UPDD' zum Nachladen der epgsearchdone.data in den Speicher, z.B. nach einer Änderung + durch ein externes Tool + * 'SETS ' zum Ein-/Ausschalten der Suchtimersuche im Hintergrund +- weil das Setup allmählich zu groß wird, gibt es dort jetzt die Modi "Standard" und + "Erweitert" (umschaltbar über Taste rot), vorgeschlagen von Rolf Ahrenberg +- Update der finnischen Übersetzung, Danke an Rolf Ahrenberg +- Update der italienischen Übersetzung, Danke an Reelbox User +- Update der französischen Übersetzung, Danke an Patrice Staudt +- Neue holländische Übersetzung, Danke an Reelbox User +- Verwendung von '127.0.0.1' anstatt der Auflösung von 'localhost' für SVDRP, + vorgeschlagen von Thiemo Gehrke +- neues Skript recordingdone.sh für die reccmds.conf, um eine Aufnahme als erlegigt zu + kennzeichnen (für epgsearch's done-Feature), Danke an Patrice Staudt, Christian Jacobsen + und Mike Constabel +- neues Skript mtdone2epgsearchdone.sh zur Übernahme von erledigten Aufnahmen von + mastertimer in epgsearch's done-Datei, Danke an Christian Jacobsen. +- Danke an Mike Constabel und Andreas Brugger fürs Testen und die Bug Reports +fixes: +- Fehler bei der Verwendung von Vorlagen behoben, Danke an Christian Jacobsen + +2006-01-15: Version 0.9.10 +neu: +- Aktualisierung aller Programm- und Suchergebnismenüs nach dem Anlegen + oder Ändern eines Timers, wie in vdr-1.3.38 eingeführt +- Die Taste 'Aufnehmen' wird jetzt mit 'Aufnehmen' oder 'Timer' beschriftet, + abhängig davon, ob für die Sendung ein Timer existiert, wie in vdr-1.3.38 + eingeführt +- Im Timer-Edit-Menu von epgsearch (Setup-Einstellung beachten!) wird nun bei + einer laufenden Aufnahme angezeigt, über welche Karte der Timer aufnimmt +- Neue Setup-Option: 'Untertitel in manuellen Timern' + Betrifft das autom. Ergänzen des Untertitels bei einem manuell angelegten + Timer. Die Einstellung 'intelligent' verwirft den Untertitel, falls die + Sendung länger als 80min ist. Ist noch nicht sooo intelligent ;-) +- Das Menü zum Editieren der Suche wurde für zukünftige Erweiterungen + geändert: 'Aktion' bestimmt nun, was mit den Suchergebnissen gemacht werden + soll, im Moment gibts 'Aufnehmen' als Standard und 'Nur Ankündigen' +- Danke an Rolf Ahrenberg für das Update der finnischen Übersetzung +fixes: +- in vdr-1.3.38 waren einige Übersetzungen defekt +- timercmds-patches für vdr-1.3.38 aktualisiert + +2006-01-08: Version 0.9.9 +neu: +- Unterstützung für vdr-1.3.38 +- Suchvorlagen: da die Einstellungen zu einer Suche oft die gleichen sind, + gibt es nun Vorlagen, die beim Anlegen/Ändern einer Suche mit der Taste + 'Blau' verwendet werden können. Eine Vorlage kann auch als "Standard" + definiert werden, wodurch deren Einträge beim Anlegen einer Suche auto- + matisch übernommen werden. +- Setup um 'Suchvorlagen' erweitert (zur Verwaltung der Vorlagen) +- Neue Aktion 'Als Vorlage verwenden', um eine Suche in die Vorlagen zu + kopieren +- Neue Setup-Option, um die Anzeige der Untertitel in der Übersicht zu steuern, + danke an Darren Salt für den Patch +- Erweiterung des Features 'Aufnahmen nach ... Tagen löschen' um 'Erhalte + ... Aufnahmen'. Dadurch werden die letzten x Aufnahmen immer erhalten, auch + wenn diese bereits das Zeitlimit überschritten haben. +fixes: +- Das Feature 'Aufnahmen nach ... Tagen löschen' hat auch editierte/ge- + schnittene Aufnahmen gelöscht. Behoben. + + +2005-11-27: Version 0.9.8 +neu: +ACHTUNG!: diese Version konvertiert die epgsearch.conf (die Datei, in der + die Sucheinträge gespeichert werden) in ein NEUES FORMAT. Es wird ein + Backup der alten Datei unter epgsearch.conf.bak angelegt.Geht man also auf + eine alte Version zurück, muss das Backup nach epgsearch.conf zurückkopiert + werden. +- Neues Feature 'Wiederholungen vermeiden' (aka done-Feature) für Suchtimer + (bitte die README.DE vor dem ersten Gebrauch lesen!). Ein besonderer Dank an + Mike Constable (vejoun@vdrportal) für viele viele Test-Stunden und Bug- + Reports. + * Vorschau von geplanten Timern + * Erkennung unvollständiger Aufnahmen + * Fuzzy-Vergleich von Sendungen +- Das Menü der Suchergebnisse hat bei Suchtimern mit 'Wiederh. vermeiden' nun + eine zusätzliche Belegung für die Taste 'Blau', um sich die geplanten Timer + anzeigen zu lassen, die mit dem nächsten Suchtimer-Update programmiert werden. +- Neue Setup-Option zur Anzeige von Sendern ohne EPG in 'Was läuft jetzt?', + Idee von 'Nordlicht's EPG plugin' übernommen +- Neue Setup-Option 'Zeige Kanal-Separatoren' in 'Was läuft jetzt?' + Idee von 'Nordlicht's EPG plugin' übernommen +- Neues Suchtimer-Feature 'Lösche Aufnahmen nach ... Tagen'. Damit werden Auf- + nahmen nach den eingestellen Tagen automatisch gelöscht. Praktisch z.B. für + Nachrichtensendungen wie Tagesschau, die nur für einige Tage interessieren. +- Die Inhaltsangabe von Timern (über ok im Timermenu), die epgsearch erzeugt hat, + enthalten nun zusätzliche Infos: Titel und Untertitel (falls vorhanden) am + Anfang, sowie Name und ID des Suchtimers und den Sender am Ende +- Die Inhaltsangabe von manuell programmierten Timern enthält nun: + Titel und Untertitel (falls vorhanden) am Anfang, sowie Sender am Ende +- 'Ausführen' im Suchmenu wurde ersetzt durch 'Aktionen' und listet: + * Suche ausführen (wie zuvor auch mit ok) + * 'Als Suchtimer verwenden' an/aus + * Suchtimer-Update ausführen + * Erledigte Aufnahmen anzeigen + Es können natürlich genauso die Tasten als Abkürzung verwendet werden, ohne + das Menu aufzurufen. '0' ruft das Menü auf. +- Einführung eines Logfiles (Standard ist plugin-configdir/epgsearch.log, kann + aber über den Startparameter '-l /path/to/logfile' geändert werden. Der Para- + meter '-v n' bestimmt das Log-Level. n=0 bedeutet kein Logging (default), + 1 (eingeschränktes Logging),2(detailliert),3(umfangreich). +- Im Setup gibts nun ein Standard-Aufnahmeverzeichnis, das beim manuellen Pro- + grammieren von Timern vorgegeben wird. Unterstützt werden auch Einträge der + Form '%Category%~%Genre%'. +- abhängig vom aufrufenden Menu sind nun die Tasten 'Grün/Geld' im Event-Menu + (also der Inhaltsangabe) nun mit dem vorh./nächsten Sender bzw. der vorh./ + nächsten Startzeit beschriftet, danke an Andreas Brugger (brougs78@vdrportal) +- Sendernummern werden nun auch im Menü Suchergebnisse gelistet, falls die + Option im Setup geschaltet ist, danke an Gerhard Steiner (gestein@vdrportal). +- Kurztasten (1,2,...) für EPG-Befehle sind nun auch im Menu der Inhaltsangabe + verfügbar, danke an Frank Krömmelbein (frank99@vdrportal) +- Ab VDR version >= 1.3.31 kann im Setup nun eingestellt werden, ob man für die + manuelle Timerprogrammierung das Timer-Editmenü von epgsearch oder von VDR ver- + wenden will.(evtl. sinnvoll, wenn man einen gepatchten VDR benutzt). Danke an + Frank Krömmelbein (frank99@vdrportal) +- Falls ein Untertitel existiert wird er beim manuellen Timer-Programmieren nun + automatisch ans Verzeichnis angehängt. Danke an Gerhard Steiner + (gestein@vdrportal) +- Aufteilung von Verzeichnis und File beim erneuten Bearbeiten von Timern opti- + miert, Danke Andreas Brugger (brougs78@vdrportal) +- In den Hauptmenus werden Untertitel nun immer angezeigt, in der Form 'Titel ~ + Untertitel', falls vorhanden +- Neue service-Funktion 'Epgsearch-updatesearchtimers-v1.0' zum Aufruf eines + Suchtimer-Updates +- Falls ein Suchtimer-Update über das Aktionenmenu aufgerufen wird, gibt es nun + im OSD eine Nachricht, sobald das Update fertig ist. (Ebenso bei Verwendung von + des Services 'Epgsearch-updatesearchtimers-v1.0' +- Das Such-Menü zeigt nun die Anzahl der (aktiven) Suchen im Titel an +- Danke an Rolf Ahrenberg für die Aktualisierung der finnischen Übersetzung. +- Danke an Mike Constabel für die Überarbeitung der READMEs und des MANUALs. +fixes: +- epgsearch springt nun zum Hauptmenu zurück, falls es nicht über eine Kurztaste + aufgerufen wurde. Danke an Andreas Brugger (brougs78@vdrportal) +- Eingabe von Suchbegriffen bei englischem OSD korrigiert +- Sortierung von Suchtimern nach dem Editieren einer Suche korrigiert, Danke an + Mike Constabel (vejoun@vdrportal) +- Menü-Navigation bei leerem EPG korrigiert, Danke an Darren Salt für den Patch +- Falsche optische Ausrichtung von Sucheinträgen im Suchmenü korrigiert, Danke an + Andreas Brugger (brougs78@vdrportal) + + +2005-09-04: Version 0.9.7 +neu: +- Änderungen in der Beschreibung einer Sendung bewirken jetzt auch ein Update eines Timers +fixes: +- bei der Verwendung von reg. Ausdrücken in Suchtimern gab es ein böses Speicherleck, + Danke an TomG@vdrportal +- Kanalanzeige in den Farbtasten funktionierte nicht wenn es Kanaltrenner gab. Danke an viking@vdrportal + + +2005-08-27: Version 0.9.6 + +neu: +- Suchkriterium 'Verw. Kanal' um 'Kanalgruppen' erweitert. Diese Kanalgruppen können über ein eigenes Menu verwaltet werden (im Suchtimer oder im Setup) und erlauben eine flexiblere Kanalauswahl für Suchtimer als bisher. (s. Screenshot) +- epgsearch stellt das erweiterte Timer-Editmenu und die Suche im EPG jetzt als 'Service' anderen Plugins zur Verfügung (ab 1.3.30 oder mit Udo Richters backport, s. MANUAL oder mail an mich, falls jemand Interesse hat) +- Beim Programmieren eines Timers (manuell oder per Suchtimer) wird nun die Inhaltsangabe an den Timer übergeben (damit kann im VDR-Timermenu mit 'ok' die Inhaltsangabe angezeigt werden), Danke an TomG +- Nach dem Umschalten der Farbtasten mit '0' im Menu 'Programm' kann mit den Farbtasten Grün/Gelb zum Programm des vorherigen/nächsten Senders gewechselt werden (s. Farbtasten im Screenshot) +- patch von Uwe/egal hinzugefügt, der es erlaubt, das VDR-Programmmenu durch epgsearch zu ersetzen. Danke an Uwe auch für die Anpassungen in epgsearch (Nach dem Patchen von VDR muss der patch noch im epgsearch-Setup aktiviert werden!) +- Nach dem Anlegen einer neuen Suche wird diese jetzt im Suchmenu korrekt einsortiert, Danke an Mike Constabel +- Gerhard Steiner's timercmd patch für vdr >= 1.3.25 hinzugefügt +- ein 'back' im Anfangsmenu schließt nun immer das OSD (sollte Probleme mit dem submenu-Patch lösen) +- Events ohne Titel (ja, sowas gibts) werden in der Suche nun immer ignoriert, Danke an Mike Constabel +- neue EPG-Variable '%channel%', die im Verzeichnis-Eintrag verwendet werden kann und durch den Sendernamen ersetzt wird +- Anfangs- und Endpuffer einer Aufnhame dürfen jetzt auch negativ sein (das erlaubt ein absichtliches Abschneiden einer Sendung am Anfang oder Ende), Danke an Mike Constabel +- Groß-/Kleinschreibung wird nun in erweiterten EPG-Kategorien ignoriert +- Finnische Übersetzung aktualisiert, Danke an Rolf Ahrenberg + +fixes: +- Beim Laden von '.epgsearchrc' wird jetzt auch ein evtl. angegebener Config-Pfad (-c) berücksichtigt, Danke an Ronny Kornexl +- Programmierung von Suchtimern mit leerem Verzeichnis oder Namen korrigiert, Danke an Andreas Brugger +- Programmierung von Suchtimern korrigiert, bei denen Mitternacht zwischen Start und Ende liegt +- Menu Verzeichnisauswahl machte Probleme, wenn keine Verzeichnisse existierten, Danke an harvey@vdrportal +- (De)Aktivieren von Suchtimern mit '0' speichert nun sofort, Danke an Mike Constabel +- Menu Navigation (Grüm-Gelb-Gelb-Grün) zeigt nun korrekterweise 'Was läuft jetzt' und nicht mehr Inhaltsangabe, Danke an Mike Constabel + diff --git a/INSTALL b/INSTALL new file mode 100644 index 0000000..777e04c --- /dev/null +++ b/INSTALL @@ -0,0 +1,36 @@ +Theres nothing special about it. Install it like any other standard +plugin (unpack, soft link, make plugins). + +Optional libraries: +------------------- + +libpcre +------- +For support of Perl compatible regular expressions in a search you have to use +libpcre: +simply edit the plugins Makefile and uncomment '#HAVE_PCREPOSIX=1' to +'HAVE_PCREPOSIX=1' or append 'HAVE_PCREPOSIX=1' to your 'make plugins' +call. (you will need pcreposix installed, comes with libpcre from +www.pcre.org, but it's already part of most distributions +HINT: if all compiles well, but after starting VDR you get: + +ERROR: /usr/lib/libpcreposix.so.0: undefined symbol: pcre_free). + +update libpcre from www.pcre.org and recompile the plugin. + +There seems to be a problem with PCRE on some systems, that produce a crash +when using regexp. Til now, I could not find the reason. So perhaps dont use +HAVE_PCREPOSIX=1, if you don't really need it. + +libtre +------ +epgsearch has a fuzzy search algorithm. Unfortunately it's rescrited to +search patterns with a maximum of 31 characters. This results in empty results +if more than 31 characters are used. To avoid this limitation you can use the +TRE package (http://laurikari.net/tre/). Install tre (on debian: +apt-get install tre-agrep libtre4 libtre-dev) and activate epgsearch's support +for it in the Makefile by uncommenting '#HAVE_LIBTRE=1' to 'HAVE_LIBTRE=1' or append +it to your 'make plugins' call. After recompiling epgsearch will now use an +algorithm similiar to 'agrep' with no limits. + + diff --git a/INSTALL.DE b/INSTALL.DE new file mode 100644 index 0000000..1d871df --- /dev/null +++ b/INSTALL.DE @@ -0,0 +1,22 @@ +Hier gibt es nichts besonderes. Bitte wie jedes andere Standard-Plugin +installieren (entpacken, soft link, make plugins). Eine kleine +Besonderheit: Wer lieber mit Perl compatible regular expressions in +der Suche arbeitet, sollte einfach im Makefile des Plugins +#HAVE_PCREPOSIX=1 in HAVE_PCREPOSIX=1 ndern oder einfach +HAVE_PCREPOSIX an den 'make plugins'-Aufruf anhngen. Hierzu muss pcreposix +installiert sein, das in der libpcre von www.pcre.org enthalten ist. +Dies sollte aber in den meisten Distributionen bereits enthalten sein. + +HINWEIS: wenn alles normal kompiliert, aber beim Start von VDR +folgendes kommt: + + ERROR: /usr/lib/libpcreposix.so.0: undefined symbol: pcre_free). + +dann bitte libpcre von www.pcre.org updaten und das Plugin neu +kompilieren. + +Scheinbar gibt es auf manchen Systemen Probleme mit PCRE, die sich in einem +Crash uern, wenn man reg. Ausdrcke benutzt. Da ich die Ursache bisher +nicht +finden konnte, empfehle ich deshalb auf HAVE_PCREPOSIX=1 zu verzichten, wenn +es nicht unbedingt notwendig ist. diff --git a/MANUAL b/MANUAL new file mode 120000 index 0000000..880d5cb --- /dev/null +++ b/MANUAL @@ -0,0 +1 @@ +doc/en/epgsearch.4.txt \ No newline at end of file diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..662ef1f --- /dev/null +++ b/Makefile @@ -0,0 +1,225 @@ +# +# Makefile for epgsearch, a Video Disk Recorder plugin +# +# Christian Wieninger cwieninger at gmx.de +# + +### uncomment one of these lines, if you don't want the addon epgsearchonly, conflictcheckonly +#WITHOUT_EPGSEARCHONLY=1 +#WITHOUT_CONFLICTCHECKONLY=1 +#WITHOUT_QUICKSEARCH=1 + +PLUGIN = epgsearch +MAINMENUSHORTCUT = epgsearchmainmenushortcut +PLUGIN2 = epgsearchonly +PLUGIN3 = conflictcheckonly +PLUGIN4 = quickepgsearch + +# uncomment this if you want to use Perl compatible regular expressions (PCRE), +# also have a look at INSTALL for further notes on this +#HAVE_PCREPOSIX=1 + +# uncomment this if you want to use libtre for unlimited fuzzy searching, +# also have a look at INSTALL for further notes on this +#HAVE_LIBTRE=1 + +### The version number of this plugin (taken from the main source file): + +VERSION = $(shell grep 'static const char VERSION\[\] *=' $(PLUGIN).c | awk '{ print $$6 }' | sed -e 's/[";]//g') + +### The C++ compiler and options: + +CXX ?= g++ +CXXFLAGS ?= -Wall -O2 -Woverloaded-virtual -Wno-format-y2k -fPIC + +### The directory environment: + +DVBDIR = ../../../../DVB +VDRDIR = ../../.. +LIBDIR = ../../lib +TMPDIR = /tmp + +### Allow user defined options to overwrite defaults: + +-include $(VDRDIR)/Make.config + +ALL = libvdr-$(PLUGIN).so createcats +ifndef WITHOUT_EPGSEARCHONLY + ALL += libvdr-$(PLUGIN2).so +endif +ifndef WITHOUT_CONFLICTCHECKONLY + ALL += libvdr-$(PLUGIN3).so +endif +ifndef WITHOUT_QUICKSEARCH + ALL += libvdr-$(PLUGIN4).so +endif + +### The version number of VDR (taken from VDR's "config.h"): + +VDRVERSION = $(shell grep 'define VDRVERSION ' $(VDRDIR)/config.h | awk '{ print $$3 }' | sed -e 's/"//g') +APIVERSION = $(shell grep 'define APIVERSION ' $(VDRDIR)/config.h | awk '{ print $$3 }' | sed -e 's/"//g') +ifeq ($(strip $(APIVERSION)),) + APIVERSION = $(VDRVERSION) +endif + +### The name of the distribution archive: + +ARCHIVE = $(PLUGIN)-$(VERSION) +PACKAGE = vdr-$(ARCHIVE) + +### Includes and Defines (add further entries here): + +INCLUDES += -I$(VDRDIR)/include -I$(DVBDIR)/include +#INCLUDES += -I$(VDRDIR)/include + +DEFINES += -D_GNU_SOURCE -DPLUGIN_NAME_I18N='"$(PLUGIN)"' +DEFINES1 += -D_GNU_SOURCE -DPLUGIN_NAME_I18N='"$(MAINMENUSHORTCUT)"' +DEFINES2 += -D_GNU_SOURCE -DPLUGIN_NAME_I18N='"$(PLUGIN2)"' +DEFINES3 += -D_GNU_SOURCE -DPLUGIN_NAME_I18N='"$(PLUGIN3)"' +DEFINES4 += -D_GNU_SOURCE -DPLUGIN_NAME_I18N='"$(PLUGIN4)"' + +### The object files (add further files here): + +OBJS = afuzzy.o blacklist.o changrp.o conflictcheck.o conflictcheck_thread.o distance.o $(PLUGIN).o epgsearchcats.o epgsearchcfg.o epgsearchext.o epgsearchsetup.o epgsearchsvdrp.o epgsearchtools.o i18n.o mail.o md5.o menu_announcelist.o menu_blacklistedit.o menu_blacklists.o menu_commands.o menu_conflictcheck.o menu_deftimercheckmethod.o menu_dirselect.o menu_event.o menu_favorites.o menu_main.o menu_myedittimer.o menu_quicksearch.o menu_recsdone.o menu_search.o menu_searchactions.o menu_searchedit.o menu_searchresults.o menu_searchtemplate.o menu_switchtimers.o menu_templateedit.o menu_timersdone.o menu_whatson.o noannounce.o rcfile.o recdone.o recstatus.o searchtimer_thread.o services.o switchtimer.o switchtimer_thread.o templatefile.o timer_thread.o timerdone.o uservars.o varparser.o + +ifdef HAVE_PCREPOSIX +LIBS += -L/usr/lib -lpcreposix -lpcre +DEFINES += -DHAVE_PCREPOSIX +endif + +#ifdef HAVE_LIBTRE +#LIBS += -L/usr/lib -ltre +#DEFINES += -DHAVE_LIBTRE +#endif + +ifdef CFLC +DEFINES += -DCFLC +endif + +ifdef DEBUG_CONFL +DEFINES += -DDEBUG_CONFL +endif + +OBJS2 = mainmenushortcut.o epgsearchonly.o +LIBS2 = + +OBJS3 = mainmenushortcut.o conflictcheckonly.o +LIBS3 = + +OBJS4 = mainmenushortcut.o quickepgsearch.o +LIBS4 = + +### The main target: + +all: libvdr-$(PLUGIN).so libvdr-$(PLUGIN2).so libvdr-$(PLUGIN3).so libvdr-$(PLUGIN4).so createcats i18n + +### Implicit rules: + +%.o: %.c + $(CXX) $(CXXFLAGS) -c $(DEFINES) $(INCLUDES) $< +mainmenushortcut.o: mainmenushortcut.c + $(CXX) $(CXXFLAGS) -c $(DEFINES1) $(INCLUDES) $< +epgsearchonly.o: epgsearchonly.c + $(CXX) $(CXXFLAGS) -c $(DEFINES2) $(INCLUDES) $< +conflictcheckonly.o: conflictcheckonly.c + $(CXX) $(CXXFLAGS) -c $(DEFINES3) $(INCLUDES) $< +quickepgsearch.o: quickepgsearch.c + $(CXX) $(CXXFLAGS) -c $(DEFINES4) $(INCLUDES) $< + +# Dependencies: + +MAKEDEP = g++ -MM -MG +DEPFILE = .dependencies +$(DEPFILE): Makefile + @$(MAKEDEP) $(CXXFLAGS) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) $(OBJS2:%.o=%.c) $(OBJS3:%.o=%.c) $(OBJS4:%.o=%.c)> $@ + +-include $(DEPFILE) + +### Internationalization (I18N): + +PODIR = po +LOCALEDIR = $(VDRDIR)/locale +I18Npo = $(wildcard $(PODIR)/*.po) +I18Nmo = $(addsuffix .mo, $(foreach file, $(I18Npo), $(basename $(file)))) +I18Ndirs = $(notdir $(foreach file, $(I18Npo), $(basename $(file)))) +I18Npot = $(PODIR)/$(PLUGIN).pot +I18Nvdrmo = vdr-$(PLUGIN).mo +ifeq ($(strip $(APIVERSION)),1.5.7) + I18Nvdrmo = $(PLUGIN).mo +endif + +%.mo: %.po + msgfmt -c -o $@ $< + +$(I18Npot): $(wildcard *.[ch]) + xgettext -C -cTRANSLATORS --no-wrap -F -k -ktr -ktrNOOP --msgid-bugs-address='' -o $@ $(wildcard *.[ch]) + +$(I18Npo): $(I18Npot) + msgmerge -U --no-wrap -F --backup=none -q $@ $< + +i18n: $(I18Nmo) + @mkdir -p $(LOCALEDIR) + for i in $(I18Ndirs); do\ + mkdir -p $(LOCALEDIR)/$$i/LC_MESSAGES;\ + cp $(PODIR)/$$i.mo $(LOCALEDIR)/$$i/LC_MESSAGES/$(I18Nvdrmo);\ + done + +generate-i18n: i18n-template.h $(I18Npot) $(I18Npo) buildutil/pot2i18n.pl + buildutil/pot2i18n.pl $(I18Npot) i18n-template.h > i18n-generated.h + +### Targets: + +libvdr-$(PLUGIN).so: $(OBJS) + $(CXX) $(CXXFLAGS) -shared $(OBJS) $(LIBS) -o $@ + @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION) + +libvdr-$(PLUGIN2).so: $(OBJS2) + $(CXX) $(CXXFLAGS) -shared $(OBJS2) $(LIBS2) -o $@ + @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION) + +libvdr-$(PLUGIN3).so: $(OBJS3) + $(CXX) $(CXXFLAGS) -shared $(OBJS3) $(LIBS3) -o $@ + @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION) + +libvdr-$(PLUGIN4).so: $(OBJS4) + $(CXX) $(CXXFLAGS) -shared $(OBJS4) $(LIBS4) -o $@ + @cp --remove-destination $@ $(LIBDIR)/$@.$(APIVERSION) + +createcats: createcats.o Makefile + $(CXX) $(CXXFLAGS) createcats.o -o $@ + +dist: generate-i18n clean + @-rm -rf $(TMPDIR)/$(ARCHIVE) + @mkdir $(TMPDIR)/$(ARCHIVE) + @cp -a * $(TMPDIR)/$(ARCHIVE) + @-rm -rf $(TMPDIR)/$(ARCHIVE)/doc-src + @-rm -rf $(TMPDIR)/$(ARCHIVE)/html + @-rm -rf $(TMPDIR)/$(ARCHIVE)/docsrc2man.sh + @-rm -rf $(TMPDIR)/$(ARCHIVE)/docsrc2html.sh + @tar czf $(PACKAGE).tgz -C $(TMPDIR) $(ARCHIVE) + @-rm -rf $(TMPDIR)/$(ARCHIVE) + @echo Distribution package created as $(PACKAGE).tgz + +distfull: generate-i18n clean + @-rm -rf $(TMPDIR)/$(ARCHIVE) + @mkdir $(TMPDIR)/$(ARCHIVE) + @cp -a * $(TMPDIR)/$(ARCHIVE) + @tar czf $(PACKAGE).tgz -C $(TMPDIR) $(ARCHIVE) + @-rm -rf $(TMPDIR)/$(ARCHIVE) + @echo complete distribution package created as $(PACKAGE).tgz + +install-doc: + @mkdir -p $(MANDIR)/man1 + @mkdir -p $(MANDIR)/man4 + @mkdir -p $(MANDIR)/man5 + @mkdir -p $(MANDIR)/de/man1 + @mkdir -p $(MANDIR)/de/man5 + + @cp man/en/*1.gz $(MANDIR)/man1/ + @cp man/en/*4.gz $(MANDIR)/man4/ + @cp man/en/*5.gz $(MANDIR)/man5/ + @cp man/de/*1.gz $(MANDIR)/de/man1/ + @cp man/de/*5.gz $(MANDIR)/de/man5/ +clean: + @-rm -f $(PODIR)/*.mo $(PODIR)/*.pot $(PODIR)/*~ + @-rm -f $(OBJS) $(OBJS2) $(OBJS3) $(OBJS4) $(DEPFILE) *.so *.tgz core* *~ createcats createcats.o pod2*.tmp diff --git a/README b/README new file mode 120000 index 0000000..a720e53 --- /dev/null +++ b/README @@ -0,0 +1 @@ +doc/en/epgsearch.1.txt \ No newline at end of file diff --git a/README.DE b/README.DE new file mode 120000 index 0000000..244bfec --- /dev/null +++ b/README.DE @@ -0,0 +1 @@ +doc/de/epgsearch.1.txt \ No newline at end of file diff --git a/README.Translators b/README.Translators new file mode 100644 index 0000000..5682e64 --- /dev/null +++ b/README.Translators @@ -0,0 +1,44 @@ +--------------------------------------------------- +Building and maintaining translations for EPGSearch +--------------------------------------------------- + +If your language is not yet supported in EPGSearch or any +updates are needed it would be great if you could give your +support for this. + +To do so please follow these steps: + +1. Check if there is a current beta version of EPGSearch at + + http://winni.vdr-developer.org/epgsearch/downloads/beta + + If not please use the latest known release. + +2. Copy the original po file for your language to any backup + destination. Now edit the original po file for your language in + the po subdirectory. All entries with 'msgstr ""' should be filled + with your translation. + +3. To test your translations: + in vdr > 1.5.6: + simply recompile EPGSearch and check your changes. + in vdr < 1.5.7: + for backwards compatibility the translation is built from the + po files. To do so call + + make generate-i18n + + from EPGSearch's source directory and then recompile EPGSearch. + (this calls buildutil/pot2i18n.pl which may need to install Locale::PO + in the pearl cpan shell) + +4. When done please send me your po file or even better a patch for it, + created like + + cd po + diff -Nru /path-to-backup-po-file/x.po x.po > epgsearch_x.diff + + +Many thanks for your support + +Christian diff --git a/afuzzy.c b/afuzzy.c new file mode 100644 index 0000000..1a6792a --- /dev/null +++ b/afuzzy.c @@ -0,0 +1,271 @@ +/* +Copyright (C) 2004-2007 Christian Wieninger + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +Or, point your browser to http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + +The author can be reached at cwieninger@gmx.de + +The project's page is at http://winni.vdr-developer.org/epgsearch +*/ + +#include +#include +#include + +#include "afuzzy.h" + +static int afuzzy_checkFLT(const char *t, AFUZZY *fuzzy); + +/****************************************************************************** +FUNCTION afuzzy_init() + Initialization of the fuzzy search routine. This applies to the consequent + calls of the afuzzy_CheckRTR (whole string matching) and afuzzy_CheckSUB + (substring match) routines. afuzzy_init() should be called for each + new pattern or error length. The search is case sensitive + +ARGUMENTS: + p Pattern + kerr Number of possible errors. Shouldn't exceed pattern length + UseFilter Use agrep filter algorithm that speeds up search. + fuzzy pointer to the structure that will be later passes to Check* + (the first 6 elements should be NULLs for the first call) + +RETURN VALUE: + none + +ALGORITHM + see. the article on agrep algorithms. + The only change is accounting transpositions as one edit operation . +******************************************************************************/ +void afuzzy_init(const char *p, int kerr, int UseFilter, AFUZZY *fuzzy) +{ + int cnt, p_len, i, j, l, d, m, dd; + char PatFilter[sizeof(Uint)*8 + 1]; + + fuzzy->k = kerr; + m = strlen(p); + fuzzy->FilterSet = 0; + memset(fuzzy->Map, 0 , sizeof(fuzzy->Map) ); + + if (fuzzy->S) + free(fuzzy->S); + if (fuzzy->R) + free(fuzzy->R); + if (fuzzy->R1) + free(fuzzy->R1); + if (fuzzy->RP) + free(fuzzy->RP); + if (fuzzy->RI) + free(fuzzy->RI); + if (fuzzy->FilterS) + free(fuzzy->FilterS); + + fuzzy->FilterS = NULL; + fuzzy->S = (Uint *)calloc(m + 1, sizeof(Uint)); + fuzzy->R = (Uint *)calloc(fuzzy->k + 1, sizeof(Uint)); + fuzzy->R1 = (Uint *)calloc(fuzzy->k + 1, sizeof(Uint)); + fuzzy->RI = (Uint *)calloc(fuzzy->k + 1, sizeof(Uint)); + fuzzy->RP = (Uint *)calloc(fuzzy->k + 1, sizeof(Uint)); + + for (i = 0, cnt = 0; i < m; i++) + { + l = fuzzy->Map[(unsigned char)p[i]]; + if (!l) + { + l = fuzzy->Map[(unsigned char)p[i]] = ++cnt; + fuzzy->S[l] = 0; + } + fuzzy->S[l] |= 1 << i; + } + + + for (d = 0; d <= fuzzy->k; d++) + fuzzy->RI[d] = (1 << d) - 1; + + fuzzy->mask_ok = (1 << (m - 1)); + fuzzy->r_size = sizeof(Uint) * (fuzzy->k + 1); + p_len = m; + + if (p_len > (int) sizeof(Uint)*8) + p_len = (int) sizeof(Uint)*8; + + /* If k is zero then no filter is needed! */ + if (fuzzy->k && (p_len >= 2*(fuzzy->k + 1)) ) + { + if (UseFilter) + { + fuzzy->FilterSet = 1; + memset(fuzzy->FilterMap, 0 , sizeof(fuzzy->FilterMap) ); + fuzzy->FilterS = (Uint *)calloc(m + 1, sizeof(Uint)); + + /* Not let's fill the interleaved pattern */ + dd = p_len / (fuzzy->k + 1); + p_len = dd * (fuzzy->k + 1); + + for (i = 0, cnt = 0; i < dd; i++) + for (j = 0; j < fuzzy->k + 1; j++, cnt++) + PatFilter[cnt] = (unsigned char)p[j*dd + i]; + PatFilter[p_len] = 0; + + for (i = 0, cnt = 0; i < p_len; i++) + { + l = fuzzy->FilterMap[(unsigned char)PatFilter[i]]; + if (!l) + { + l = fuzzy->FilterMap[(unsigned char)PatFilter[i]] = ++cnt; + fuzzy->FilterS[l] = 0; + } + fuzzy->FilterS[l] |= 1 << i; + } + fuzzy->filter_ok = 0; + for (i = p_len - fuzzy->k - 1; i <= p_len - 1; i++) /* k+1 times */ + fuzzy->filter_ok |= 1 << i; + + /* k+1 first bits set to 1 */ + fuzzy->filter_shift = (1 << (fuzzy->k + 2)) - 1; + } + } +} + +/****************************************************************************** +FUNCTION afuzzy_free() + Cleaning up after previous afuzzy_init() call. + +ARGUMENTS: + fuzzy pointer to the afuzzy parameters structure + +RETURN VALUE: + none +******************************************************************************/ +void afuzzy_free(AFUZZY *fuzzy) +{ + if (fuzzy->S) + { + free(fuzzy->S); + fuzzy->S = NULL; + } + if (fuzzy->R) + { + free(fuzzy->R); + fuzzy->R = NULL; + } + if (fuzzy->R1) + { + free(fuzzy->R1); + fuzzy->R1 = NULL; + } + if (fuzzy->RP) + { + free(fuzzy->RP); + fuzzy->RP = NULL; + } + if (fuzzy->RI) + { + free(fuzzy->RI); + fuzzy->RI = NULL; + } + if (fuzzy->FilterS) + { + free(fuzzy->FilterS); + fuzzy->FilterS = NULL; + } +} + + +/****************************************************************************** +FUNCTION afuzzy_CheckSUB() + Perform a fuzzy pattern substring matching. afuzzy_init() should be + called previously to initialize the pattern and error length. + Positive result means that some part of the string given matches the + pattern with no more than afuzzy->k errors (1 error = 1 letter + replacement or transposition) + +ARGUMENTS: + t the string to test + fuzzy pointer to the afuzzy parameters structure + +RETURN VALUE: + 0 - no match + > 0 - strings match + +ALGORITHM + ???????????????? +******************************************************************************/ +int afuzzy_checkSUB(const char *t, AFUZZY *fuzzy) +{ + register char c; + register int j, d; + + /* For eficciency this case should be little bit optimized */ + if (!fuzzy->k) + { + Uint R = 0, R1; + + for (j = 0; (c = t[j]) != '\0'; j++) + { + R1 = ( ((R<<1) | 1) & fuzzy->S[fuzzy->Map[(unsigned char)c]]); + R = R1; + + if (R1 & fuzzy->mask_ok) + return 1; + } /* end for (register int j = 0 ... */ + return 0; + } + + if (fuzzy->FilterSet && !afuzzy_checkFLT(t, fuzzy)) + return 0; + + memcpy(fuzzy->R, fuzzy->RI, fuzzy->r_size); /* R = RI */ + + for (j = 0; (c = t[j]); j++) + { + for (d = 0; d <= fuzzy->k; d++) + { + fuzzy->R1[d] = (((fuzzy->R[d]<<1) | 1) & + fuzzy->S[fuzzy->Map[(unsigned char)c]]); + if (d > 0) + fuzzy->R1[d] |= ((fuzzy->R[d-1] | fuzzy->R1[d-1])<<1) | 1 | + fuzzy->R[d-1]; + } + if (fuzzy->R1[fuzzy->k] & fuzzy->mask_ok) + return j; + + memcpy(fuzzy->R, fuzzy->R1, fuzzy->r_size); + + } /* end for (register int j = 0 ... */ + + return 0; +} + +static int afuzzy_checkFLT(const char *t, AFUZZY *fuzzy) +{ + register Uint FilterR = 0; + register Uint FilterR1; + register int j; + + for (j = 0; t[j] != '\0'; j++) + { + FilterR1 = ( ((FilterR<<(fuzzy->k+1)) | fuzzy->filter_shift) & + fuzzy->FilterS[fuzzy->FilterMap[(unsigned char)t[j]]]); + if (FilterR1 & fuzzy->filter_ok) + return 1; + FilterR = FilterR1; + } /* end for (register int j = 0 ... */ + + return 0; +} + + diff --git a/afuzzy.h b/afuzzy.h new file mode 100644 index 0000000..f610602 --- /dev/null +++ b/afuzzy.h @@ -0,0 +1,65 @@ +/* +Copyright (C) 2004-2007 Christian Wieninger + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +Or, point your browser to http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + +The author can be reached at cwieninger@gmx.de + +The project's page is at http://winni.vdr-developer.org/epgsearch +*/ + +#ifndef _AFUZZY_H +#define _AFUZZY_H + +#include +// source from: +/* + Leonid Boitsov 2002. (itman@narod.ru) + C version of Stas Namin. + This code is a GPL software and is distributed under GNU + public licence without any warranty. +*/ + +typedef unsigned int Uint; + +#define MaxPatSize (sizeof(Uint) * 8) + +typedef struct +{ + Uint *R, + *R1, + *RP, + *S, + *RI; + Uint *FilterS; + + int Map[256]; + int FilterMap[256]; + int k; + Uint mask_ok; + Uint filter_ok; + Uint filter_shift; + int r_size; + int FilterSet; +} AFUZZY; + +void afuzzy_init(const char *p, int kerr, int UseFilter, AFUZZY *fuzzy); +void afuzzy_free(AFUZZY *fuzzy); +int afuzzy_checkSUB(const char *t, AFUZZY *fuzzy); + +#endif + + diff --git a/blacklist.c b/blacklist.c new file mode 100644 index 0000000..aff3211 --- /dev/null +++ b/blacklist.c @@ -0,0 +1,762 @@ +/* +Copyright (C) 2004-2007 Christian Wieninger + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +Or, point your browser to http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + +The author can be reached at cwieninger@gmx.de + +The project's page is at http://winni.vdr-developer.org/epgsearch +*/ + +#include +#include "epgsearchtools.h" +#include "blacklist.h" +#include "epgsearchcats.h" +#include +#include "menu_dirselect.h" +#include "changrp.h" +#include "menu_search.h" +#include "menu_searchedit.h" +#include "menu_searchresults.h" +#include +#ifdef HAVE_PCREPOSIX +#include +#else +#include +#endif + +cBlacklists Blacklists; + +// -- cBlacklist ----------------------------------------------------------------- +char *cBlacklist::buffer = NULL; + +cBlacklist::cBlacklist(void) +{ + ID = -1; + *search = 0; + options = 1; + useTime = false; + startTime = 0000; + stopTime = 2359; + useChannel = false; + channelMin = Channels.GetByNumber(cDevice::CurrentChannel()); + channelMax = Channels.GetByNumber(cDevice::CurrentChannel()); + channelGroup = NULL; + useCase = false; + mode = 0; + useTitle = true; + useSubtitle = true; + useDescription = true; + useDuration = false; + minDuration = 0; + maxDuration = 130; + useDayOfWeek = false; + DayOfWeek = 0; + buffer = NULL; + + useExtEPGInfo = false; + catvalues = (char**) malloc(SearchExtCats.Count() * sizeof(char*)); + cSearchExtCat *SearchExtCat = SearchExtCats.First(); + int index = 0; + while (SearchExtCat) + { + catvalues[index] = (char*)malloc(MaxFileName); + *catvalues[index] = 0; + SearchExtCat = SearchExtCats.Next(SearchExtCat); + index++; + } + ignoreMissingEPGCats = 0; + fuzzyTolerance = 1; +} + +cBlacklist::~cBlacklist(void) +{ + if (buffer) { + free(buffer); + buffer = NULL; + } + if (catvalues) + { + cSearchExtCat *SearchExtCat = SearchExtCats.First(); + int index = 0; + while (SearchExtCat) + { + free(catvalues[index]); + SearchExtCat = SearchExtCats.Next(SearchExtCat); + index++; + } + free(catvalues); + catvalues = NULL; + } +} + +cBlacklist& cBlacklist::operator= (const cBlacklist &Blacklist) +{ + memcpy(this, &Blacklist, sizeof(*this)); + catvalues = (char**) malloc(SearchExtCats.Count() * sizeof(char*)); + cSearchExtCat *SearchExtCat = SearchExtCats.First(); + int index = 0; + while (SearchExtCat) + { + catvalues[index] = (char*)malloc(MaxFileName); + *catvalues[index] = 0; + strcpy(catvalues[index], Blacklist.catvalues[index]); + SearchExtCat = SearchExtCats.Next(SearchExtCat); + index++; + } + return *this; +} + +void cBlacklist::CopyFromTemplate(const cSearchExt* templ) +{ + options = templ->options; + useTime = templ->useTime; + startTime = templ->startTime; + stopTime = templ->stopTime; + useChannel = templ->useChannel; + useCase = templ->useCase; + mode = templ->mode; + useTitle = templ->useTitle; + useSubtitle = templ->useSubtitle; + useDescription = templ->useDescription; + useDuration = templ->useDuration; + minDuration = templ->minDuration; + maxDuration = templ->maxDuration; + useDayOfWeek = templ->useDayOfWeek; + DayOfWeek = templ->DayOfWeek; + useExtEPGInfo = templ->useExtEPGInfo; + + cSearchExtCat *SearchExtCat = SearchExtCats.First(); + int index = 0; + while (SearchExtCat) + { + strcpy(catvalues[index], templ->catvalues[index]); + SearchExtCat = SearchExtCats.Next(SearchExtCat); + index++; + } + + channelMin = templ->channelMin; + channelMax = templ->channelMax; + if (channelGroup) + free(channelGroup); + if (templ->channelGroup) + channelGroup = strdup(templ->channelGroup); + fuzzyTolerance = templ->fuzzyTolerance; + ignoreMissingEPGCats = templ->ignoreMissingEPGCats; +} + +bool cBlacklist::operator< (const cListObject &ListObject) +{ + cBlacklist *BL = (cBlacklist *)&ListObject; + return strcasecmp(search, BL->search) < 0; +} + +const char *cBlacklist::ToText(void) +{ + char tmp_Start[5] = ""; + char tmp_Stop[5] = ""; + char tmp_minDuration[5] = ""; + char tmp_maxDuration[5] = ""; + char* tmp_chanSel = NULL; + char* tmp_search = NULL; + char* tmp_catvalues = NULL; + + free(buffer); + if (mode < 4 || mode == 5) // not a regular expression + asprintf(&tmp_search, "%s", search); + else if (mode ==4) + { + tmp_search = strdup(search); + while(strstr(tmp_search, "|")) + tmp_search = strreplace(tmp_search, "|", "!^pipe^!"); // ugly: replace with something, that should not happen to be part of a regular expression + } + strreplace(tmp_search, ':', '|'); + + if (useTime) + { + sprintf(tmp_Start, "%04d", startTime); + sprintf(tmp_Stop, "%04d", stopTime); + } + if (useDuration) + { + sprintf(tmp_minDuration, "%04d", minDuration); + sprintf(tmp_maxDuration, "%04d", maxDuration); + } + + if (useChannel==1) + { + if (channelMin->Number() < channelMax->Number()) + asprintf(&tmp_chanSel, "%s|%s", CHANNELSTRING(channelMin), CHANNELSTRING(channelMax)); + else + asprintf(&tmp_chanSel, "%s", CHANNELSTRING(channelMin)); + } + if (useChannel==2) + { + int channelGroupNr = ChannelGroups.GetIndex(channelGroup); + if (channelGroupNr == -1) + { + LogFile.eSysLog("channel group %s does not exist!", channelGroup); + useChannel = 0; + } + else + tmp_chanSel = strdup(channelGroup); + } + + if (useExtEPGInfo) + { + cSearchExtCat *SearchExtCat = SearchExtCats.First(); + int index = 0; + while (SearchExtCat) + { + char* catvalue = NULL; + asprintf(&catvalue, "%s", catvalues[index]); + while(strstr(catvalue, ":")) + catvalue = strreplace(catvalue, ":", "!^colon^!"); // ugly: replace with something, that should not happen to be part ofa category value + while(strstr(catvalue, "|")) + catvalue = strreplace(catvalue, "|", "!^pipe^!"); // ugly: replace with something, that should not happen to be part of a regular expression + + if (index == 0) + asprintf(&tmp_catvalues, "%d#%s", SearchExtCat->id, catvalue); + else + { + char* temp = tmp_catvalues; + asprintf(&tmp_catvalues, "%s|%d#%s", tmp_catvalues, SearchExtCat->id, catvalue); + free(temp); + } + SearchExtCat = SearchExtCats.Next(SearchExtCat); + index++; + free(catvalue); + } + } + + asprintf(&buffer, "%d:%s:%d:%s:%s:%d:%s:%d:%d:%d:%d:%d:%d:%s:%s:%d:%d:%d:%s:%d:%d", + ID, + tmp_search, + useTime, + tmp_Start, + tmp_Stop, + useChannel, + (useChannel>0 && useChannel<3)?tmp_chanSel:"0", + useCase, + mode, + useTitle, + useSubtitle, + useDescription, + useDuration, + tmp_minDuration, + tmp_maxDuration, + useDayOfWeek, + DayOfWeek, + useExtEPGInfo, + useExtEPGInfo?tmp_catvalues:"", + fuzzyTolerance, + ignoreMissingEPGCats); + + + if (tmp_chanSel) + free(tmp_chanSel); + if (tmp_search) + free(tmp_search); + if (tmp_catvalues) + free(tmp_catvalues); + + + return buffer; +} + +bool cBlacklist::Parse(const char *s) +{ + char *line; + char *pos; + char *pos_next; + int parameter = 1; + int valuelen; + char value[MaxFileName]; + + pos = line = strdup(s); + pos_next = pos + strlen(pos); + if (*pos_next == '\n') *pos_next = 0; + while (*pos) { + while (*pos == ' ') pos++; + if (*pos) { + if (*pos != ':') { + pos_next = strchr(pos, ':'); + if (!pos_next) + pos_next = pos + strlen(pos); + valuelen = pos_next - pos + 1; + if (valuelen > MaxFileName) valuelen = MaxFileName; + strn0cpy(value, pos, valuelen); + pos = pos_next; + switch (parameter) { + case 1: ID = atoi(value); + break; + case 2: strcpy(search, value); + break; + case 3: useTime = atoi(value); + break; + case 4: startTime = atoi(value); + break; + case 5: stopTime = atoi(value); + break; + case 6: useChannel = atoi(value); + break; + case 7: + if (useChannel == 0) + { + channelMin = NULL; + channelMax = NULL; + } + else if (useChannel == 1) + { + int minNum=0, maxNum=0; + int fields = sscanf(value, "%d-%d", &minNum, &maxNum); + if (fields == 0) // stored with ID + { + char *channelMinbuffer = NULL; + char *channelMaxbuffer = NULL; + int channels = sscanf(value, "%a[^|]|%a[^|]", &channelMinbuffer, &channelMaxbuffer); + channelMin = Channels.GetByChannelID(tChannelID::FromString(channelMinbuffer), true, true); + if (!channelMin) + { + LogFile.eSysLog("ERROR: channel %s not defined", channelMinbuffer); + channelMin = channelMax = NULL; + useChannel = 0; + } + if (channels == 1) + channelMax = channelMin; + else + { + channelMax = Channels.GetByChannelID(tChannelID::FromString(channelMaxbuffer), true, true); + if (!channelMax) + { + LogFile.eSysLog("ERROR: channel %s not defined", channelMaxbuffer); + channelMin = channelMax = NULL; + useChannel = 0; + } + } + free(channelMinbuffer); + free(channelMaxbuffer); + } + } + else if (useChannel == 2) + channelGroup = strdup(value); + break; + case 8: useCase = atoi(value); + break; + case 9: mode = atoi(value); + break; + case 10: useTitle = atoi(value); + break; + case 11: useSubtitle = atoi(value); + break; + case 12: useDescription = atoi(value); + break; + case 13: useDuration = atoi(value); + break; + case 14: minDuration = atoi(value); + break; + case 15: maxDuration = atoi(value); + break; + case 16: useDayOfWeek = atoi(value); + break; + case 17: DayOfWeek = atoi(value); + break; + case 18: useExtEPGInfo = atoi(value); + break; + case 19: + if (!ParseExtEPGValues(value)) + { + LogFile.eSysLog("ERROR reading ext. EPG values - 1"); + free(line); + return false; + } + break; + case 20: fuzzyTolerance = atoi(value); + break; + case 21: ignoreMissingEPGCats = atoi(value); + break; + } //switch + } + parameter++; + } + if (*pos) pos++; + } //while + + strreplace(search, '|', ':'); + while(strstr(search, "!^pipe^!")) + strreplace(search, "!^pipe^!", "|"); + + free(line); + return (parameter >= 19) ? true : false; +} + +bool cBlacklist::ParseExtEPGValues(const char *s) +{ + char *line; + char *pos; + char *pos_next; + int valuelen; + char value[MaxFileName]; + + pos = line = strdup(s); + pos_next = pos + strlen(pos); + if (*pos_next == '\n') *pos_next = 0; + while (*pos) { + while (*pos == ' ') pos++; + if (*pos) { + if (*pos != '|') { + pos_next = strchr(pos, '|'); + if (!pos_next) + pos_next = pos + strlen(pos); + valuelen = pos_next - pos + 1; + if (valuelen > MaxFileName) valuelen = MaxFileName; + strn0cpy(value, pos, valuelen); + pos = pos_next; + if (!ParseExtEPGEntry(value)) + { + LogFile.eSysLog("ERROR reading ext. EPG value: %s", value); + free(line); + return false; + } + } + } + if (*pos) pos++; + } //while + + free(line); + return true; +} + +bool cBlacklist::ParseExtEPGEntry(const char *s) +{ + char *line; + char *pos; + char *pos_next; + int parameter = 1; + int valuelen; + char value[MaxFileName]; + int currentid = -1; + + pos = line = strdup(s); + pos_next = pos + strlen(pos); + if (*pos_next == '\n') *pos_next = 0; + while (*pos) { + while (*pos == ' ') pos++; + if (*pos) { + if (*pos != '#') { + pos_next = strchr(pos, '#'); + if (!pos_next) + pos_next = pos + strlen(pos); + valuelen = pos_next - pos + 1; + if (valuelen > MaxFileName) valuelen = MaxFileName; + strn0cpy(value, pos, valuelen); + pos = pos_next; + switch (parameter) { + case 1: + { + currentid = atoi(value); + int index = SearchExtCats.GetIndexFromID(currentid); + if (index > -1) + strcpy(catvalues[index], ""); + } + break; + case 2: + if (currentid > -1) + { + int index = SearchExtCats.GetIndexFromID(currentid); + if (index > -1) + { + while(strstr(value, "!^colon^!")) + strreplace(value, "!^colon^!", ":"); + while(strstr(value, "!^pipe^!")) + strreplace(value, "!^pipe^!", "|"); + strcpy(catvalues[index], value); + } + } + break; + } //switch + } + parameter++; + } + if (*pos) pos++; + } //while + + free(line); + return (parameter >= 2) ? true : false; +} + +bool cBlacklist::Save(FILE *f) +{ + return fprintf(f, "%s\n", ToText()) > 0; +} + +cEvent * cBlacklist::GetEventByBlacklist(const cSchedule *schedules, const cEvent *Start, int MarginStop) +{ + cEvent *pe = NULL; + cEvent *p1 = NULL; + + if (Start) + p1 = schedules->Events()->Next(Start); + else + p1 = schedules->Events()->First(); + + time_t tNow=time(NULL); + char* szTest = NULL; + char* searchText = strdup(search); + + if (!useCase) + ToLower(searchText); + + int searchStart = 0, searchStop = 0; + if (useTime) + { + searchStart = startTime; + searchStop = stopTime; + if (searchStop < searchStart) + searchStop += 2400; + } + int minSearchDuration = 0; + int maxSearchDuration = 0; + if (useDuration) + { + minSearchDuration = minDuration/100*60 + minDuration%100; + maxSearchDuration = maxDuration/100*60 + maxDuration%100; + } + + for (cEvent *p = p1; p; p = schedules->Events()->Next(p)) + { + if(!p) + { + break; + } + + if (szTest) + { + free(szTest); + szTest = NULL; + } + + // ignore events without title + if (!p->Title() || strlen(p->Title()) == 0) + continue; + + asprintf(&szTest, "%s%s%s%s%s", (useTitle?p->Title():""), (useSubtitle||useDescription)?"~":"", + (useSubtitle?p->ShortText():""),useDescription?"~":"", + (useDescription?p->Description():"")); + + if (tNow < p->EndTime() + MarginStop * 60) + { + if (!useCase) + ToLower(szTest); + + if (useTime) + { + time_t tEvent = p->StartTime(); + struct tm tmEvent; + localtime_r(&tEvent, &tmEvent); + int eventStart = tmEvent.tm_hour*100 + tmEvent.tm_min; + int eventStart2 = tmEvent.tm_hour*100 + tmEvent.tm_min + 2400; + if ((eventStart < searchStart || eventStart > searchStop) && + (eventStart2 < searchStart || eventStart2 > searchStop)) + continue; + } + if (useDuration) + { + int duration = p->Duration()/60; + if (minSearchDuration > duration || maxSearchDuration < duration) + continue; + } + + if (useDayOfWeek) + { + time_t tEvent = p->StartTime(); + struct tm tmEvent; + localtime_r(&tEvent, &tmEvent); + if (DayOfWeek >= 0 && DayOfWeek != tmEvent.tm_wday) + continue; + if (DayOfWeek < 0) + { + int iFound = 0; + for(int i=0; i<7; i++) + if (abs(DayOfWeek) & (int)pow(2,i) && i == tmEvent.tm_wday) + { + iFound = 1; + break; + } + if (!iFound) + continue; + } + } + + if (strlen(szTest) > 0) + { + if (!MatchesSearchMode(szTest, searchText, mode," ,;|~", fuzzyTolerance)) + continue; + } + + if (useExtEPGInfo && !MatchesExtEPGInfo(p)) + continue; + pe=p; + break; + } + } + if (szTest) + free(szTest); + free(searchText); + return pe; +} + +// returns a pointer array to the matching search results +cSearchResults* cBlacklist::Run(cSearchResults* pSearchResults, int MarginStop) +{ + LogFile.Log(3,"start search for blacklist '%s'", search); + + cSchedulesLock schedulesLock; + const cSchedules *schedules; + schedules = cSchedules::Schedules(schedulesLock); + if(!schedules) { + LogFile.Log(1,"schedules are currently locked! try again later."); + return NULL; + } + + const cSchedule *Schedule = schedules->First(); + + while (Schedule) { + cChannel* channel = Channels.GetByChannelID(Schedule->ChannelID(),true,true); + if (!channel) + { + Schedule = (const cSchedule *)schedules->Next(Schedule); + continue; + } + + if (useChannel == 1 && channelMin && channelMax) + { + if (channelMin->Number() > channel->Number() || channelMax->Number() < channel->Number()) + { + Schedule = (const cSchedule *)schedules->Next(Schedule); + continue; + } + } + if (useChannel == 2 && channelGroup) + { + cChannelGroup* group = ChannelGroups.GetGroupByName(channelGroup); + if (!group || !group->ChannelInGroup(channel)) + { + Schedule = (const cSchedule *)schedules->Next(Schedule); + continue; + } + } + + if (useChannel == 3) + { + if (channel->Ca() >= CA_ENCRYPTED_MIN) + { + Schedule = (const cSchedule *)schedules->Next(Schedule); + continue; + } + } + + const cEvent *pPrevEvent = NULL; + do { + const cEvent* event = GetEventByBlacklist(Schedule, pPrevEvent, MarginStop); + pPrevEvent = event; + if (event && Channels.GetByChannelID(event->ChannelID(),true,true)) + { + if (!pSearchResults) pSearchResults = new cSearchResults; + pSearchResults->Add(new cSearchResult(event, this)); + } + } while(pPrevEvent); + Schedule = (const cSchedule *)schedules->Next(Schedule); + } + LogFile.Log(3,"found %d event(s) for blacklist '%s'", pSearchResults?pSearchResults->Count():0, search); + + return pSearchResults; +} + +bool cBlacklist::MatchesExtEPGInfo(const cEvent* e) +{ + if (!e || !e->Description()) + return false; + cSearchExtCat* SearchExtCat = SearchExtCats.First(); + while (SearchExtCat) + { + char* value = NULL; + int index = SearchExtCats.GetIndexFromID(SearchExtCat->id); + if (index > -1) + value = catvalues[index]; + if (value && strlen(value) > 0) + { + char* testvalue = GetExtEPGValue(e, SearchExtCat); + if (!testvalue) + return false; + + // compare not case sensitive + char* valueLower = strdup(value); + ToLower(valueLower); + ToLower(testvalue); + if (!MatchesSearchMode(testvalue, valueLower, SearchExtCat->searchmode, ",;|~", fuzzyTolerance)) + { + free(testvalue); + free(valueLower); + return false; + } + free(testvalue); + free(valueLower); + } + SearchExtCat = SearchExtCats.Next(SearchExtCat); + } + return true; +} + +// -- cBlacklists ---------------------------------------------------------------- +int cBlacklists::GetNewID() +{ + int newID = -1; + cMutexLock BlacklistLock(this); + cBlacklist *l = (cBlacklist *)First(); + while (l) { + newID = max(newID, l->ID); + l = (cBlacklist *)l->Next(); + } + return newID+1; +} + +cBlacklist* cBlacklists::GetBlacklistFromID(int ID) +{ + if (ID == -1) + return NULL; + cMutexLock BlacklistLock(this); + cBlacklist *l = (cBlacklist *)First(); + while (l) { + if (l->ID == ID) + return l; + l = (cBlacklist *)l->Next(); + } + return NULL; +} + +bool cBlacklists::Exists(const cBlacklist* Blacklist) +{ + cMutexLock BlacklistLock(this); + cBlacklist *l = (cBlacklist*)First(); + while (l) + { + if (l == Blacklist) + return true; + l = (cBlacklist*)l->Next(); + } + return false; +} diff --git a/blacklist.h b/blacklist.h new file mode 100644 index 0000000..f020011 --- /dev/null +++ b/blacklist.h @@ -0,0 +1,100 @@ +/* +Copyright (C) 2004-2007 Christian Wieninger + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +Or, point your browser to http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + +The author can be reached at cwieninger@gmx.de + +The project's page is at http://winni.vdr-developer.org/epgsearch +*/ + +#ifndef __EPGSEARCHBL_H +#define __EPGSEARCHBL_H + +#include + +class cSearchExt; +class cSearchResults; + +class cBlacklist : public cListObject { + friend class cMenuEditSearchExt; +public: + int ID; + char search[MaxFileName]; + int options; + int useTime; + int startTime; + int stopTime; + int useChannel; + cChannel *channelMin; + cChannel *channelMax; + char* channelGroup; + int useCase; + int mode; + int useTitle; + int useSubtitle; + int useDescription; + int useDuration; + int minDuration; + int maxDuration; + int useDayOfWeek; + int DayOfWeek; + int useEpisode; + int useExtEPGInfo; + int ignoreMissingEPGCats; + char** catvalues; + int fuzzyTolerance; + static char *buffer; +public: + cBlacklist(void); + virtual ~cBlacklist(void); + cBlacklist& operator= (const cBlacklist&); + virtual bool operator< (const cListObject &ListObject); + + const char *Search(void) { return search; } + int Options(void) { return options; } + int StartTime(void) { return startTime; } + int StopTime(void) { return stopTime; } + int UseChannel(void) { return useChannel; } + cChannel *ChannelMin(void) { return channelMin; } + cChannel *ChannelMax(void) { return channelMax; } + cEvent * GetEventByBlacklist(const cSchedule *schedules, const cEvent *Start, int MarginStop = 0); + bool MatchesExtEPGInfo(const cEvent* e); + const char *ToText(void); + bool Parse(const char *s); + bool ParseExtEPGValues(const char *s); + bool ParseExtEPGEntry(const char *s); + bool Save(FILE *f); + cSearchResults* Run(cSearchResults* pSearchResults = NULL, int MarginStop = 0); + void CopyFromTemplate(const cSearchExt* templ); +}; + +class cBlacklists : public cConfig, public cMutex { +public: + int GetNewID(void); + cBlacklist* GetBlacklistFromID(int ID); + bool Exists(const cBlacklist* Blacklist); +}; + +class cBlacklistObject: public cListObject { + public: + cBlacklist* blacklist; + cBlacklistObject(cBlacklist* Blacklist) : blacklist(Blacklist) {} +}; + +extern cBlacklists Blacklists; + +#endif diff --git a/buildutil/pot2i18n.pl b/buildutil/pot2i18n.pl new file mode 100755 index 0000000..600879b --- /dev/null +++ b/buildutil/pot2i18n.pl @@ -0,0 +1,157 @@ +#!/usr/bin/perl +# +# File: pot2i18n.pl - Convert plugin pot file into i18n.c-format +# Author: Dieter Hametner +# Version: 0.1 +# +# based on po2i18n.pl version 0.1 from Udo Richter +# +# See the po2i18n/README file for copyright information and how to +# reach the original author. Also general use is described there. +# +# This version uses the CPAN module Locale::PO to read the .pot and .po files +# which ensures, that these files are read correctly. +# +# The usage of pot2i18n.pl differs from po2i18n.pl that it requires as first +# argument the path to the plugins .pot file. There it then looks also for +# the translated .po files which are used to create the result. +# This version does not sort the msgids lexicaly (in contrast to po2i18n.pl) + +use strict; +use warnings; + +use Locale::PO; +use File::Basename; + +my @LANGS = ( + "en_US", + "de_DE", + "sl_SI", + "it_IT", + "nl_NL", + "pt_PT", + "fr_FR", + "nn_NO", + "fi_FI", + "pl_PL", + "es_ES", + "el_GR", + "sv_SE", + "ro_RO", + "hu_HU", + "ca_ES", + "ru_RU", + "hr_HR", + "et_EE", + "da_DK", + "cs_CZ", + "tr_TR" + ); + +my %VERS = ( + "en_US" => 10200, + "de_DE" => 10200, + "sl_SI" => 10200, + "it_IT" => 10200, + "nl_NL" => 10200, + "pt_PT" => 10200, + "fr_FR" => 10200, + "nn_NO" => 10200, + "fi_FI" => 10200, + "pl_PL" => 10200, + "es_ES" => 10200, + "el_GR" => 10200, + "sv_SE" => 10200, + "ro_RO" => 10200, + "hu_HU" => 10200, + "ca_ES" => 10200, + "ru_RU" => 10302, + "hr_HR" => 10307, + "et_EE" => 10313, + "da_DK" => 10316, + "cs_CZ" => 10342, + "tr_TR" => 10502 + ); + +die "Missing .pot file argument" unless $#ARGV >= 0; + +my $potfile = $ARGV[0]; +my $podir = dirname($potfile); + +my $potRef = Locale::PO->load_file_asarray($potfile); +shift; + +my %translations; + +foreach my $lang (@LANGS) { + $translations{$lang} = Locale::PO->load_file_ashash("$podir/$lang.po"); +} + +# debugging code: (may be removed) +#for my $po (@{$potRef}) { +# my $msgid = $po->msgid; +# +# print "UNTRANSLATED: ", $msgid, "\n"; +# next if $msgid eq "\"\""; +# foreach my $lang (@LANGS) { +# my $lhref = $translations{$lang}; +# my $lpo = ${$lhref}{$msgid}; +# $lpo = $po if !defined $lpo; +# +# my $msg = $lpo->msgstr; +# $msg = $lpo->msgid if !defined $msg; +# $msg = $msgid if ($lang eq "en_US"); +# print $lang, ": ", $msg, "\n"; +# } +# print "\n"; +#} +# +#exit; + +my $silent = 0; + +while (<>) { + my $line = $_; + + if ($line =~ /^\/\/ START I18N/) { + print "// START I18N - automatically generated by pot2i18n.pl\n"; + foreach my $po (@{$potRef}) { + my $msgid = $po->msgid; + next if $msgid eq "\"\""; + + my $head = " { "; + my $endif = ""; + my $versnum = 10200; + + for my $lang (@LANGS) { + if ($VERS{$lang} ne $versnum) { + $versnum = $VERS{$lang}; + print $endif; + print "#if VDRVERSNUM >= $versnum\n"; + $endif = "#endif\n"; + } + + my $lhref = $translations{$lang}; + my $lpo = ${$lhref}{$msgid}; + $lpo = $po if !defined $lpo; + + my $msgstr = $lpo->msgstr; + $msgstr = $lpo->msgid if !defined $msgstr; + $msgstr = $msgid if ($lang eq "en_US"); + + print "$head$msgstr,\n"; + $head = " "; + } + print $endif; + print " },\n"; + } + $silent = 1; + } + + if (!$silent) { print $line; } + + if ($line =~ /^\/\/ END I18N/) { + print "// END I18N - automatically generated by pot2i18n.pl\n"; + $silent = 0; + } +} diff --git a/changrp.c b/changrp.c new file mode 100644 index 0000000..14c91c7 --- /dev/null +++ b/changrp.c @@ -0,0 +1,528 @@ +/* +Copyright (C) 2004-2007 Christian Wieninger + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +Or, point your browser to http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + +The author can be reached at cwieninger@gmx.de + +The project's page is at http://winni.vdr-developer.org/epgsearch +*/ + +#include "changrp.h" +#include "epgsearchtools.h" +#include "epgsearchcfg.h" +#include "epgsearchext.h" +#include + +// -- cChannelGroup ----------------------------------------------------------------- +cChannelGroup::cChannelGroup(void) +{ + strcpy(name, ""); + channels.Clear(); +} + +cChannelGroup::~cChannelGroup(void) +{ + channels.Clear(); +} + +bool cChannelGroup::Parse(const char *s) +{ + char *line; + char *pos; + char *pos_next; + int parameter = 1; + int valuelen; +#define MAXVALUELEN (10 * MaxFileName) + + char value[MAXVALUELEN]; + + pos = line = strdup(s); + pos_next = pos + strlen(pos); + if (*pos_next == '\n') *pos_next = 0; + while (*pos) { + while (*pos == ' ') pos++; + if (*pos) { + if (*pos != '|') { + pos_next = strchr(pos, '|'); + if (!pos_next) + pos_next = pos + strlen(pos); + valuelen = pos_next - pos + 1; + if (valuelen > MAXVALUELEN) + { + LogFile.eSysLog("entry '%s' is too long. Will be truncated!", pos); + valuelen = MAXVALUELEN; + } + strn0cpy(value, pos, valuelen); + pos = pos_next; + switch (parameter) { + case 1: strcpy(name,value); + break; + default: + { + char *channelbuffer = NULL; + int numChannels = sscanf(value, "%a[^|]", &channelbuffer); + if (numChannels == 1) + { + cChannel* channel = Channels.GetByChannelID(tChannelID::FromString(channelbuffer), true, true); + if (channel) + { + cChannelGroupItem* channelitem = new cChannelGroupItem(channel); + channels.Add(channelitem); + } + } + free(channelbuffer); + } + break; + } //switch + } + parameter++; + } + if (*pos) pos++; + } //while + + free(line); + return (parameter >= 1) ? true : false; +} + +const char *cChannelGroup::ToText(void) +{ + char* channelbuffer = NULL; + cChannelGroupItem* ChannelGroupItem = channels.First(); + int index = 0; + while (ChannelGroupItem) + { + cChannel* channel = ChannelGroupItem->channel; + if (index++ == 0) + channelbuffer = strdup(CHANNELSTRING(channel)); + else + { + char* temp = channelbuffer; + asprintf(&channelbuffer, "%s|%s", channelbuffer, CHANNELSTRING(channel)); + free(temp); + } + ChannelGroupItem = channels.Next(ChannelGroupItem); + } + char* buffer = NULL; + asprintf(&buffer, "%s|%s", name, channelbuffer); + free(channelbuffer); + return buffer; +} + +int* cChannelGroup::CreateChannelSel() +{ + int* channelSel = (int*) malloc(Channels.Count() * sizeof(int)); + cChannel* channel = Channels.First(); + int index = 0; + while (channel) + { + if (channel->GroupSep()) + { + channel = Channels.Next(channel); + continue; + } + channelSel[index] = 0; + cChannelGroupItem* channelInGroup = channels.First(); + while (channelInGroup) + { + if (channel == channelInGroup->channel) + { + channelSel[index] = 1; + break; + } + channelInGroup = channels.Next(channelInGroup); + } + index++; + channel = Channels.Next(channel); + } + return channelSel; +} + +void cChannelGroup::CreateChannelList(int* channelSel) +{ + channels.Clear(); + cChannel* channel = Channels.First(); + int index = 0; + while (channel) + { + if (!channel->GroupSep()) + { + if (channelSel[index] == 1) + channels.Add(new cChannelGroupItem(channel)); + index++; + } + channel = Channels.Next(channel); + } +} + +bool cChannelGroup::Save(FILE *f) +{ + return fprintf(f, "%s\n", ToText()) > 0; +} + +bool cChannelGroup::ChannelInGroup(cChannel* channel) +{ + cChannelGroupItem* channelInGroup = channels.First(); + while (channelInGroup) + { + if (channel == channelInGroup->channel) + return true; + channelInGroup = channels.Next(channelInGroup); + } + return false; +} + +// -- cChannelGroups ----------------------------------------------------------------- +int cChannelGroups::GetIndex(char* channelGroup) +{ + if (!channelGroup) + return -1; + cChannelGroup* ChannelGroup = First(); + int index = 0; + while (ChannelGroup) + { + if (strcmp(channelGroup, ChannelGroup->name) == 0) + return index; + index++; + ChannelGroup = Next(ChannelGroup); + } + return -1; +} + +cChannelGroup* cChannelGroups::GetGroupByName(const char* channelGroup) +{ + if (!channelGroup) + return NULL; + cChannelGroup* ChannelGroup = First(); + while (ChannelGroup) + { + if (strcmp(channelGroup, ChannelGroup->name) == 0) + return ChannelGroup; + ChannelGroup = Next(ChannelGroup); + } + return NULL; +} + +cSearchExt* cChannelGroups::Used(cChannelGroup* group) +{ + if (!group) + return NULL; + + if (SearchExts.Count() == 0) + SearchExts.Load(AddDirectory(CONFIGDIR, "epgsearch.conf")); + + cMutexLock SearchExtsLock(&SearchExts); + cSearchExt *SearchExt = SearchExts.First(); + while (SearchExt) + { + if (SearchExt->useChannel == 2 && strcmp(SearchExt->channelGroup, group->name) == 0) + return SearchExt; + SearchExt = SearchExts.Next(SearchExt); + } + return NULL; +} + +char** cChannelGroups::CreateMenuitemsList() +{ + char** menuitemsChGr = new char*[ChannelGroups.Count()+1]; + cChannelGroup* ChannelGroup = First(); + menuitemsChGr[0] = strdup(""); + int index = 1; + while (ChannelGroup) + { + menuitemsChGr[index++] = ChannelGroup->name; + ChannelGroup = Next(ChannelGroup); + } + return menuitemsChGr; +} + +// -- cMenuChannelGroupItem ----------------------------------------------------------------- +cMenuChannelGroupItem::cMenuChannelGroupItem(cChannelGroup* Group) +{ + group = Group; + Set(); +} + +void cMenuChannelGroupItem::Set(void) +{ + char* channelbuffer = NULL; + + cChannelGroupItem* channelInGroup = group->channels.First(); + int channelNr, chIntBegin = -1, chIntEnd = -1, chLast = -1; + while (channelInGroup) + { + channelNr = channelInGroup->channel->Number(); + if (chIntBegin == -1) + chIntBegin = channelNr; + if (chIntEnd == -1) + chIntEnd = channelNr; + + if (chLast == channelNr-1) + chIntEnd = channelNr; + else + { + chIntEnd = chLast; + if(chIntBegin == chIntEnd) + asprintf(&channelbuffer, "%s %d", channelbuffer?channelbuffer:"", chIntBegin); + else if (chIntEnd != -1) + asprintf(&channelbuffer, "%s %d-%d", channelbuffer?channelbuffer:"", chIntBegin, chIntEnd); + chIntBegin = chIntEnd = channelNr; + } + + chLast = channelNr; + channelInGroup = group->channels.Next(channelInGroup); + if (!channelInGroup) + { + if(chLast == chIntBegin) + asprintf(&channelbuffer, "%s %d", channelbuffer?channelbuffer:"", chIntBegin); + else + asprintf(&channelbuffer, "%s %d-%d", channelbuffer?channelbuffer:"", chIntBegin, chLast); + } + } + + + char* buffer = NULL; + asprintf(&buffer, "%s\t%s", group->name, channelbuffer?channelbuffer:""); + free(channelbuffer); + SetText(buffer, false); +} + +// --- cMenuChannelGroups ---------------------------------------------------------- +cMenuChannelGroups::cMenuChannelGroups(char** GroupName) +:cOsdMenu(tr("Channel groups"),20) +{ + groupSel = -1; + groupName = GroupName; + if (groupName && *groupName) + groupSel = ChannelGroups.GetIndex(*groupName); + + cChannelGroup* ChannelGroup = ChannelGroups.First(); + int index = 0; + while (ChannelGroup) + { + Add(new cMenuChannelGroupItem(ChannelGroup), (index == groupSel?true:false)); + ChannelGroup = ChannelGroups.Next(ChannelGroup); + index++; + } + + if (groupName && *groupName) + SetHelp(trVDR("Button$Edit"), trVDR("Button$New"), trVDR("Button$Delete"), tr("Button$Select")); + else + SetHelp(trVDR("Button$Edit"), trVDR("Button$New"), trVDR("Button$Delete"), NULL); + Sort(); + Display(); +} + +cChannelGroup *cMenuChannelGroups::CurrentGroup(void) +{ + cMenuChannelGroupItem *item = (cMenuChannelGroupItem *)Get(Current()); + return item ? item->group : NULL; +} + +eOSState cMenuChannelGroups::New(void) +{ + if (HasSubMenu()) + return osContinue; + return AddSubMenu(new cMenuEditChannelGroup(new cChannelGroup, true)); +} + +eOSState cMenuChannelGroups::Delete(void) +{ + cChannelGroup *curGroup = CurrentGroup(); + if (curGroup) { + cSearchExt* search = ChannelGroups.Used(curGroup); + if (search) + { + char* Message = NULL; + asprintf(&Message, "%s %s", tr("Channel group used by:"), search->search); + Skins.Message(mtInfo, Message); + free(Message); + return osContinue; + } + if (Interface->Confirm(tr("Edit$Delete group?"))) { + ChannelGroups.Del(curGroup); + ChannelGroups.Save(); + cOsdMenu::Del(Current()); + Display(); + } + } + return osContinue; +} + +eOSState cMenuChannelGroups::ProcessKey(eKeys Key) +{ + int GroupNumber = HasSubMenu() ? Count() : -1; + + eOSState state = cOsdMenu::ProcessKey(Key); + if (state == osUnknown) + { + if (HasSubMenu()) + return osContinue; + switch (Key) + { + case kRed: + if (CurrentGroup()) + state = AddSubMenu(new cMenuEditChannelGroup(CurrentGroup())); + else + state = osContinue; + break; + case kGreen: state = New(); break; + case kYellow: state = Delete(); break; + + case kOk: + case kBlue: + if (groupName && *groupName) + { + free(*groupName); + *groupName = strdup(CurrentGroup()->name); + return osBack; + } + default: break; + } + } + if (GroupNumber >= 0 && !HasSubMenu() && ChannelGroups.Get(GroupNumber)) + { + // a newly created group was confirmed with Ok + cChannelGroup* group = ChannelGroups.Get(GroupNumber); + Add(new cMenuChannelGroupItem(group), true); + Display(); + } + + return state; +} + +// --- cMenuEditChannelGroup -------------------------------------------------------- +cMenuEditChannelGroup::cMenuEditChannelGroup(cChannelGroup *Group, bool New) +:cOsdMenu(tr("Edit channel group"),30) +{ + group = Group; + channelSel = group->CreateChannelSel(); + strcpy(name, group->name); + addIfConfirmed = New; + if (group) + Set(); +} + +cMenuEditChannelGroup::~cMenuEditChannelGroup() +{ + free(channelSel); +} + +void cMenuEditChannelGroup::Set() +{ + int current = Current(); + Clear(); + + Add(new cMenuEditStrItem( tr("Group name"), name, sizeof(group->name), trVDR(FileNameChars))); + cChannel* channel = Channels.First(); + int index = 0; + while (channel) + { + if (channel->GroupSep()) + { + channel = Channels.Next(channel); + continue; + } + Add(new cMenuEditBoolItem( CHANNELNAME(channel), &channelSel[index++], trVDR("no"), trVDR("yes"))); + channel = Channels.Next(channel); + } + + SetCurrent(Get(current)); + +} + +eOSState cMenuEditChannelGroup::ProcessKey(eKeys Key) +{ + eOSState state = cOsdMenu::ProcessKey(Key); + + const char* ItemText = Get(Current())->Text(); + if (strlen(ItemText) > 0 && strstr(ItemText, tr("Group name")) != ItemText) + SetHelp(tr("Button$Invert selection"), tr("Button$All yes"), tr("Button$All no"), NULL); + else if (!InEditMode(ItemText, tr("Group name"), name)) + SetHelp(NULL, NULL, NULL, NULL); + + if (state == osUnknown) { + switch (Key) { + case kOk: + if (strlen(name) == 0) + { + Skins.Message(mtError, tr("Group name is empty!")); + return osContinue; + } + if (addIfConfirmed && ChannelGroups.GetGroupByName(name)) + { + Skins.Message(mtError, tr("Group name already exists!")); + return osContinue; + } + + { + bool saveSearchExts = false; + if (strcmp(group->name, name) != 0 && !addIfConfirmed) // if group name changed, update searches + { + cMutexLock SearchExtsLock(&SearchExts); + cSearchExt *SearchExt = SearchExts.First(); + while (SearchExt) { + if (SearchExt->useChannel == 2 && + SearchExt->channelGroup && + strcmp(SearchExt->channelGroup, group->name) == 0) + { + free(SearchExt->channelGroup); + SearchExt->channelGroup = strdup(name); + } + SearchExt = SearchExts.Next(SearchExt); + } + saveSearchExts = true; // save them after groups are saved! + } + + strcpy(group->name, name); + group->CreateChannelList(channelSel); + if (addIfConfirmed) + ChannelGroups.Add(group); + ChannelGroups.Save(); + if (saveSearchExts) + SearchExts.Save(); + } + addIfConfirmed = false; + return osBack; + break; + case kRed: + case kGreen: + case kYellow: + { + cChannel* channel = Channels.First(); + int index = 0; + while (channel) + { + if (channel->GroupSep()) + { + channel = Channels.Next(channel); + continue; + } + + channelSel[index] = (Key == kGreen?1:(Key == kRed?1-channelSel[index]:0)); + index++; + channel = Channels.Next(channel); + } + Set(); + Display(); + return osContinue; + } + + default: break; + } + } + return state; +} diff --git a/changrp.h b/changrp.h new file mode 100644 index 0000000..7212ffd --- /dev/null +++ b/changrp.h @@ -0,0 +1,110 @@ +/* +Copyright (C) 2004-2007 Christian Wieninger + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +Or, point your browser to http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + +The author can be reached at cwieninger@gmx.de + +The project's page is at http://winni.vdr-developer.org/epgsearch +*/ + +#ifndef __EPGSEARCHCHANGRP_H +#define __EPGSEARCHCHANGRP_H + +#include +#include +#include + +class cSearchExt; + +// --- cChannelGroupItem -------------------------------------------------------- +class cChannelGroupItem : public cListObject { +public: + cChannel* channel; +public: + cChannelGroupItem(cChannel* ch) : channel(ch) {} +}; + +// --- cChannelGroup -------------------------------------------------------- +class cChannelGroup : public cListObject { +public: + char name[MaxFileName]; + cList channels; +public: + cChannelGroup(void); + virtual ~cChannelGroup(void); + + bool Parse(const char *s); + const char *ToText(void); + bool Save(FILE *f); + int* CreateChannelSel(); + void CreateChannelList(int*); + bool ChannelInGroup(cChannel*); +}; + +// --- cChannelGroups -------------------------------------------------------- +class cChannelGroups : public cConfig { +private: +public: + cChannelGroups(void) {} + ~cChannelGroups(void) {} + int GetIndex(char* channelGroup); + cChannelGroup* GetGroupByName(const char* channelGroup); + cSearchExt* Used(cChannelGroup*); + char** CreateMenuitemsList(); +}; + +extern cChannelGroups ChannelGroups; + +// --- cMenuChannelGroupItem ---------------------------------------------------------- +class cMenuChannelGroupItem : public cOsdItem { + private: +public: + cChannelGroup* group; + cMenuChannelGroupItem(cChannelGroup*); + void Set(void); + }; + +// --- cMenuChannelGroups -------------------------------------------------------- +class cMenuChannelGroups : public cOsdMenu { + private: + cChannelGroup *CurrentGroup(void); + eOSState New(void); + eOSState Delete(void); + int groupSel; + char** groupName; + + protected: + virtual eOSState ProcessKey(eKeys Key); + public: + cMenuChannelGroups(char** groupName = NULL); +}; + +// --- cMenuEditChannelGroup -------------------------------------------------------- +class cMenuEditChannelGroup : public cOsdMenu { +private: + cChannelGroup *group; + bool addIfConfirmed; + char name[MaxFileName]; + int* channelSel; +public: + cMenuEditChannelGroup(cChannelGroup *group, bool New = false); + ~cMenuEditChannelGroup(); + void Set(); + virtual eOSState ProcessKey(eKeys Key); +}; + +#endif diff --git a/conf/epgsearchcats.conf-epgdata b/conf/epgsearchcats.conf-epgdata new file mode 100644 index 0000000..ed1b7b0 --- /dev/null +++ b/conf/epgsearchcats.conf-epgdata @@ -0,0 +1,50 @@ +# ----------------------------------------------------------------------------- +# This is just a template based on your current epg.data. Please edit! +# Perhaps a category or its value list should be removed. Also the +# 'name in menu' should be adjusted to your language. +# The order of items determines the order listed in epgsearch. It does not +# depend on the ID, which is used by epgsearch. +# Format: +# ID|category name|name in menu|values separated by ',' (option)|searchmode (option) +# - 'ID' should be a unique positive integer +# (changing the id later on will force you to reedit your search timers!) +# - 'category name' is the name in your epg.data +# - 'name in menu' is the name displayed in epgsearch. +# - 'values' is an optional list of possible values +# - 'searchmode' is an optional parameter specifying the mode of search: +# text comparison: +# 0 - the whole term must appear as substring +# 1 - all single words (delimiters are ',', ';', '|' or '~') +# must exist as substrings. This is the default search mode. +# 2 - at least one word (delimiters are ',', ';', '|' or '~') +# must exist as substring. +# 3 - matches exactly +# 4 - regular expression +# numerical comparison: +# 10 - less +# 11 - less or equal +# 12 - greater +# 13 - greater or equal +# 14 - equal +# 15 - not equal +# ----------------------------------------------------------------------------- + +1|Category|Kategorie|Information,Kinder,Musik,Serie,Show,Spielfilm,Sport|3 + +2|Genre|Genre|Abenteuer,Action,Boxen,Comedy,Dokumentarfilm,Drama,Erotik,Familien-Show,Fantasy,Fussball,Geschichte,Gesellschaft,Gesundheit,Gymnastik,Handball,Heimat,Humor,Jazz,Kinderfilme,Kindernachrichten,Kinderserien,Klassik,Krankenhaus,Krimi,Kultur,Kurzfilm,Motor+Verkehr,Motorsport,Musik,Mystery,Nachrichten,Natur,Politik,Radsport,Ratgeber,Reise,Rock,Romantik/Liebe,Science Fiction,Soap,Spielshows,Talkshows,Tennis,Thriller,Verschiedenes,Volksmusik,Wassersport,Western,Wintersport,Wirtschaft,Wissen,Zeichentrick|2 + +3|Format|Video-Format|16:9,4:3|2 + +4|Audio|Audio|Dolby Surround,Stereo|2 + +5|Year|Jahr||0 + +6|Cast|Besetzung||2 + +7|Director|Regisseur||2 + +8|Moderation|Moderation||2 + +9|Rating|Bewertung|Tagestip,Tip|2 + +10|FSK|FSK|6,12,16,18|2 diff --git a/conf/epgsearchcats.conf-tvm2vdr-hoerzu b/conf/epgsearchcats.conf-tvm2vdr-hoerzu new file mode 100644 index 0000000..4b96d84 --- /dev/null +++ b/conf/epgsearchcats.conf-tvm2vdr-hoerzu @@ -0,0 +1,54 @@ +# ----------------------------------------------------------------------------- +# This is just a template based on your current epg.data. Please edit! +# Perhaps a category or its value list should be removed. Also the +# 'name in menu' should be adjusted to your language. +# The order of items determines the order listed in epgsearch. It does not +# depend on the ID, which is used by epgsearch. +# Format: +# ID|category name|name in menu|values separated by ',' (option)|searchmode (option) +# - 'ID' should be a unique positive integer +# (changing the id later on will force you to reedit your search timers!) +# - 'category name' is the name in your epg.data +# - 'name in menu' is the name displayed in epgsearch. +# - 'values' is an optional list of possible values +# - 'searchmode' is an optional parameter specifying the mode of search: +# text comparison: +# 0 - the whole term must appear as substring +# 1 - all single words (delimiters are ',', ';', '|' or '~') +# must exist as substrings. This is the default search mode. +# 2 - at least one word (delimiters are ',', ';', '|' or '~') +# must exist as substring. +# 3 - matches exactly +# 4 - regular expression +# numerical comparison: +# 10 - less +# 11 - less or equal +# 12 - greater +# 13 - greater or equal +# 14 - equal +# 15 - not equal +# ----------------------------------------------------------------------------- + +1|Category|Kategorie|Information,Kinder,Musik,Serie,Show,Spielfilm,Sport|3 + +2|Genre|Genre|Abenteuer,Action,Boxen,Comedy,Dokumentarfilm,Drama,Erotik,Familien-Show,Fantasy,Fussball,Geschichte,Gesellschaft,Gesundheit,Gymnastik,Handball,Heimat,Humor,Jazz,Kinderfilme,Kindernachrichten,Kinderserien,Klassik,Krankenhaus,Krimi,Kultur,Kurzfilm,Motor+Verkehr,Motorsport,Musik,Mystery,Nachrichten,Natur,Politik,Radsport,Ratgeber,Reise,Rock,Romantik/Liebe,Science Fiction,Soap,Spielshows,Talkshows,Tennis,Thriller,Verschiedenes,Volksmusik,Wassersport,Western,Wintersport,Wirtschaft,Wissen,Zeichentrick|2 + +3|Format|Video-Format|16:9,4:3|2 + +4|Audio|Audio|Dolby Surround,Dolby,Hoerfilm,Stereo|2 + +5|Year|Jahr||0 + +6|Cast|Besetzung||2 + +7|Director|Regisseur||2 + +8|Moderation|Moderation||2 + +9|Rating|Bewertung|Groartig besonders wertvoll,Groartig wertvoll,Groartig,Gelungen besonders wertvoll,Gelungen wertvoll,Gelungen,Annehmbar besonders wertvoll,Annehmbar wertvoll,besonders wertvoll,Annehmbar,Schwach|3 + +10|FSK|FSK|6,12,16,18|3 + +11|Country|Land||0 + +12|Episode|Episode||0 diff --git a/conf/epgsearchcats.conf-tvm2vdr-tvmovie b/conf/epgsearchcats.conf-tvm2vdr-tvmovie new file mode 100644 index 0000000..5140307 --- /dev/null +++ b/conf/epgsearchcats.conf-tvm2vdr-tvmovie @@ -0,0 +1,48 @@ +# ----------------------------------------------------------------------------- +# This is just a template based on your current epg.data. Please edit! +# Perhaps a category or its value list should be removed. Also the +# 'name in menu' should be adjusted to your language. +# The order of items determines the order listed in epgsearch. It does not +# depend on the ID, which is used by epgsearch. +# Format: +# ID|category name|name in menu|values separated by ',' (option)|searchmode (option) +# - 'ID' should be a unique positive integer +# (changing the id later on will force you to reedit your search timers!) +# - 'category name' is the name in your epg.data +# - 'name in menu' is the name displayed in epgsearch. +# - 'values' is an optional list of possible values +# - 'searchmode' is an optional parameter specifying the mode of search: +# text comparison: +# 0 - the whole term must appear as substring +# 1 - all single words (delimiters are ',', ';', '|' or '~') +# must exist as substrings. This is the default search mode. +# 2 - at least one word (delimiters are ',', ';', '|' or '~') +# must exist as substring. +# 3 - matches exactly +# 4 - regular expression +# numerical comparison: +# 10 - less +# 11 - less or equal +# 12 - greater +# 13 - greater or equal +# 14 - equal +# 15 - not equal +# ----------------------------------------------------------------------------- + +1|Category|Category|Film,Kultur,Serie,Show,Spielfilm,Sport|2 + +2|Genre|Genre|Abenteuer,Abenteuerkomdie,Action,Actiondrama,Action-Fantasy,Actionkomdie,Actionkrimi,Actionthriller,Animations,Anime,Ansprache,Arzt,Auslandsmagazin,Auslandsreportage,Automagazin,Ballett,Bericht,Bibelverfilmung,Bildungsprogramm,Biographie,Boulevardmagazin,Boxen,Bchermagazin,Brgersendung,Chart,Chronik,Clip,Clips,Comedy,Daily Soap,Dauerwerbesendung,Detektiv,Diskussion,Doku,Dokudrama,Doku-Drama,Dokumentar,Dokumentation,Doku-Soap,Drama,Dramedy,Ehedrama,Ehekomdie,Erotik,Erotikthriller,Familien,Familienchronik,Familiendrama,Familienkomdie,Fantasy,Fantasyabenteuer,Fantasykomdie,Fernseh,Festakt,Frauenmagazin,Frhmagazin,Fuball,Gala,Gehrlosenmagazin,Gerichts,Gesellschaftsdrama,Gesellschaftskomdie,Gesellschaftssatire,Gesprch,Gesundheitsmagazin,Gottesdienst,Groteske,Gruselkomdie,Heimat,Heimatmelodram,Historien,Historiendrama,Horror,Horrorkomdie,Horrorthriller,Impressionen,Informationen,Interview,Jazz,Jugend,Jugenddrama,Jugendmagazin,Jugendmemoiren,Justizdrama,Kabarett,Kammermusik,Katastrophen,Kinder,Kinderabenteuer,Kinder<80><94>Magazin,Kinderkomdie,Kinderkrimi,Kindermagazin,Kinder-Magazin,Kinomagazin,Klassik,Koch,Komdie,Konzert,Kriegs,Kriegsdrama,Krimi,Krimiabenteuer,Krimidrama,Krimikomdie,Kriminalmagazin,Kriminal-Magazin,Kulinarisches,Kulturmagazin,Kurz,Liebes,Liebeskomdie,Lifestylemagazin,Literaturverfilmung,Lotterie,Lustspiel,Magazin,Mrchen,Medienmagazin,Melodram,Militrsatire,Mittagsmagazin,Motorsport,Musical,Musicalverfilmung,Musik,Musikkomdie,Musikmagazin,Mystery,Mythen-Doku,Nachrichten,Nachrichtenmagazin,Naturdokumentation,nn,kokrimi,Oper,Politdrama,Politmagazin,Polit-Report,Politthriller,Polizei,Portrt,Prsentation,Predigt,Preisverleihung,Programminformation,Psychothriller,Puppen,Puppentrick,Quiz,Ratgeber,Reisedokumentation,Reisemagazin,Reisereportage,Reitsport,Religion,Reportage,Rock,Romanze,Sammelsendung,Satire,Satiremagazin,Schwank,schwarze Komdie,Science-fiction,Science-fiction-Film,Science-Fiction-Horror,Science-fiction-Komdie,Sitcom,Sitzung,Sketch,Slapstickkomdie,Sonstiges,Spiel,Sport,Sportmagazin,Sportsendung,Sprachkurs,Talk,Teenagerkomdie,Telenovela,Tennis,Theater,Thriller,Tier,Tier-doku,Tierdokumentation,Tiermagazin,Tragikomdie,Trick,Turnen,Umzug,Unterhaltung,Unterhaltungs,Unterhaltungsmusik,Verkaufs,Verkehrsmagazin,Volksmusik,Volkstheater,Vortrag,Weltmusik,Werbung,Western,Westerndrama,Wetter,Wirtschaftsmagazin,Wissenschaftsmagazin,Wochenmagazin,Zeichentrick,Zusammenfassung|2 + +3|Format|Format|4:3,16:9|3 + +4|Audio|Audio|Dolby,DolbyDigital, - O-Ton,Stereo,Stereo - O-Ton,Surround,Zweikanal|3 + +5|Year|Jahr||0 + +6|Cast|Darsteller||2 + +7|Director|Regisseur||2 + +8|Rating|Bewertung|TagesTipp,Tipp,TopTipp|2 + +9|FSK|FSK|3,4,5,6,7,8,9,12,16,18|3 diff --git a/conf/epgsearchconflmail.templ b/conf/epgsearchconflmail.templ new file mode 100644 index 0000000..265bf90 --- /dev/null +++ b/conf/epgsearchconflmail.templ @@ -0,0 +1,58 @@ +######################################################################### +# This is a sample template for email notifications about timer conflicts. +# +# There are 4 sections to be defined: +# - "subject" to be used as mail subject +# - "mailbody" the body of the mail (put %conflictss% in the place where the +# list of conflicts should appear!) +# - "conflictsat" the description of one time where one or more conflicts +# exists (put %confltimers% in the place where the list of conflict +# timers should appear!) +# - "confltimer" the description of one conflicting timer +# +# close each section with the correspondig end tag! +######################################################################### + + +######################################################################### +# here's the subject definition (no CR!) +######################################################################### +[epgsearch] timer conflict info: %conflict.count% conflicting timers! + + +######################################################################### +# here's the body definition +######################################################################### +information about conflicting timers +---------------------------------------------------------------------- + + check at: %datenow% %timenow% +conflicts: %conflict.count% + +---------------------------------------------------------------------- +%conflict.conflicts% + + +Have fun! + +######################################################################### +# here's the conflictsat definition +######################################################################### + +the following timers have a conflict at: %conflict.date% %conflict.time% +%conflict.confltimers% + + + + +######################################################################### +# here's the definition of a conflict timer +######################################################################### + + Title: %title% ~ %subtitle% +Start/End: %time_w% %date% %time%-%timeend% (Timer: %timer.start%-%timer.stop%) + Channel: %chlng% (%chnr%) + File: %timer.file% + Search: %timer.search% (%timer.searchid%) +---------------------------------------------------------------------- + diff --git a/conf/epgsearchmenu.conf b/conf/epgsearchmenu.conf new file mode 100644 index 0000000..3d3658d --- /dev/null +++ b/conf/epgsearchmenu.conf @@ -0,0 +1,37 @@ +######################################################### +# sample file for epgsearchmenu.conf +# +# The following variables exist: +# +# %time% - start time in format HH:MM +# %date% - start date in format TT.MM.YY +# %datesh% - start date in format TT.MM. +# %time_w% - weekday name +# %time_d% - start day in format TT +# %title% - title +# %subtitle% - subtitle +# %t_status% - timer status ('T', 't', 'R') +# %v_status% - VPS status +# %r_status% - running status +# %status% - complete status, the same as +# '%t_status%%v_status%%r_status%' +# %colon% - the sign ':' +# %% - a value from the extended EPG categories, specified in +# epgsearchcats.conf, like %genre% or %category% +# +# for the 'Whats on...' menus there is also: +# +# %chnr% - channel number +# %chsh% - the short channel name +# %chlng% - the 'normal' channel name +# %progr% - graphical progress bar +# %progrT2S% - progress bar in text2skin style +# +######################################################### + +MenuWhatsOnNow= %chnr%:4|%progrt2s%:5| %time% %t_status%:8|%category%:6| %title% ~ %subtitle%:35 +MenuWhatsOnNext=%chnr%:4|%time% %t_status%:8|%category%:8| %title% ~ %subtitle%:35 +MenuWhatsOnElse=%chnr%:4|%time% %t_status%:8|%category%:8| %title% ~ %subtitle%:35 +MenuSchedule=%time% %t_status%:8|%genre%:14| %title% ~ %subtitle%:35 +MenuSearchResults=%chsh%:12|%datesh%:6|%time%:6|%t_status%:2|%title% ~ %subtitle%:35 +# WarEagleIcons=1 \ No newline at end of file diff --git a/conf/epgsearchupdmail-html.templ b/conf/epgsearchupdmail-html.templ new file mode 100644 index 0000000..15accd0 --- /dev/null +++ b/conf/epgsearchupdmail-html.templ @@ -0,0 +1,157 @@ +######################################################################### +# This is a sample template for email notifications about timer changes +# (NOTE: This is a sample for a HTML mail, but you could use only text +# as well) +# +# There are 3 sections that have to be defined: +# - "subject" to be used as mail subject +# - "mailbody" the body of the mail: +# put %update.newtimers% in the place where the list of new timers should +# appear. The same for %update.modtimers% and %update.deltimers% for the +# list of changed or deleted timers. +# - "timer" the description of one timer. This section is used to display one +# timer within a timer list, e.g. in %update.newtimers% +# +# close each section with the corresponding end tag! +# Please have a look at the MANUAL for the available variables. +######################################################################### +# +# Version: 0.3 Date: 24.09.2006 +# +# Author: Mike Constabel +# Christian Wieninger +# +######################################################################### + +######################################################################### +# here's the mail's subject definition (no CR!) +######################################################################### +[epgsearch] update info: %update.countnewtimers% new / %update.countmodtimers% modified / %update.countdeltimers% deleted timers + + +######################################################################### +# here's the mail's body definition +######################################################################### + + + +Information about search timer update + + + + + + + + + + + +
Information about search timer update
update at:%datenow% %timenow%
new timers:%update.countnewtimers%
modified timers:%update.countmodtimers%
deleted timers:%update.countdeltimers%
+ +

+ + + + +
Top New timers
%update.newtimers%
+ +

+ + + + +
Top Modified timers
%update.modtimers%
+ +

+ + + + +
Top Deleted timers
%update.deltimers%
+ +

+ +

Have fun!

+ +
+ +############################################################################## +# here's the timer definition, which is used to display information about +# a timer within one of the timer lists. You can use any variables that refer +# to an event or timer. (Please note, that a timer may have no event assigned +# to it, resulting in an empty variable substitution!). You can also use 'user +# defined' variables from epgsearchuservars.conf. +############################################################################## + + + + + + + + + +
Title:%title%
Subtitle:%subtitle%
Start/End:%time_w% %date% %time%-%timeend% (Timer: %timer.start%-%timer.stop%)
Channel:%timer.chlng% (%timer.chnr%)
File:%timer.file%
Search:%timer.search% (%timer.searchid%)
Summary:%htmlsummary%
+

+
diff --git a/conf/epgsearchupdmail.templ b/conf/epgsearchupdmail.templ new file mode 100644 index 0000000..b79e98b --- /dev/null +++ b/conf/epgsearchupdmail.templ @@ -0,0 +1,68 @@ +######################################################################### +# This is a sample template for email notifications about timer changes +# (NOTE: This is a sample for a text mail, but you could use HTML as well) +# +# There are 3 sections that have to be defined: +# - "subject" to be used as mail subject +# - "mailbody" the body of the mail: +# put %update.newtimers% in the place where the list of new timers should +# appear. The same for %update.modtimers% and %update.deltimers% for the +# list of changed or deleted timers. +# - "timer" the description of one timer. This section is used to display one +# timer within a timer list, e.g. in %update.newtimers% +# +# close each section with the correspondig end tag! +# Please have a look at the MANUAL for the available variables. +######################################################################### + + +######################################################################### +# here's the mail's subject definition (no CR!) +######################################################################### +[epgsearch] update info: %update.countnewtimers% new / %update.countmodtimers% modified / %update.countdeltimers% deleted timers + + +######################################################################### +# here's the mail's body definition +######################################################################### +information about search timer update +---------------------------------------------------------------------- + + update at: %datenow% %timenow% + new timers: %update.countnewtimers% +modified timers: %update.countmodtimers% + deleted timers: %update.countdeltimers% + +the following timers have been added: +---------------------------------------------------------------------- +%update.newtimers% + +the following timers have been modified: +---------------------------------------------------------------------- +%update.modtimers% + +the following timers have been deleted: +---------------------------------------------------------------------- +%update.deltimers% + +Have fun! + +############################################################################## +# here's the timer definition, which is used to display information about +# a timer within one of the timer lists. You can use any variables that refer +# to an event or timer. (Please note, that a timer may have no event assigned +# to it, resulting in an empty variable substitution!). You can also use 'user +# defined' variables from epgsearchuservars.conf. +############################################################################## + + Title: %title% ~ %subtitle% +Start/End: %time_w% %date% %time%-%timeend% (Timer: %timer.start%-%timer.stop%) + Channel: %timer.chlng% (%timer.chnr%) + File: %timer.file% + Search: %timer.search% (%timer.searchid%) + + +Summary: +%summary% +---------------------------------------------------------------------- + diff --git a/conflictcheck.c b/conflictcheck.c new file mode 100644 index 0000000..d783f8a --- /dev/null +++ b/conflictcheck.c @@ -0,0 +1,648 @@ +/* +Copyright (C) 2004-2007 Christian Wieninger + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +Or, point your browser to http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + +The author can be reached at cwieninger@gmx.de + +The project's page is at http://winni.vdr-developer.org/epgsearch +*/ + +#include +#include +#include "conflictcheck.h" +#include "epgsearchcfg.h" +#include +#include "conflictcheck_thread.h" +#include "recstatus.h" + +#define FULLMATCH 1000 +#define EPGLIMITBEFORE (1 * 3600) // Time in seconds before a timer's start time and +#define EPGLIMITAFTER (1 * 3600) // after its stop time within which EPG events will be taken into consideration. + +// --- cConflictCheckTimerObj -------------------------------------------------------- +cConflictCheckTimerObj::cConflictCheckTimerObj(cTimer* Timer, time_t Start, time_t Stop, int Device) : cTimerObj(Timer), start(Start), stop(Stop), device(Device), conflCheckTime(NULL), concurrentTimers(NULL), ignore(false) +{ + event = Timer->Event(); + recDuration = 0; + lastRecStart = 0; + lastRecStop = 0; +} + +int cConflictCheckTimerObj::Compare(const cListObject &ListObject) const +{ + cConflictCheckTimerObj *p = (cConflictCheckTimerObj *)&ListObject; + long diff = start - p->start; + if (diff == 0) + diff = p->timer->Priority() - timer->Priority(); + if (diff == 0) + diff = timer->Index() - p->timer->Index(); + return diff; +} + +const cEvent* cConflictCheckTimerObj::Event() +{ + if(timer->Event()) + return timer->Event(); + else + if (!event) + event = SetEventFromSchedule(); + return event; +} + +const cEvent* cConflictCheckTimerObj::SetEventFromSchedule() +{ + cSchedulesLock SchedulesLock; + const cSchedules* Schedules = NULL; + if (!(Schedules = cSchedules::Schedules(SchedulesLock))) + return NULL; + + const cSchedule *Schedule = Schedules->GetSchedule(timer->Channel()); + if (Schedule && Schedule->Events()->First()) + { + const cEvent *Event = NULL; + if (timer->HasFlags(tfVps) && Schedule->Events()->First()->Vps()) + { + // VPS timers only match if their start time exactly matches the event's VPS time: + for (const cEvent *e = Schedule->Events()->First(); e; e = Schedule->Events()->Next(e)) + { + if (e->StartTime() && e->RunningStatus() != SI::RunningStatusNotRunning) + { // skip outdated events + int overlap = 0; + Matches(e, &overlap); + if (overlap > FULLMATCH) { + Event = e; + break; // take the first matching event + } + } + } + } + else + { + // Normal timers match the event they have the most overlap with: + int Overlap = 0; + // Set up the time frame within which to check events: + timer->Matches(0, true); + time_t TimeFrameBegin = start - EPGLIMITBEFORE; + time_t TimeFrameEnd = stop + EPGLIMITAFTER; + for (const cEvent *e = Schedule->Events()->First(); e; e = Schedule->Events()->Next(e)) + { + if (e->EndTime() < TimeFrameBegin) + continue; // skip events way before the timer starts + if (e->StartTime() > TimeFrameEnd) + break; // the rest is way after the timer ends + int overlap = 0; + Matches(e, &overlap); + if (overlap && overlap >= Overlap) + { + if (Event && overlap == Overlap && e->Duration() <= Event->Duration()) + continue; // if overlap is the same, we take the longer event + Overlap = overlap; + Event = e; + } + } + } + return Event; + } + return NULL; +} + +int cConflictCheckTimerObj::Matches(const cEvent *Event, int *Overlap) const +{ + // Overlap is the percentage of the Event's duration that is covered by + // this timer (based on FULLMATCH for finer granularity than just 100). + // To make sure a VPS timer can be distinguished from a plain 100% overlap, + // it gets an additional 100 added, and a VPS event that is actually running + // gets 200 added to the FULLMATCH. + if (timer->Channel()->GetChannelID() == Event->ChannelID()) { + bool UseVps = timer->HasFlags(tfVps) && Event->Vps(); + timer->Matches(UseVps ? Event->Vps() : Event->StartTime(), true); + int overlap = 0; + if (UseVps) + overlap = (start == Event->Vps()) ? FULLMATCH + (Event->IsRunning() ? 200 : 100) : 0; + if (!overlap) { + if (start <= Event->StartTime() && Event->EndTime() <= stop) + overlap = FULLMATCH; + else if (stop <= Event->StartTime() || Event->EndTime() <= start) + overlap = 0; + else + overlap = (min(stop, Event->EndTime()) - max(start, Event->StartTime())) * FULLMATCH / max(Event->Duration(), 1); + } + if (Overlap) + *Overlap = overlap; + if (UseVps) + return overlap > FULLMATCH ? tmFull : tmNone; + return overlap >= FULLMATCH ? tmFull : overlap > 0 ? tmPartial : tmNone; + } + return tmNone; +} + +// --- cConflictCheck ------------------------------------------------------- +cConflictCheck::cConflictCheck() +{ + evaltimeList = NULL; + timerList = NULL; + failedList = NULL; + relevantConflicts = 0; + numConflicts = 0; + devices = NULL; + InitDevicesInfo(); +} + +cConflictCheck::~cConflictCheck() +{ + if (evaltimeList) + { + evaltimeList->Clear(); + DELETENULL(evaltimeList); + } + if (timerList) + { + timerList->Clear(); + DELETENULL(timerList); + } + if (devices) + delete [] devices; +} + +void cConflictCheck::InitDevicesInfo() +{ + devices = new cConflictCheckDevice[MAXDEVICES]; +#ifdef DEBUG_CONFL + numDevices = 2; + for(int i=0; iFirst(); checkTime; checkTime = failedList->Next(checkTime)) + { + LogFile.Log(2,"result of conflict check for %s:", DAYDATETIME(checkTime->evaltime)); + std::set::iterator it; + for (it = checkTime->failedTimers.begin(); it != checkTime->failedTimers.end(); it++) + LogFile.Log(2,"timer '%s' (%s, channel %s) failed", (*it)->timer->File(), DAYDATETIME((*it)->timer->StartTime()), CHANNELNAME((*it)->timer->Channel())); + } + } +} + +cList* cConflictCheck::CreateCurrentTimerList() +{ + cList* CurrentTimerList = NULL; + + // collect single event timers + time_t tMax = 0; + cTimer* ti = NULL; + for (ti = Timers.First(); ti; ti = Timers.Next(ti)) + { + tMax = max(tMax, ti->StartTime()); + if (!ti->IsSingleEvent()) continue; + // already recording? + int deviceNr = gl_recStatusMonitor->TimerRecDevice(ti)-1; + cConflictCheckTimerObj* timerObj = new cConflictCheckTimerObj(ti, ti->StartTime(), ti->StopTime(), deviceNr); + if (deviceNr >= 0) + { + devices[deviceNr].recTimers.insert(timerObj); + timerObj->lastRecStart = ti->StartTime(); + } + LogFile.Log(3,"add timer '%s' (%s, channel %s) for conflict check", ti->File(), DAYDATETIME(ti->StartTime()), CHANNELNAME(ti->Channel())); + if (deviceNr >= 0) + LogFile.Log(3,"timer already recording since %s on device %d", DAYDATETIME(ti->StartTime()), deviceNr+1); + + if (!CurrentTimerList) CurrentTimerList = new cList; + CurrentTimerList->Add(timerObj); + } + + // collect repeating timers from now until the date of the timer with tMax + time_t maxCheck = time(NULL) + EPGSearchConfig.checkMaxDays * SECSINDAY; + tMax = max(tMax, maxCheck); + for (ti = Timers.First(); ti; ti = Timers.Next(ti)) + { + if (ti->IsSingleEvent()) continue; + time_t day = time(NULL); + while(day < tMax) + { + if (ti->DayMatches(day)) + { + time_t Start = cTimer::SetTime(day, cTimer::TimeToInt(ti->Start())); + int deviceNr = -1; + if (Start < time(NULL)) + { +#ifndef DEBUG_CONFL + if (ti->Recording()) + deviceNr = gl_recStatusMonitor->TimerRecDevice(ti)-1; +#else + if (Start + ti->StopTime() - ti->StartTime() > time(NULL)) + deviceNr = 0; +#endif + if (deviceNr == -1) // currently not recording, skip it + { + day += SECSINDAY; + continue; + } + } + else if (Start < ti->StartTime()) + { + day += SECSINDAY; + continue; + } + cConflictCheckTimerObj* timerObj = new cConflictCheckTimerObj(ti, Start, Start + ti->StopTime() - ti->StartTime(), deviceNr); + LogFile.Log(3,"add timer '%s' (%s, channel %s) for conflict check", ti->File(), DAYDATETIME(Start), CHANNELNAME(ti->Channel())); + if (deviceNr >= 0) + { + LogFile.Log(3,"timer already recording since %s on device %d", DAYDATETIME(Start), deviceNr+1); + devices[deviceNr].recTimers.insert(timerObj); + timerObj->lastRecStart = Start; + } + if (!CurrentTimerList) CurrentTimerList = new cList; + CurrentTimerList->Add(timerObj); + } + day += SECSINDAY; + } + } + + if (CurrentTimerList) CurrentTimerList->Sort(); + return CurrentTimerList; +} + +// create a list of all times that have to be checked +cList* cConflictCheck::CreateEvaluationTimeList(cList* TimerList) +{ + LogFile.Log(3,"create check time list"); + cList* EvalTimeList = NULL; + for(cConflictCheckTimerObj* TimerObj= TimerList->First(); TimerObj; TimerObj = TimerList->Next(TimerObj)) + { + if (!TimerObj->timer->HasFlags(tfActive)) continue; + + if (!EvalTimeList) EvalTimeList = new cList; + + cConflictCheckTime* checkTime = NULL; + + // add all timer start times + for(cConflictCheckTime* checkTimeTest = EvalTimeList->First(); checkTimeTest; checkTimeTest = EvalTimeList->Next(checkTimeTest)) + { + if (checkTimeTest->evaltime == TimerObj->start) + { + checkTime = checkTimeTest; + break; + } + } + if (!checkTime) + { + checkTime = new cConflictCheckTime(TimerObj->start); + EvalTimeList->Add(checkTime); + } + checkTime->startingTimers.insert(TimerObj); + + + // add all timer stop times + checkTime = NULL; + for(cConflictCheckTime* checkTimeTest = EvalTimeList->First(); checkTimeTest; checkTimeTest = EvalTimeList->Next(checkTimeTest)) + { + if (checkTimeTest->evaltime == TimerObj->stop) + { + checkTime = checkTimeTest; + break; + } + } + if (!checkTime) + { + checkTime = new cConflictCheckTime(TimerObj->stop); + EvalTimeList->Add(checkTime); + } + checkTime->stoppingTimers.insert(TimerObj); + } + if (EvalTimeList) + EvalTimeList->Sort(); + + LogFile.Log(3,"create check time list - done"); + return EvalTimeList; +} + +// this return a list of all conflicts +cList* cConflictCheck::CreateConflictList(cList* EvalTimeList, cList* TimerList) +{ + LogFile.Log(3,"create conflict list"); + relevantConflicts = 0; + numConflicts = 0; + maxCheck = time(NULL) + EPGSearchConfig.checkMaxDays * SECSINDAY; + + // check each time + for(cConflictCheckTime* checkTime = EvalTimeList->First(); checkTime; checkTime = EvalTimeList->Next(checkTime)) + { + int Conflicts = ProcessCheckTime(checkTime); + if (Conflicts > 0) // if there were conflicts do a retry as VDR would do a few seconds after the conflict + { + LogFile.Log(3,"retry check time %s", DAYDATETIME(checkTime->evaltime)); + int OldConflicts = Conflicts; + while(true) + { + Conflicts = ProcessCheckTime(checkTime); + if (Conflicts == OldConflicts) break; // no change after retry? + OldConflicts = Conflicts; + }; + } + } + + nextRelevantConflictDate = 0; + for(cConflictCheckTime* checkTime = EvalTimeList->First(); checkTime;) // clear the list + { + cConflictCheckTime* checkTimeNext = EvalTimeList->Next(checkTime); + if (checkTime->failedTimers.size() == 0) + EvalTimeList->Del(checkTime); + else + { + bool allTimersIgnored = true; + std::set::iterator it; + for (it = checkTime->failedTimers.begin(); it != checkTime->failedTimers.end(); it++) + { + numConflicts++; + if (!(*it)->ignore) + { + if (!nextRelevantConflictDate) + nextRelevantConflictDate = checkTime->evaltime; + else + nextRelevantConflictDate = min(nextRelevantConflictDate, checkTime->evaltime); + + relevantConflicts++; + allTimersIgnored = false; + break; + } + } + if (allTimersIgnored) + checkTime->ignore = true; + } + checkTime = checkTimeNext; + } + + // store for external access + cConflictCheckThread::m_cacheNextConflict = nextRelevantConflictDate; + cConflictCheckThread::m_cacheRelevantConflicts = relevantConflicts; + cConflictCheckThread::m_cacheTotalConflicts = numConflicts; + + LogFile.Log(3,"create conflict list - done"); + return EvalTimeList; +} + +// checks for conflicts at one special time +int cConflictCheck::ProcessCheckTime(cConflictCheckTime* checkTime) +{ + if (!checkTime) return 0; + LogFile.Log(3,"check time %s", DAYDATETIME(checkTime->evaltime)); + + LogFile.Log(3,"detach stopping timers"); + int Conflicts = 0; + // detach all stopping timers from their devices + std::set::iterator it; + for (it = checkTime->stoppingTimers.begin(); it != checkTime->stoppingTimers.end(); it++) + if ((*it) && (*it)->device >= 0) + { + LogFile.Log(3,"detach device %d from timer '%s' (%s, channel %s) at %s", (*it)->device, (*it)->timer->File(), DAYDATETIME((*it)->start), CHANNELNAME((*it)->timer->Channel()), DAYDATETIME(checkTime->evaltime)); + devices[(*it)->device].recTimers.erase(*it); + (*it)->lastRecStop = checkTime->evaltime; + if ((*it)->lastRecStart > 0 && (*it)->lastRecStart < (*it)->lastRecStop) + { + (*it)->recDuration += (*it)->lastRecStop - (*it)->lastRecStart; + (*it)->lastRecStart = 0; + if (((*it)->stop - (*it)->start - (*it)->recDuration) < EPGSearchConfig.checkMinDuration * 60) + (*it)->ignore = true; + } + } + + LogFile.Log(3,"add pending timers"); + // if we have pending timers add them to the current start list + for (it = pendingTimers.begin(); it != pendingTimers.end(); it++) + { + if ((*it) && (*it)->stop > checkTime->evaltime) + checkTime->startingTimers.insert(*it); + pendingTimers.erase(*it); + } + + LogFile.Log(3,"attach starting timers"); + // handle starting timers + for (it = checkTime->startingTimers.begin(); it != checkTime->startingTimers.end(); it++) + { + bool NeedsDetachReceivers = false; + if (!(*it) || (*it)->device >= 0) continue; // already has a device + int device = GetDevice(*it, &NeedsDetachReceivers); + if (device >= 0) // device will be attached? + { + if (NeedsDetachReceivers) // but needs to detach all others? + { + // disable running timers + std::set::iterator it2 = devices[device].recTimers.begin(); + for(; it2 != devices[device].recTimers.end(); it2++) + { + LogFile.Log(3,"stopping timer '%s' (%s, channel %s) at %s on device %d because of higher priority", (*it2)->timer->File(), DAYDATETIME((*it2)->start), CHANNELNAME((*it2)->timer->Channel()), DAYDATETIME(checkTime->evaltime), device); + AddConflict((*it2), checkTime, pendingTimers); + devices[device].recTimers.erase(*it2); + Conflicts++; + } + } + devices[device].recTimers.insert(*it); + (*it)->device = device; + (*it)->lastRecStart = checkTime->evaltime; + + LogFile.Log(3,"recording timer '%s' (%s, channel %s) at %s on device %d", (*it)->timer->File(), DAYDATETIME((*it)->start), CHANNELNAME((*it)->timer->Channel()), DAYDATETIME(checkTime->evaltime), device); + } + else + { + AddConflict((*it), checkTime, pendingTimers); + Conflicts++; + } + } + LogFile.Log(3,"check time %s - done", DAYDATETIME(checkTime->evaltime)); + return Conflicts; +} + +#if APIVERSNUM >= 10500 +int cConflictCheck::GetDevice(cConflictCheckTimerObj* TimerObj, bool*) +{ + int Priority = TimerObj->timer->Priority(); + const cChannel* Channel = TimerObj->timer->Channel(); + + // Collect the current priorities of all CAM slots that can decrypt the channel: + int selDevice = -1; + int NumCamSlots = CamSlots.Count(); + int SlotPriority[NumCamSlots]; + int NumUsableSlots = 0; + if (Channel->Ca() >= CA_ENCRYPTED_MIN) { + for (cCamSlot *CamSlot = CamSlots.First(); CamSlot; CamSlot = CamSlots.Next(CamSlot)) { + SlotPriority[CamSlot->Index()] = MAXPRIORITY + 1; // assumes it can't be used + if (CamSlot->ModuleStatus() == msReady) { + if (CamSlot->ProvidesCa(Channel->Caids())) { + if (!ChannelCamRelations.CamChecked(Channel->GetChannelID(), CamSlot->SlotNumber())) { + SlotPriority[CamSlot->Index()] = CamSlot->Priority(); + NumUsableSlots++; + } + } + } + } +#ifdef CFLC + int NumUsableSlots = 1; +#endif + if (!NumUsableSlots) + return selDevice; // no CAM is able to decrypt this channel + } + + bool NeedsDetachReceivers = false; + + uint32_t Impact = 0xFFFFFFFF; // we're looking for a device with the least impact + for (int j = 0; j < NumCamSlots || !NumUsableSlots; j++) { + if (NumUsableSlots && SlotPriority[j] > MAXPRIORITY) + continue; // there is no CAM available in this slot + for (int i = 0; i < numDevices; i++) { + if (Channel->Ca() && Channel->Ca() <= CA_DVB_MAX && Channel->Ca() != devices[i].CardIndex() + 1) + continue; // a specific card was requested, but not this one + if (NumUsableSlots && !CamSlots.Get(j)->Assign(devices[i].device, true)) + continue; // CAM slot can't be used with this device + bool ndr; + if (devices[i].ProvidesChannel(Channel, Priority, &ndr)) { // this device is basicly able to do the job + if (NumUsableSlots && devices[i].CamSlot() && devices[i].CamSlot() != CamSlots.Get(j)) + ndr = true; // using a different CAM slot requires detaching receivers + // Put together an integer number that reflects the "impact" using + // this device would have on the overall system. Each condition is represented + // by one bit in the number (or several bits, if the condition is actually + // a numeric value). The sequence in which the conditions are listed corresponds + // to their individual severity, where the one listed first will make the most + // difference, because it results in the most significant bit of the result. + uint32_t imp = 0; + imp <<= 1; imp |= 0; // prefer the primary device for live viewing if we don't need to detach existing receivers + imp <<= 1; imp |= !devices[i].Receiving() || ndr; // use receiving devices if we don't need to detach existing receivers + imp <<= 1; imp |= devices[i].Receiving(); // avoid devices that are receiving + imp <<= 8; imp |= min(max(devices[i].Priority() + MAXPRIORITY, 0), 0xFF); // use the device with the lowest priority (+MAXPRIORITY to assure that values -99..99 can be used) + imp <<= 8; imp |= min(max((NumUsableSlots ? SlotPriority[j] : 0) + MAXPRIORITY, 0), 0xFF); // use the CAM slot with the lowest priority (+MAXPRIORITY to assure that values -99..99 can be used) + imp <<= 1; imp |= ndr; // avoid devices if we need to detach existing receivers + imp <<= 1; imp |= devices[i].IsPrimaryDevice(); // avoid the primary device + imp <<= 1; imp |= devices[i].HasDecoder(); // avoid full featured cards + imp <<= 1; imp |= NumUsableSlots ? !ChannelCamRelations.CamDecrypt(Channel->GetChannelID(), j + 1) : 0; // prefer CAMs that are known to decrypt this channel + if (imp < Impact) { + // This device has less impact than any previous one, so we take it. + Impact = imp; + selDevice = i; + NeedsDetachReceivers = ndr; + } + } + } + if (!NumUsableSlots) + break; // no CAM necessary, so just one loop over the devices + } + return selDevice; +} +#else +// retrieves a free device (nearly a copy of the original cDevice::GetDevice) +int cConflictCheck::GetDevice(cConflictCheckTimerObj* TimerObj, bool *NeedsDetachReceivers) +{ + int selDevice = -1; + int Priority = TimerObj->timer->Priority(); + const cChannel* Channel = TimerObj->timer->Channel(); + uint Impact = 0xFFFFFFFF; + for (int i = 0; i < numDevices; i++) { + bool ndr; + if (devices[i].ProvidesChannel(Channel, Priority, &ndr)) { // this device is basicly able to do the job + uint imp = 0; + imp <<= 1; imp |= !devices[i].Receiving() || ndr; + imp <<= 1; imp |= devices[i].Receiving(); + imp <<= 1; //imp |= devices[i] == ActualDevice(); // cannot be handled + imp <<= 1; imp |= devices[i].IsPrimaryDevice(); + imp <<= 1; imp |= devices[i].HasDecoder(); + imp <<= 8; imp |= min(max(devices[i].Priority() + MAXPRIORITY, 0), 0xFF); + imp <<= 8; imp |= min(max(devices[i].ProvidesCa(Channel), 0), 0xFF); + if (imp < Impact) { + Impact = imp; + selDevice = i; + if (NeedsDetachReceivers) + *NeedsDetachReceivers = ndr; + } + } + } + return selDevice; +} +#endif + +void cConflictCheck::AddConflict(cConflictCheckTimerObj* TimerObj, cConflictCheckTime* CheckTime, std::set& pendingTimers) +{ + for(cConflictCheckTimerObj* concTimer= timerList->First(); concTimer; concTimer = timerList->Next(concTimer)) + { + if (concTimer->start >= TimerObj->stop) continue; + if (concTimer->stop <= TimerObj->start) continue; + if (!TimerObj->concurrentTimers) TimerObj->concurrentTimers = new std::set; + TimerObj->concurrentTimers->insert(concTimer); + } + TimerObj->ignore = (TimerObj->timer->Priority() < EPGSearchConfig.checkMinPriority) || TimerObj->start > maxCheck; + CheckTime->concurrentRecs.insert(TimerObj); + pendingTimers.insert(TimerObj); + + TimerObj->lastRecStop = CheckTime->evaltime; + if (TimerObj->lastRecStart > 0 && TimerObj->lastRecStart < TimerObj->lastRecStop) + { + TimerObj->recDuration += TimerObj->lastRecStop - TimerObj->lastRecStart; + TimerObj->lastRecStart = 0; + if ((TimerObj->stop - TimerObj->start - TimerObj->recDuration) < EPGSearchConfig.checkMinDuration * 60) + TimerObj->ignore = true; + } + + TimerObj->device = -1; + if (!TimerObj->conflCheckTime) + TimerObj->conflCheckTime = CheckTime; + else + return; + CheckTime->failedTimers.insert(TimerObj); + + LogFile.Log(3,"conflict found for timer '%s' (%s, channel %s)", TimerObj->timer->File(), DAYDATETIME(TimerObj->start), CHANNELNAME(TimerObj->timer->Channel())); +} + +bool cConflictCheck::TimerInConflict(cTimer* timer) +{ + for(cConflictCheckTime* checkTime = failedList->First(); checkTime; checkTime = failedList->Next(checkTime)) + { + std::set::iterator it; + for (it = checkTime->failedTimers.begin(); it != checkTime->failedTimers.end(); it++) + { + if (!(*it)->ignore) + { + std::set::iterator it2; + if ((*it)->concurrentTimers) + { + for (it2 = (*it)->concurrentTimers->begin(); it2 != (*it)->concurrentTimers->end(); it2++) + { + if ((*it2)->timer == timer) + return true; + } + } + } + } + } + return false; +} diff --git a/conflictcheck.h b/conflictcheck.h new file mode 100644 index 0000000..ea344b3 --- /dev/null +++ b/conflictcheck.h @@ -0,0 +1,307 @@ +/* +Copyright (C) 2004-2007 Christian Wieninger + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +Or, point your browser to http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + +The author can be reached at cwieninger@gmx.de + +The project's page is at http://winni.vdr-developer.org/epgsearch +*/ + +#ifndef __EPGSEARCHCONFLCH_H +#define __EPGSEARCHCONFLCH_H + +#include "epgsearchtools.h" +#include +#include +#include + +#define DO_MULTIPLE_RECORDINGS 1 +#define DO_REC_AND_PLAY_ON_PRIMARY_DEVICE 1 + +class cConflictCheckTime; +class TimerObjSort; + +// --- cConflictCheckTimerObj -------------------------------------------------------- +class cConflictCheckTimerObj : public cTimerObj +{ + const cEvent* event; + public: + time_t start; + time_t stop; + int device; + int recDuration; + time_t lastRecStart; + time_t lastRecStop; + cConflictCheckTime* conflCheckTime; + std::set* concurrentTimers; + bool ignore; + + cConflictCheckTimerObj(cTimer* Timer, time_t Start, time_t Stop, int Device = -1); + int Compare(const cListObject &ListObject) const; + const cEvent* Event(); + const cEvent* SetEventFromSchedule(); + int Matches(const cEvent *Event, int *Overlap) const; +}; + +class TimerObjSort +{ +public: + bool operator() (cConflictCheckTimerObj* a, cConflictCheckTimerObj* b) + { + return (a->Compare(*b) < 0); + } +}; + + +// --- cConflictCheckTime -------------------------------------------------------- +class cConflictCheckTime : public cListObject +{ + public: + time_t evaltime; + std::set startingTimers; + std::set stoppingTimers; + std::set failedTimers; + std::set concurrentRecs; + bool ignore; + + cConflictCheckTime(time_t EvalTime) : evaltime(EvalTime), ignore(false) {} + int Compare(const cListObject &ListObject) const + { + cConflictCheckTime *p = (cConflictCheckTime *)&ListObject; + return evaltime - p->evaltime; + } +}; + +#if APIVERSNUM < 10500 +// --- cConflictCheckDevice -------------------------------------------------------- +// This class tries to emulate the behaviour of a DVB device +// NOTE: The case device == NULL is only for debugging purposes +class cConflictCheckDevice +{ + public: + std::set recTimers; + cDevice* device; + int devicenr; + + cConflictCheckDevice() {} + int Priority() const + { + int prio = -1; + for(std::set::iterator it = recTimers.begin(); it != recTimers.end(); it++) + prio = max(prio, (*it)->timer->Priority()); + return prio; + }; + bool Receiving() const { return (recTimers.size() > 0); } + bool IsTunedTo (const cChannel* Channel) const + { + for(std::set::iterator it = recTimers.begin(); it != recTimers.end(); it++) + if ((*it)->timer->Channel()->Source() == Channel->Source() && + (*it)->timer->Channel()->Transponder() == Channel->Transponder()) + return true; + return false; + } + bool HasDecoder() const { if (device) return device->HasDecoder(); else return (devicenr == 0); } + bool IsPrimaryDevice() const { if (device) return device->IsPrimaryDevice(); else return (devicenr == 0); } + bool ProvidesSource(int Source) const + { + if (device) return device->ProvidesSource(Source); + else + { +// int type = Source & cSource::st_Mask; +// if (devicenr == 0) return type == cSource::stCable; +// if (devicenr > 0) return type == cSource::stTerr; +// return false; + return true; + } + } + int ProvidesCa(const cChannel* Channel) const { if (device) return device->ProvidesCa(Channel); else return true; } + int Ca() const + { + for(std::set::iterator it = recTimers.begin(); it != recTimers.end(); it++) + return (*it)->timer->Channel()->Ca(); + return 0; + } + bool HasPid(int Pid) const { return true; } + bool ProvidesChannel(const cChannel *Channel, int Priority = -1, bool *NeedsDetachReceivers = NULL) const + { + bool result = false; + bool hasPriority = Priority < 0 || Priority > this->Priority(); + bool needsDetachReceivers = false; + +#ifdef CFLC + if (ProvidesSource(Channel->Source())) +#else + if (ProvidesSource(Channel->Source()) && ProvidesCa(Channel)) +#endif + { + result = hasPriority; + if (Priority >= 0 && Receiving()) + { + if (IsTunedTo(Channel)) + { + if (Channel->Vpid() && !HasPid(Channel->Vpid()) || Channel->Apid(0) && ! HasPid(Channel->Apid(0))) + { +#ifdef DO_MULTIPLE_RECORDINGS +#ifndef DO_MULTIPLE_CA_CHANNELS + if (Ca() >= CA_ENCRYPTED_MIN || Channel->Ca() >= CA_ENCRYPTED_MIN) + needsDetachReceivers = Ca() != Channel->Ca(); + else +#endif + if (!IsPrimaryDevice()) + result = true; +#ifdef DO_REC_AND_PLAY_ON_PRIMARY_DEVICE + else + result = Priority >= Setup.PrimaryLimit; +#endif +#endif + } + else + result = !IsPrimaryDevice() || Priority >= Setup.PrimaryLimit; + } + else + needsDetachReceivers = true; + } + } + if (NeedsDetachReceivers) + *NeedsDetachReceivers = needsDetachReceivers; + return result; + } +}; +#else +// --- cConflictCheckDevice -------------------------------------------------------- +// This class tries to emulate the behaviour of a DVB device +// NOTE: The case device == NULL is only for debugging purposes +class cConflictCheckDevice +{ + public: + std::set recTimers; + cDevice* device; + int devicenr; + + cConflictCheckDevice() {} + int Priority() const + { + int prio = -1; + for(std::set::iterator it = recTimers.begin(); it != recTimers.end(); it++) + prio = max(prio, (*it)->timer->Priority()); + return prio; + }; + int CardIndex(void) const { if (device) return device->CardIndex(); else return devicenr;} + bool Receiving() const { return (recTimers.size() > 0); } + bool IsTunedTo (const cChannel* Channel) const + { + for(std::set::iterator it = recTimers.begin(); it != recTimers.end(); it++) + if ((*it)->timer->Channel()->Source() == Channel->Source() && + (*it)->timer->Channel()->Transponder() == Channel->Transponder()) + return true; + return false; + } + bool HasDecoder() const { if (device) return device->HasDecoder(); else return (devicenr == 0); } + bool IsPrimaryDevice() const { if (device) return device->IsPrimaryDevice(); else return (devicenr == 0); } + bool ProvidesSource(int Source) const + { + if (device) return device->ProvidesSource(Source); + else + { +// int type = Source & cSource::st_Mask; +// if (devicenr == 0) return type == cSource::stCable; +// if (devicenr > 0) return type == cSource::stTerr; +// return false; + return true; + } + } + cCamSlot *CamSlot(void) const { if (device) return device->CamSlot(); else return NULL;} + int Ca() const + { + for(std::set::iterator it = recTimers.begin(); it != recTimers.end(); it++) + return (*it)->timer->Channel()->Ca(); + return 0; + } + bool HasPid(int Pid) const { return true; } + bool ProvidesChannel(const cChannel *Channel, int Priority = -1, bool *NeedsDetachReceivers = NULL) const + { + bool result = false; + bool hasPriority = Priority < 0 || Priority > this->Priority(); + bool needsDetachReceivers = false; + + if (ProvidesSource(Channel->Source())) { + result = hasPriority; + if (Priority >= 0 && Receiving()) { + if (IsTunedTo(Channel)) { + if (Channel->Vpid() && !HasPid(Channel->Vpid()) || Channel->Apid(0) && !HasPid(Channel->Apid(0))) { +#ifdef DO_MULTIPLE_RECORDINGS + if (CamSlot() && Channel->Ca() >= CA_ENCRYPTED_MIN) { + if (CamSlot()->CanDecrypt(Channel)) + result = true; + else + needsDetachReceivers = true; + } + else if (!IsPrimaryDevice()) + result = true; +#ifdef DO_REC_AND_PLAY_ON_PRIMARY_DEVICE + else + result = Priority >= Setup.PrimaryLimit; +#endif +#endif + } + else + result = !IsPrimaryDevice() || Priority >= Setup.PrimaryLimit; + } + else + needsDetachReceivers = true; + } + } + if (NeedsDetachReceivers) + *NeedsDetachReceivers = needsDetachReceivers; + return result; + } +}; + +#endif + +// --- cConflictCheck -------------------------------------------------------- +class cConflictCheck +{ + cList* timerList; + cList* evaltimeList; + cList* failedList; + std::set pendingTimers; + cConflictCheckDevice *devices; + + int numDevices; + time_t maxCheck; + public: + int relevantConflicts; + int numConflicts; + time_t nextRelevantConflictDate; + + cConflictCheck(); + ~cConflictCheck(); + void InitDevicesInfo(); + void Check(); + cList* CreateCurrentTimerList(); + cList* CreateEvaluationTimeList(cList*); + cList* CreateConflictList(cList*, cList* timerList); + int GetDevice(cConflictCheckTimerObj* TimerObj, bool *NeedsDetachReceivers); + cList* GetFailed() { return failedList; } + cList* GetTimers() { return timerList; } + void AddConflict(cConflictCheckTimerObj* TimerObj, cConflictCheckTime* Checktime, std::set& pendingTimers); + int ProcessCheckTime(cConflictCheckTime* checkTime); + bool TimerInConflict(cTimer*); +}; + +#endif diff --git a/conflictcheck_thread.c b/conflictcheck_thread.c new file mode 100644 index 0000000..7a7fabf --- /dev/null +++ b/conflictcheck_thread.c @@ -0,0 +1,156 @@ +/* +Copyright (C) 2004-2007 Christian Wieninger + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +Or, point your browser to http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + +The author can be reached at cwieninger@gmx.de + +The project's page is at http://winni.vdr-developer.org/epgsearch +*/ + +#include +#include "conflictcheck_thread.h" +#include "epgsearchcfg.h" +#include "mail.h" + +#define CONFLICTCHECK_NICE 19 +#define CONFLCHECK_WAIT 20 + +cConflictCheckThread *cConflictCheckThread::m_Instance = NULL; +time_t cConflictCheckThread::m_cacheNextConflict = 0; +int cConflictCheckThread::m_cacheRelevantConflicts = 0; +int cConflictCheckThread::m_cacheTotalConflicts = 0; +bool cConflictCheckThread::m_runOnce = false; +bool cConflictCheckThread::m_forceUpdate = false; + +cConflictCheckThread::cConflictCheckThread(cPluginEpgsearch* thePlugin) +: cThread("EPGSearch: conflictcheck") +{ + m_plugin = thePlugin; + m_Active = false; + m_lastUpdate = time(NULL); + m_runOnce = false; + m_forceUpdate = false; +} + +cConflictCheckThread::~cConflictCheckThread() { + if (m_Active) + Stop(); +} + +void cConflictCheckThread::Init(cPluginEpgsearch* thePlugin, bool runOnce) +{ + if (EPGSearchConfig.checkTimerConflictsAfterUpdate || EPGSearchConfig.conflictCheckIntervall == 0) + { + if (!runOnce) return; + m_runOnce = true; + } + + if (m_Instance == NULL) { + m_Instance = new cConflictCheckThread(thePlugin); + m_Instance->Start(); + } + else + if (runOnce) m_forceUpdate = true; // force an update, because thread is already running + +} + +void cConflictCheckThread::Exit(void) { + if (m_Instance != NULL) { + m_Instance->Stop(); + DELETENULL(m_Instance); + } +} + +void cConflictCheckThread::Stop(void) { + m_Active = false; + Cancel(6); +} + +void cConflictCheckThread::Action(void) +{ + SetPriority(CONFLICTCHECK_NICE); + + m_Active = true; + // let VDR do its startup + if (!m_runOnce) + for(int wait = 0; wait < CONFLCHECK_WAIT && m_Active; wait++) + sleepSec(1); + + time_t nextUpdate = time(NULL); + while (m_Active) + { + time_t now = time(NULL); + if (now >= nextUpdate || m_forceUpdate) + { + m_forceUpdate = false; + if (Timers.BeingEdited()) + { + sleepSec(1); + continue; + } + LogFile.iSysLog("timer conflict check started"); + + cConflictCheck conflictCheck; + conflictCheck.Check(); + + time_t nextConflict = 0; + if (conflictCheck.relevantConflicts > 0) + { + char* msgfmt = NULL; + asprintf(&msgfmt, tr("%d timer conflict(s)! First at %s. Show them?"), conflictCheck.relevantConflicts, + *DateTime(conflictCheck.nextRelevantConflictDate)); + bool doMessage = EPGSearchConfig.noConflMsgWhileReplay == 0 || + !cDevice::PrimaryDevice()->Replaying() || + conflictCheck.nextRelevantConflictDate - now < 2*60*60; + if (doMessage && SendMsg(msgfmt, true,7) == kOk) + { + m_plugin->showConflicts = true; + cRemote::CallPlugin("epgsearch"); + } + free(msgfmt); + + if (EPGSearchConfig.sendMailOnConflicts) + { + cMailConflictNotifier mailNotifier; + mailNotifier.SendConflictNotifications(conflictCheck); + } + } + + // store for external access + cConflictCheckThread::m_cacheNextConflict = conflictCheck.nextRelevantConflictDate; + cConflictCheckThread::m_cacheRelevantConflicts = conflictCheck.relevantConflicts; + cConflictCheckThread::m_cacheTotalConflicts = conflictCheck.numConflicts; + + LogFile.iSysLog("timer conflict check finished"); + + m_lastUpdate = time(NULL); + int Intervall = EPGSearchConfig.conflictCheckIntervall; + if (nextConflict > 0 && EPGSearchConfig.conflictCheckWithinLimit > 0 && + nextConflict - time(NULL) < EPGSearchConfig.conflictCheckWithinLimit * 60) + Intervall = EPGSearchConfig.conflictCheckIntervall2; + + nextUpdate = long(m_lastUpdate/60)*60 + (Intervall * 60); + } + sleepSec(2); // to avoid high system load if time%30==0 + while (m_Active && time(NULL)%30 != 0 && !m_runOnce) // sync heart beat to a multiple of 5secs + sleepSec(1); + }; + + m_Active = false; + LogFile.iSysLog("Leaving conflict check thread"); +} + diff --git a/conflictcheck_thread.h b/conflictcheck_thread.h new file mode 100644 index 0000000..1c44e30 --- /dev/null +++ b/conflictcheck_thread.h @@ -0,0 +1,52 @@ +/* +Copyright (C) 2004-2007 Christian Wieninger + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +Or, point your browser to http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + +The author can be reached at cwieninger@gmx.de + +The project's page is at http://winni.vdr-developer.org/epgsearch +*/ + +#ifndef VDR_CONFLICTCHECK_THREAD_H +#define VDR_CONFLICTCHECK_THREAD_H + +#include +#include "conflictcheck.h" +#include "epgsearch.h" + +class cConflictCheckThread: public cThread { + private: + bool m_Active; + time_t m_lastUpdate; + cPluginEpgsearch* m_plugin; + static bool m_runOnce; + static bool m_forceUpdate; + protected: + virtual void Action(void); + void Stop(void); + public: + static cConflictCheckThread *m_Instance; + static time_t m_cacheNextConflict; + static int m_cacheRelevantConflicts; + static int m_cacheTotalConflicts; + cConflictCheckThread(cPluginEpgsearch* thePlugin); + virtual ~cConflictCheckThread(); + static void Init(cPluginEpgsearch* thePlugin, bool runOnce = false); + static void Exit(void); +}; + +#endif diff --git a/conflictcheckonly.c b/conflictcheckonly.c new file mode 100644 index 0000000..91c9892 --- /dev/null +++ b/conflictcheckonly.c @@ -0,0 +1,227 @@ +/* +Copyright (C) 2004-2007 Christian Wieninger + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +Or, point your browser to http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + +The author can be reached at cwieninger@gmx.de + +The project's page is at http://winni.vdr-developer.org/epgsearch +*/ + +#include +#include +#include +#if APIVERSNUM < 10507 +#include "i18n.h" +#define trNOOP(s) (s) +#endif +#include "services.h" +#include "mainmenushortcut.h" + +static const char VERSION[] = "0.0.1"; +static const char DESCRIPTION[] = trNOOP("Direct access to epgsearch's conflict check menu"); +static const char MAINMENUENTRY[] = trNOOP("Timer conflicts"); +static const char SETUPTEXT[] = trNOOP("Conflict info in main menu"); + +#if APIVERSNUM < 10507 +const tI18nPhrase PhrasesLocal[] = +{ + { + "Direct access to epgsearch's conflict check menu", + "Direkter Zugriff auf epgsearch's Konflikt-Prfungs-Men",// Deutsch + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "Suoratoiminto EPGSearch-laajennoksen ajastimien tarkistukselle", + "",// TODO Polski + "",// TODO Espaol + "",// TODO (Greek) + "",// TODO Svenska + "",// TODO Romaneste + "",// TODO Magyar + "",// TODO Catal + "",// TODO (Russian) + "",// TODO Hrvatski (Croatian) + "", // Eesti + "", // Dansk + "", // Czech + }, + { + "Timer conflicts", + "Timer-Konflikte", + "",// TODO + "",// TODO + "", + "",// TODO + "", + "",// TODO + "Ajastimien pllekkisyydet", + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "", // Eesti + "", // Dansk + "", // Czech + }, + { + "next", + "nchster", + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "seuraava", + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "", // Eesti + "", // Dansk + "", // Czech + }, + { + "Conflict info in main menu", + "Konflikt-Info im Hauptmen", + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "Nyt pllekkisyydet pvalikossa", + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "",// TODO + "", // Eesti + "", // Dansk + "", // Czech + }, + { NULL } +}; +#endif + +cString DateTime(time_t t) +{ + char buffer[32]; + if (t == 0) + { + time(&t); + } + struct tm tm_r; + tm *tm = localtime_r(&t, &tm_r); + snprintf(buffer, sizeof(buffer), "%02d.%02d %02d:%02d", tm->tm_mday, tm->tm_mon + 1, tm->tm_hour, tm->tm_min); + return buffer; +} + +class cPluginConflictcheckonly : public cMainMenuShortcut +{ + private: + char* _menuText; + + public: + cPluginConflictcheckonly(); + ~cPluginConflictcheckonly(); + virtual const char* Version() { return VERSION; } + +#if APIVERSNUM < 10507 + virtual const char* Description() { return tr(DESCRIPTION); } +#else + virtual const char* Description() { return I18nTranslate(DESCRIPTION, I18nEpgsearch); } +#endif + virtual bool Initialize(); + virtual cOsdObject* MainMenuAction() { return GetEpgSearchMenu("Epgsearch-conflictmenu-v1.0"); } + + protected: +#if APIVERSNUM < 10507 + virtual const char* SetupText() { return tr(SETUPTEXT); } +#else + virtual const char* SetupText() { return I18nTranslate(SETUPTEXT, I18nEpgsearch); } +#endif + virtual const char* MainMenuText(void); +}; + +cPluginConflictcheckonly::cPluginConflictcheckonly() +:_menuText(NULL) +{ +} + +cPluginConflictcheckonly::~cPluginConflictcheckonly() +{ + free(_menuText); +} + +const char* cPluginConflictcheckonly::MainMenuText(void) +{ +#if APIVERSNUM < 10507 + const char* menuText = tr(MAINMENUENTRY); +#else + const char* menuText = I18nTranslate(MAINMENUENTRY, I18nEpgsearch); +#endif + + cPlugin *epgSearchPlugin = cPluginManager::GetPlugin("epgsearch"); + if (epgSearchPlugin) + { + Epgsearch_lastconflictinfo_v1_0* serviceData = new Epgsearch_lastconflictinfo_v1_0; + if (epgSearchPlugin->Service("Epgsearch-lastconflictinfo-v1.0", serviceData)) + { + if (serviceData->relevantConflicts > 0) + { + free(_menuText); + asprintf(&_menuText, "%s (%d, %s: %s)", menuText, serviceData->relevantConflicts, +#if APIVERSNUM < 10507 + tr("next"), *DateTime(serviceData->nextConflict)); +#else + I18nTranslate("next", I18nEpgsearch), *DateTime(serviceData->nextConflict)); +#endif + menuText = _menuText; + } + } + delete serviceData; + } + return menuText; +} + +bool cPluginConflictcheckonly::Initialize(void) +{ +#if APIVERSNUM < 10507 + RegisterI18n(PhrasesLocal); +#endif + return cMainMenuShortcut::Initialize(); +} + +VDRPLUGINCREATOR(cPluginConflictcheckonly); // Don't touch this! diff --git a/createcats.c b/createcats.c new file mode 100644 index 0000000..f9d2327 --- /dev/null +++ b/createcats.c @@ -0,0 +1,348 @@ +/* +Copyright (C) 2004-2007 Christian Wieninger + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +Or, point your browser to http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + +The author can be reached at cwieninger@gmx.de + +The project's page is at http://winni.vdr-developer.org/epgsearch +*/ + +#include +#include +#include +#include +#include + +#define MINAPPEARANCE 100 // the minimum appearance of a category +#define MAXVALUES 60 // the maximum of values for a category +#define MAXNAMELENGTH 30 // the maximum length of a category name or value + + +// some helping stuff copied from VDR sources +#define KILOBYTE(n) ((n) * 1024) +#define MAXPARSEBUFFER KILOBYTE(10) + +bool isnumber(const char *s) +{ + if (!*s) + return false; + while (*s) { + if (!isdigit(*s)) + return false; + s++; + } + return true; +} + +// --- cReadLine ------------------------------------------------------------- +class cReadLine { + private: + char buffer[MAXPARSEBUFFER]; + public: + char *Read(FILE *f); +}; + +char *cReadLine::Read(FILE *f) +{ + if (fgets(buffer, sizeof(buffer), f) > 0) { + int l = strlen(buffer) - 1; + if (l >= 0 && buffer[l] == '\n') + buffer[l] = 0; + return buffer; + } + return NULL; +} + +char *skipspace(const char *s) +{ + while (*s && isspace(*s)) + s++; + return (char *)s; +} + +int comparevalue( const void *arg1, const void *arg2 ) +{ + char* value1 = *(char**) arg1; + char* value2 = *(char**) arg2; + return strcmp(value1, value2); +} + +// --- cCat ------------------------------------------------------------- +class cCat { + public: + int appeared; + char name[MAXPARSEBUFFER]; + int numvalues; + char** values; + + cCat(char* n) + :appeared(0), numvalues(0), values(NULL) + { + strcpy(name, n); + } + void addvalue(char* value) + { + if (valueexists(value)) + return; + char* newvalue = (char*) malloc(sizeof(char) * (strlen(value)+1)); + strcpy(newvalue, value); + values = (char**) realloc(values, sizeof(char*)*(numvalues+1)); + values[numvalues++] = newvalue; + } + bool valueexists(char* value) + { + for(int i=0; iappeared == cat2->appeared) return 0; + if (cat1->appeared < cat2->appeared) return 1; else return -1; +} + +// --- cCats ------------------------------------------------------------- +class cCats { + private: + int numcats; + cCat** cats; + public: + cCats():numcats(0), cats(NULL) {} + + int num() {return numcats;} + + cCat* add(char* name) + { + cCat* newCat = new cCat(name); + cats = (cCat**) realloc(cats, sizeof(cCat*)*(numcats+1)); + cats[numcats++] = newCat; + return newCat; + } + + cCat* get(int i) + { + if (i>=0 && iname, name) == 0) + return cats[i]; + return NULL; + } + void sort() + { + for(int i=0; isort(); + qsort(cats, numcats, sizeof( cCat* ), comparecat ); + } +}; + +int main(int argc, char *argv[]) +{ + FILE* f = NULL; + cCats catlist; + unsigned int minappearance = MINAPPEARANCE; + unsigned int maxvalues = MAXVALUES; + unsigned int maxlength = MAXNAMELENGTH; + + static const struct option long_options[] = { + { "minappearance", required_argument, NULL, 'm' }, + { "maxvalues", required_argument, NULL, 'v' }, + { "maxlength", required_argument, NULL, 'l' }, + { "help", no_argument, NULL, 'h' }, + { NULL } + }; + + int c; + while ((c = getopt_long(argc, argv, "m:v:l:h", long_options, NULL)) != -1) + { + switch (c) + { + case 'm': + if (isnumber(optarg)) + { + minappearance = atoi(optarg); + break; + } + fprintf(stderr, "invalid parameter minappearance: %s\n", optarg); + return 2; + break; + case 'v': + if (isnumber(optarg)) + { + maxvalues = atoi(optarg); + break; + } + fprintf(stderr, "invalid parameter maxvalues: %s\n", optarg); + return 2; + break; + case 'l': + if (isnumber(optarg)) + { + maxlength = atoi(optarg); + break; + } + fprintf(stderr, "invalid parameter maxlenght: %s\n", optarg); + return 2; + break; + case 'h': + printf("usage: createcats [OPTIONS] /path_to/epg.data\n\n"); + printf("-m N, --minappearance=N the minimum number a category has to appear\n"); + printf(" to be used\n"); + printf("-v N, --maxvalues=N values of a category are omitted if they exceed\n"); + printf(" this number\n"); + printf("-l N, --maxlength=N the maximum length of a text to be accepted\n"); + printf(" as a category value\n"); + printf("-h, --help this help\n\n"); + return 0; + } + } + + if (argc < 2) + { + fprintf(stderr, "ERROR: please pass your epg.data\nusage: createcats epg.data\n"); + return 1; + } + + f = fopen(argv[argc-1], "r"); + if (f == NULL) + { + fprintf(stderr, "ERROR: could not open: %s\n", argv[1]); + return 1; + } + + char *s; + cReadLine ReadLine; + while ((s = ReadLine.Read(f)) != NULL) + { + if (*s == 'D') + { + s = strchr(s,'|'); // jump to possibly first category + if (!s) + continue; + s++; + char *pstrSearchToken; + char *pstrSearch=strdup(s); + pstrSearchToken=strtok(pstrSearch, "|"); + + while(pstrSearchToken) + { + // must have a ':' + char* szPos = NULL; + if ((szPos = strchr(pstrSearchToken, ':')) == NULL) + { + pstrSearchToken=strtok(NULL, "|"); + continue; + } + + char catname[MAXPARSEBUFFER] = ""; + char catvalue[MAXPARSEBUFFER] = ""; + + strncpy(catname, pstrSearchToken, szPos - pstrSearchToken); + catname[szPos - pstrSearchToken] = 0; + strcpy(catvalue, skipspace(szPos+1)); + + cCat* cat = catlist.exists(catname); + if (!cat && strlen(catname) < maxlength) // accept only names up to 30 chars + cat = catlist.add(catname); + + if (cat) + { + cat->appeared++; + if (strlen(catvalue) < maxlength) // accept only values up to 30 chars + cat->addvalue(catvalue); + } + + pstrSearchToken=strtok(NULL, "|"); + } + free(pstrSearch); + } + } + fclose(f); + + catlist.sort(); + + f = fopen("epgsearchcats.conf", "w"); + if (f == NULL) + { + fprintf(stderr, "ERROR: could not open outputfile\n"); + return 1; + } + fprintf(f, "# -----------------------------------------------------------------------------\n"); + fprintf(f, "# This is just a template based on your current epg.data. Please edit!\n"); + fprintf(f, "# Perhaps a category or its value list should be removed. Also the\n"); + fprintf(f, "# 'name in menu' should be adjusted to your language.\n"); + fprintf(f, "# The order of items determines the order listed in epgsearch. It does not\n"); + fprintf(f, "# depend on the ID, which is used by epgsearch.\n"); + fprintf(f, "# Format:\n"); + fprintf(f, "# ID|category name|name in menu|values separated by ',' (option)|searchmode(option)\n"); + fprintf(f, "# - 'ID' should be a unique positive integer\n"); + fprintf(f, "# (changing the id later on will force you to reedit your search timers!)\n"); + fprintf(f, "# - 'category name' is the name in your epg.data\n"); + fprintf(f, "# - 'name in menu' is the name displayed in epgsearch.\n"); + fprintf(f, "# - 'values' is an optional list of possible values\n"); + fprintf(f, "# if you omit the list, the entry turns to an edit field in epgsearch,\n"); + fprintf(f, "# else it's an list of items to select from\n"); + fprintf(f, "# - 'searchmode' is an optional parameter specifying the mode of search:\n"); + fprintf(f, "# text comparison:\n"); + fprintf(f, "# 0 - the whole term must appear as substring\n"); + fprintf(f, "# 1 - all single words (delimiters are ',', ';', '|' or '~')\n"); + fprintf(f, "# must exist as substrings. This is the default search mode.\n"); + fprintf(f, "# 2 - at least one word (delimiters are ',', ';', '|' or '~')\n"); + fprintf(f, "# must exist as substring.\n"); + fprintf(f, "# 3 - matches exactly\n"); + fprintf(f, "# 4 - regular expression\n"); + fprintf(f, "# numerical comparison:\n"); + fprintf(f, "# 10 - less\n"); + fprintf(f, "# 11 - less or equal\n"); + fprintf(f, "# 12 - greater\n"); + fprintf(f, "# 13 - greater or equal\n"); + fprintf(f, "# 14 - equal\n"); + fprintf(f, "# 15 - not equal\n"); + fprintf(f, "# -----------------------------------------------------------------------------\n\n"); + int id = 1; + for(int i=0; iappeared > (int)minappearance && cat->numvalues > 1) // accept only category, that have at least 2 values and appear more than MINAPPEARANCE timers + { + fprintf(f, "# '%s' found %d times with %d different values %s\n", cat->name, cat->appeared, cat->numvalues, cat->numvalues>=(int)maxvalues?"(values omitted, too much)":""); + fprintf(f, "%d|%s|%s|", id++, cat->name, cat->name); + for(int j=0; cat->numvalues < (int)maxvalues && jnumvalues; j++) + fprintf(f, "%s%s", cat->values[j], (j == cat->numvalues-1?"":",")); + fprintf(f, "|1\n\n"); + } + } + fclose(f); + + printf("epgsearchcats.conf created!\n"); + return 0; +} diff --git a/distance.c b/distance.c new file mode 100644 index 0000000..6d5e974 --- /dev/null +++ b/distance.c @@ -0,0 +1,175 @@ +/* +Copyright (C) 2004-2007 Christian Wieninger + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +Or, point your browser to http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + +The author can be reached at cwieninger@gmx.de + +The project's page is at http://winni.vdr-developer.org/epgsearch +*/ + +//--------------------------------------------------- +// Levenshtein Distance +// by Michael Gilleland, Merriam Park Software +// +// source: +// http://www.merriampark.com/ld.htm#CPLUSPLUS +// +//--------------------------------------------------- + +#include "distance.h" +#include +#include +#include + + +//**************************** +// Get minimum of three values +//**************************** + +int Distance::Minimum (int a, int b, int c) +{ +int mi; + + mi = a; + if (b < mi) { + mi = b; + } + if (c < mi) { + mi = c; + } + return mi; + +} + +//************************************************** +// Get a pointer to the specified cell of the matrix +//************************************************** + +int *Distance::GetCellPointer (int *pOrigin, int col, int row, int nCols) +{ + return pOrigin + col + (row * (nCols + 1)); +} + +//***************************************************** +// Get the contents of the specified cell in the matrix +//***************************************************** + +int Distance::GetAt (int *pOrigin, int col, int row, int nCols) +{ +int *pCell; + + pCell = GetCellPointer (pOrigin, col, row, nCols); + return *pCell; + +} + +//******************************************************* +// Fill the specified cell in the matrix with the value x +//******************************************************* + +void Distance::PutAt (int *pOrigin, int col, int row, int nCols, int x) +{ +int *pCell; + + pCell = GetCellPointer (pOrigin, col, row, nCols); + *pCell = x; + +} + +//***************************** +// Compute Levenshtein distance +//***************************** + +int Distance::LD (char const *s, char const *t, int maxLength) +{ +int *d; // pointer to matrix +int n; // length of s +int m; // length of t +int i; // iterates through s +int j; // iterates through t +char s_i; // ith character of s +char t_j; // jth character of t +int cost; // cost +int result; // result +int cell; // contents of target cell +int above; // contents of cell immediately above +int left; // contents of cell immediately to left +int diag; // contents of cell immediately above and to left +int sz; // number of cells in matrix + + // Step 1 + + n = min((int)strlen(s), maxLength); + m = min((int)strlen(t), maxLength); + if (n == 0) { + return m; + } + if (m == 0) { + return n; + } + sz = (n+1) * (m+1) * sizeof (int); + d = (int *) malloc (sz); + + // Step 2 + + for (i = 0; i <= n; i++) { + PutAt (d, i, 0, n, i); + } + + for (j = 0; j <= m; j++) { + PutAt (d, 0, j, n, j); + } + + // Step 3 + + for (i = 1; i <= n; i++) { + + s_i = s[i-1]; + + // Step 4 + + for (j = 1; j <= m; j++) { + + t_j = t[j-1]; + + // Step 5 + + if (s_i == t_j) { + cost = 0; + } + else { + cost = 1; + } + + // Step 6 + + above = GetAt (d,i-1,j, n); + left = GetAt (d,i, j-1, n); + diag = GetAt (d, i-1,j-1, n); + cell = Minimum (above + 1, left + 1, diag + cost); + PutAt (d, i, j, n, cell); + } + } + + // Step 7 + + result = GetAt (d, n, m, n); + free (d); + return result; + +} + diff --git a/distance.h b/distance.h new file mode 100644 index 0000000..9535cba --- /dev/null +++ b/distance.h @@ -0,0 +1,47 @@ +/* +Copyright (C) 2004-2007 Christian Wieninger + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +Or, point your browser to http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + +The author can be reached at cwieninger@gmx.de + +The project's page is at http://winni.vdr-developer.org/epgsearch +*/ + +//--------------------------------------------------- +// Levenshtein Distance +// by Michael Gilleland, Merriam Park Software +// +// source: +// http://www.merriampark.com/ld.htm#CPLUSPLUS +// +//--------------------------------------------------- + +#ifndef _DISTANCE_INC_ +#define _DISTANCE_INC_ + +class Distance +{ + public: + int LD (char const *s, char const *t, int maxLength); + private: + int Minimum (int a, int b, int c); + int *GetCellPointer (int *pOrigin, int col, int row, int nCols); + int GetAt (int *pOrigin, int col, int row, int nCols); + void PutAt (int *pOrigin, int col, int row, int nCols, int x); +}; + +#endif diff --git a/doc-src/de/epgsearch.1.txt b/doc-src/de/epgsearch.1.txt new file mode 100644 index 0000000..3ac4223 --- /dev/null +++ b/doc-src/de/epgsearch.1.txt @@ -0,0 +1,1187 @@ +=head1 NAME + +F - Suchtimer und Ersatz fr VDR's Standard-Programm-Men + +=head1 BESCHREIBUNG + +EPG-Search kann als Ersatz fr VDR's Standard-Programm-Men verwendet +werden. Es sieht genauso aus, erweitert es aber um einige zustzliche +Funktionen. + +Ein weiterer Punkt sind die sog. Suchtimer die dafr +sorgen, dass Timer automatisch programmiert werden. + + - Befehle fr EPG-Eintrge mit verschiedenen integrierten Befehlen wie + z.B. 'Wiederholungen anzeigen', 'Suche anlegen'. Man kann eigene + Befehle hinzufgen, um z.B. einen VDRAdmin Autotimer anzulegen. + + - Bis zu 4 weitere Zeitpunkte im Men 'Was luft jetzt?' neben 'Jetzt' + und 'Nchste', sowie ein optionales Favoritenmen. + + - Suche im EPG: Anlegen von wiederverwendbaren Abfragen, die auch als + 'Suchtimer' verwendet werden knnen. + + - Suchtimer: Sucht im Hintergrund nach Sendungen und erzeugt einen + Timer bei passenden EPG-Eintrgen (hnlich zu VDRAdmins Autotimern) + oder informiert ber die Sendung via OSD. + + - Vermeidung von doppelten Aufnahmen der gleichen Sendung + * Timer-Vorschau + * Erkennung abgebrochener Aufnahmen + * Fuzzy-Vergleich von Sendungen + + - Fortschrittsbalken in 'Jetzt' und 'Nchste' + + - Zeit im Men 'Jetzt', 'Nchste' kann per Tastendruck verschoben + werden, z.B. was luft 'Jetzt' + 30 Minuten + + - Startmen 'Programm' oder 'Jetzt' einstellbar. + + - das Men zur detaillierten EPG-Anzeige (Zusammenfassung) erlaubt den + Sprung zur vorherigen/nchsten Sendung + + - Untersttzung erweiterter EPG-Infos in Suchtimern + + - Erweiterung des Timer-Edit-Mens um Verzeichnisse, + benutzerdefinierte Wochentage und Untertitel-Auswahl + + - Timer Konfliktcheck, informiert ber OSD-Meldung + + - Timer Konfliktmen, zeigt die Konflikte an und erleichtert die + Konfliktlsung + + - Email-Benachrichtigungen ber Suchtimer-Updates und Timer-Konflikte + +Funktioniert nur mit >= vdr-1.3.46. + +Teile der Quelltexte basieren auf dem repeating-epg-patch von Gerhard Steiner, der mir die Erlaubnis gab, diese zu verwenden. Danke fr seine Arbeit! + +=head1 OPTIONEN + +=over 4 + +=item -f file, --svdrpsendcmd=file + +Pfad zu svdrpsend.pl fr externe SVDRP-Kommunikation (Standard ist interne +Kommunikation, deshalb ist dieser Paramter normalerweise nicht notwendig) + +=item -c path, --config=path + +zur Angabe eines eigenen Konfigurationsverzeichnisses fr alle +epgsearch-Dateien, Standard ist '/epgsearch' + +=item -l file, --logfile=file + +zur Angabe eines abweichenden Dateipfades fr epgsearch's Log-File (Standard +ist epgsearch.log in epgsearch's Konfig-Verzeichnis) + +=item -v n, --verbose=n + +verbose level fr das Log-File. Wert 0 bedeutet kein Logging. Weiter Werte sind +1 (allgemeine Meldungen), 2 (detaillierte Meldungen), 3 (fr Debug-Zwecke) + +=item -r, --reloadmenuconf + +bewirkt ein Neuladen der epgsearchmenu.conf bei jedem Plugin-Aufruf am +OSD. Kann fr das Testen eines selbst angepaten Men-Layouts praktisch sein. + +=item -m file, --mailcmd=file + +das externe Kommando fr den Emailversand. Als Standard wird 'sendEmail.pl' +benutzt. Wenn ein abweichendes Kommando oder Skript verwendet wird, muss +sichergestellt sein, dass das gleiche Paramter-Interface verwendet wird, wie +bei sendEmail.pl. + +=back + +=head1 Inhalt + + 1. Beschreibung + 1.1 Men Befehle + 1.2 Men Suche + 1.2.1 Men Suche editieren + 1.2.2 Men Suchergebnisse + 1.3 Erweitertes 'Jetzt' und 'Nchste' + 1.4 Men Setup + 23. Suchtimer + 2.1 'Wiederholungen vermeiden' - Im Detail + 2.2 Wie funktioniert der Vergleichstest zwischen 2 Sendungen? + 2.3 Wie und wo wird der Vergleichstest eingesetzt? + 3. Verwendung der Suche durch andere Plugins oder Skripte + 4. Verwendung erweiterter EPG Infos + 5. Ersetzen des Standardmen + 6. Addons + +=head1 1. Beschreibung + +Auf den ersten Blick sieht EPG-Search wie der Programm-Men-Punkt des +VDR aus. +Ein Tastendruck auf '0' schaltet die Farbtasten um, so dass weitere +Funktionen erreicht werden knnen (die vorgegebene Zuweisung kann per +Setup angepasst werden): + +=head2 1.1 Men Befehle + +Dieses Men zeigt Befehle an, die auf den ausgewhlten Meneintrag +angewandt werden knnen. Es gibt 8 vorgegebene Befehle: + + - Wiederholung: Zeigt Wiederholungen an + - Aufnehmen + - Umschalten + - Suche anlegen: schaltet zum Suchmen und erzeugt eine Suche mit dem + Namen der aktuellen Sendung als Suchbegriff (um die manuelle Erfassung + zu vermeiden + - Suche in Aufnahmen: durchsucht die Aufnahmen nach einer Sendung mit + diesem Namen + - Als 'bereits aufgezeichnet' markieren: + Hiermit wird die ausgewhlte Sendung in die Datei epgsearchdone.data + bernommen und epgsearch angewiesen, diese Sendung nicht aufzunehmen, falls + der zugehrige Suchtimer mit "Wiederholung vermeiden" geschaltet ist. Ein + bereits erzeugter Timer wird beim nchsten Suchtimer-Update automatisch + gelscht. + - In/Aus Umschaltliste?: + Zum Bearbeiten der Umschaltliste. Wenn eine Sendung in der Umschaltliste + enthalten ist, wird kurz vor Beginn eine Ankndigung eingeblendet und dann + umgeschaltet. Um die gesamte Umschaltliste einzusehen, bitte + 'Suche/Aktionen/Zeige Umschaltliste' aufrufen. + - Erzeuge Ausschlussliste: + Eine Ausschlussliste wird verwendet um bestimmte Sendungen bei der + Verwendung von Suchtimern zu ignorieren. Ein Suchtimer kann beliebige + Ausschlusslisten verwenden. + +Man kann eigene Befehle hinzufgen, indem man die Datei +epgsearchcmds.conf im epgsearch-Konfig-Verzeichnis editiert. Eine +Beispiel-Datei mit Bespielscripts liegt dem Plugin bei (s. Unterverzeichnis +'scripts', stammt von vdr-wiki.de. Danke an die Autoren). + +Das Format der Datei ist identisch zu VDRs commands.conf oder reccmds.conf. +Wenn ein Befehl ausgefhrt wird, werden folgende Parameter bergeben: + + $1: Titel des Programmeintrags + $2: Startzeit als time_t-Wert (wie im Shutdown-Skript) + $3: Endzeit + $4: Programmplatz + $5: langer Kanalname + $6: Untertitel des Programmeintrags, "" falls nicht vorhanden + +Zum Ausfhren eines Befehls aus dem Hauptmen ohne ffnen des +Befehlsmens gengt es, die zugehrige Nummer des Befehls zu drcken. + +=head2 1.2 Men Suche + +Hier kann man eine Suche im EPG erzeugen, editieren, lschen und +ausfhren. Bedienung und Verhalten ist hnlich zu VDR's Timer-Men. + +=head3 1.2.1 Men Suche editieren + +Das meiste in diesem Men ist selbsterklrend, deshalb nur einige +Anmerkungen zu: + +=over 4 + +=item - B + +Suchbegriff. Will man nach mehreren Worten suchen, dann bitte mit +Leerzeichen trennen. Lsst man den Suchbegriff leer (in Verbindung +mit Suchmodus 'Ausdruck') wird alles akzeptiert. Das kann praktisch +sein, um z.B. alles zu suchen, was zu einer bestimmten Zeit auf +einem bestimmten Sender kommt. + +Mit 'Blau' kann man auch eine Vorlage fr eine Suche +bernehmen. Falls eine Vorlage als Standard definiert wurde, wird +bei einer neuen Suche automatisch der Inhalt der Standard-Vorlage +verwendet. + +Hinweis: Die unscharfe Suche ist auf 32 Zeichen begrenzt! + +=item - B + +'Ausdruck' sucht nach diesem Ausdruck innerhalb eines +EPG-Eintrags. 'alle Worte' erfordert, dass jedes Wort im EPG-Eintrag +vorkommt, 'ein Wort' dagegen nur, dass zumindest ein Wort +auftaucht. 'exakt' vergleicht den gesamten Suchbegriff mit dem +EPG-Eintrag (praktisch bei kurzen Titeln wie z.B. "Alf"). 'regulrer +Ausdruck' erlaubt die Angabe eines regulren Ausdrucks zur +Suche. Ein fhrender und abschlieender '/' ist nicht notwendig. Als +Standard werden POSIX extended regular expressions verwendet. Wer +lieber mit Perl kompatiblen regulren Ausdrcken arbeitet, muss +lediglich im Makefile des Plugins #HAVE_PCREPOSIX=1 in +HAVE_PCREPOSIX=1 ndern und neu kompilieren. (Dafr ist pcreposix +notwendig, das mit libpcre von www.pcre.org installiert wird, aber +auf den meisten Distributionen bereits vorhanden sein sollte). + +Eine Beschreibung des Suchprozesses gibt es im MANUAL. + +=item - B + +(nur verfgbar, wenn konfiguriert. Siehe weiter unten 'Verwendung +erweiterter EPG Infos') + +=item - B + +Wenn 'Ja' gewhlt ist, verhindert das, dass eine Sendung aus dem +Suchergebnis ausgeschlossen wird, falls die entsprechende +Kategorie nicht im EPG vorhanden ist. Vorsicht: Ohne weitere Suchkriterien +kann das zu einer Flut von Timern fhren. + +=item - B + +sucht nur im angegebenen Kanalbereich, der hinterlegten +Kanalgruppe, z.B. 'ffentl. Rechtl.' oder 'Sportsender'... oder in +FTA-Sendern. + +ACHTUNG: Nach einer nderung der Kanal-Reihenfolge sollten unbedingt +diese Einstellungen der Suchtimer kontrolliert werden! + +=item - B + +Neben den Wochentagen kann auch eine benutzerdefinierte Auswahl +getroffen werden, um z.B. nur Montags und Freitags zu suchen. + +Die benutzerdefinierte Auswahl findet sich am Ende der Liste +Son, Mon, ..., Sam, benutzerdefiniert + +=item - B + +Hier knnen eine oder mehrere oder alle Ausschlusslisten selektiert werden. +Falls ein Suchergebnis auch in einer der gewhlten Ausschlusslisten +erscheint, wird es verworfen. + +=item - B + +Nur verfgbar, wenn im Setup aktiviert. Mit dieser Option kann eine Suche zur +Verwendung im Favoritenmen markiert werden. Dieses Men listet alle +Suchergebnisse von Suchen mit dieser Option. + +=item - B + +Nur verfgbar, wenn mehr als eine Menvorlage fr Suchergebnisse in +epgsearchmenu.conf angegeben wurde. Mit dieser Option kann ein anderes Layout +fr die Suchergebnisse dieser Suche gewhlt werden. + +=item - B + +falls ja, sucht das Plugin im Hintergrund nach passenden Sendungen +und erzeugt dafr einen Timer (im Setup muss dazu die Verwendung von +Suchtimern aktiv sein). Bei der Einstellung lt sich +ber die Taste 'Blau' ein Zeitfenster einstellen, in dem der Suchtimer +aktiv sein soll. + +=item - B + +Standard ist 'Aufnehmen', also das Erzeugen eines Timers fr das +Suchergebnis. Man kann aber auch whlen, dass nur eine Ankndigung +der Sendung per OSD vorgenommen werden soll. Eine weitere +Mglichkeit ist 'nur umschalten'. Dadurch wird automatisch eine +Minute vor Beginn der Sendung auf deren Kanal gewechselt. + +=item - B + +falls ja, wird die Aufnahme in einem Ordner mit dem Seriennamen +gespeichert. Die Aufnahme selbst erhlt den Episondennamen. Falls es +keinen gibt, wird Datum und Uhrzeit als Episondenname verwendet. + +=item - B + +hier kann man ein Verzeichnis angeben, in dem die Aufnahme +gespeichert wird, z.B. 'SciFi'. Mit der Taste 'Blau' kann ein +Verzeichnis gewhlt werden, das bereits bei anderen Sucheintrgen +verwendet wird. Die Liste kann auerdem durch Eintrge in der Datei +epgsearchdirs.conf erweitert werden (pro Zeile ein Verzeichnis, ohne +das fhrende video-Verzeichnis, s. auch MANUAL). + +Wenn man erweiterte EPG-Infos von einem Provider erhlt, knnen im +Verzeichnis-Eintrag auch Variablen wie "%Genre%" oder "%Category%" +verwendet werden. Diese werden durch die aktuellen erw. EPG-Infos +ersetzt, sobald ein Timer erzeugt wird. + +Siehe MANUAL 'Using variables in the directory entry of a search timer') + +=item - B + +Manchen Aufnahmen sollen nur ein paar Tage existieren, +z.B. Tagesschau. Mit diesem Feature kann man epgsearch sagen, dass +es die Aufnahme automatisch nach ... Tagen lschen soll + +=item - B + +Wenn die angegebene Anzahl von Aufnahmen existiert, dann pausiert +epgsearch mit dem Erzeugen neuer Timer. Erst nach dem Lschen einer +oder mehrerer Aufnahmen, wird wieder nach neuen Sendungen gesucht. + +=item - B + +Wenn man keine Wiederholungen aufnehmen will, versucht dieses +Feature festzustellen, ob eine Sendung bereits +aufgenommen/programmiert wurde und berspringt diese dann. Bitte vor +Verwendung den Abschnitt 'Wiederholungen vermeiden - Im Detail' +weiter unten lesen. + +=item - B + +Will man eine gewisse Anzahl von Wiederholungen einer Sendung +erlauben, kann dies hier hinterlegt werden. + +=item - B + +Falls Wiederholungen nur innerhalb einer anzugebenden Anzahl Tage +erlaubt werden sollen, kann dies hier eingestellt werden. 0 +entspricht unbegrenzt. + +=item - B + +Einstellung, ob beim Test, ob eine Sendung identisch ist, auch der +Titel verglichen werden soll. + +=item - B + +Einstellung, ob beim Test, ob eine Sendung identisch ist, auch der +Untertitel verglichen werden soll. Hat eine Sendung keinen +Untertitel wird sie als abweichend gewertet und ist damit nicht +gleich einer anderen Sendung mit oder ohne Untertitel. + +=item - B + +Einstellung, ob beim Test, ob eine Sendung identisch ist, auch die +Inhaltsbeschreibung verglichen werden soll. Dabei wird zunchst +alles aus dem Inhalt entfernt, das einer Kategorienangabe +gleicht. Der verbleibende Text wird dann verglichen. Ist dieser zu +90% hnlich (im Sinne des Levinshtein-Distance-Algorithmus) wird er +als gleich behandelt. + +=item - B + +ber die Schaltflche 'Einstellungen' kann angegeben werden welche +Kategorien ebenfalls miteinander verglichen werden sollen. + +=item - B + +Jeder Suchtimer kann fr diese Parameter eigene Einstellungen +haben. Die Voreinstellung wird im Setup vorgenommen. + +=item - B + +aktiviert VPS, falls im VDR-Setup aktiv und fr die gefundene +Sendung auch VPS-Informationen vorhanden sind. + +=item - B + +zum automatischen Lschen eines Suchttimers bei folgenden Bedingungen: + + * nach x Aufnahmen, oder + * nach x Tagen nach erster Aufnahme + +Gezhlt werden dabei nur erfolgreiche Aufnahmen. Das Lschen erfolgt +direkt nach dem Ende der entsprechenden Aufnahme. + +=back + +Um den Status 'Als Suchtimer verw.' zu ndern, ohne das Men zu +ffnen, kann die Taste '2' verwendet werden. Dies ruft direkt den +2. Befehl im Befehlsmen auf. + +=head3 1.2.2 Men Suchergebnisse + +Dieses Men zeigt die Suchergebnisse an. Ein 'T' sagt aus, dass es zu +diesem Eintrag bereits einen Timer gibt, ein 't', dass es nur +teilweise aufgenommen wird, also wie im Standard-Programm-Men. + +=head2 1.3 Erweitertes 'Jetzt' and 'Nchste' + +Im Setup knnen bis zu 4 zustzliche Zeiten, als Erweiterung zu 'Jetzt' +und 'Nchste', angegeben werden um die Taste Grn zu erweitern. +Z.B. 'nachmittags', 'abends', 'sptabends'. Zeiten, die bereits +verstrichen sind, werden bersprungen, man erhlt abends also kein +'nachmittags'. Ausnahme: Ist ein Zeitpunkt nicht mehr als 20 Stunden in der +Zukunft wird das Men des nchsten Tages angezeigt. +In diesen Men kann die aktuell angezeigte Zeit durch Drcken auf +FastRew und FastFwd verschoben werden um die Zeit nach hinter oder +vorne zu verstellen. Falls diese Tasten auf der Fernbedienung nicht +existieren, kann diese Funktion durch Umschalten mit '0' erreicht +werden. Die Tasten Grn und Gelb wechseln dann zu '<<' und '>>'. Das +Umschalten kann ber das Setup angepasst werden. +Man kann einen Fortschrittsbalken im Men 'Jetzt'/'Nchste' anzeigen lassen. +Falls text2skin verwendet wird, sollte die Option "text2skin" in den +Setup-Optionen "Zeige Fortschrittsbalken in 'Jetzt'"/"Zeige Fortschrittsbalken +in 'Nchste'" verwendet werden (Die Option 'graphisch' kann ebenfalls mit +text2skin funktionieren, das ist aber abhngig vom gewhlten skin) + +=head2 1.4 Men Setup + +=head3 1.4.1 Allgemein + +=over 4 + +=item - B + +Damit wird der Eintrag 'Suche' im Hauptmen ausgeblendet. Achtung: +wenn das Plugin der Taste Grn zugeordnet ist, dann bewirkt das +Ausblenden, dass wieder das VDR-Standardmen gerufen wird (um das zu +vermeiden s. unten). + +=item - B + +Falls nicht ausgeblendet, kann hier der Name des Hauptmen-Eintrags +hinterlegt werden. Vorgabe ist 'Programmfhrer'. Hinweis: Wenn man den +Eintrag abweichend von der Vorgabe setzt, ist der Eintrag nicht mehr +abhngig von der gewhlten OSD-Sprache. Setzt man den Eintrag wieder auf den +Default oder auf leer ist die Abhngigkeit wieder gegeben. + +=item - B + +Auswahl von 'Programm' oder 'Jetzt' als Startmen. + +=back + +=head3 1.4.2 EPG Mens + +=over 4 + +=item - B + +Hier kann das Verhalten der 'Ok'-Taste bestimmt werden. Man kann damit +die Inhaltsangabe anzeigen oder zum entsprechenden Sender +wechseln. Hinweis: Die Funktion der Taste 'Blau' (Umschalten/Info/Suche) +hngt von dieser Einstellung ab. + +=item - B + +Auswahl, ob man den Standard ('Aufnehmen') oder 'Befehle' als +Vorbelegung mchte. + +=item - B + +Auswahl, ob man den Standard ('Umschalten') oder 'Suche' als +Vorbelegung mchte. + +=item - B + +Im Men 'Jetzt' kann ein Fortschrittsbalken angezeigt werden, der +den Fortschritt der laufenden Sendung anzeigt. Falls text2skin verwendet +wird, sollte die Option "pipes" verwendet werden (Die Option 'graphisch' +kann ebenfalls mit text2skin funktionieren, das ist aber abhngig vom +gewhlten skin) + +=item - B + +auswhlen, um eine fhrende Programmnummer vor jedem EPG-Eintrag +anzuzeigen. + +=item - B + +zur Anzeige einer Trennzeile zwischen Kanalgruppen im Men +'bersicht - Jetzt' ... + +=item - B + +zur Anzeige einer Trennzeile zwischen Sendungen unterschiedlicher +Tage im Men 'Programm'. + +=item - B + +Zeigt auch Radiokanle an. + +=item - B + +Bei einer sehr groen Kanalliste lt sich der Men-Aufbau mit dieser +Einstellung durch eine Einschrnkung der angezeigten Kanle beschleunigen. Mit +'0' wird das Limit aufgehoben. Wenn der aktuelle Kanal ber dem Limit liegt, +wird das Limit ignoriert und wieder alle Kanle angezeigt. + +=item - B + +Falls 'Ja' wird ein Timer sofort erzeugt, sobald man 'Aufnehmen' drckt, wie +in vdr-1.3.38 eingefhrt, sonst wird das Timer-Edit-Men angezeigt. + +=item - B + +zur Anzeige von Programmen ohne EPG, um auf diese umschalten zu +knnen oder einen Timer zu programmieren + +=item - B + +Falls 'Ja' wird nach Drcken von 'Aufnahme' sofort ein Timer angelegt, wie +in vdr-1.3.38 eingefhrt, falls 'Nein' erscheint das Timer-Edit-Men. + +=item - B + +In den Mens 'Programm', 'Jetzt', 'Nchste', 'Benutzerdef. Zeit 1', +... kann die angezeigte Zeit durch drcken von FastRew, FastFwd +verschoben werden. Die Anzahl Minuten fr den Sprung kann hier +angepasst werden. + +=item - B + +Falls die Tasten FastRew, FastFwd auf der Fernbedienung nicht +vorhanden sind, dann auf 'ja' setzen. Wenn die Taste '0' gedrckt +wird, werden somit auch die Tasten Grn/Gelb auf z.B. '<<' und '>>' +umgeschaltet. + +=item - B + +Das Favoritenmen kann dazu verwendet werden, eine Liste von bevorzugten +Sendungen anzuzeigen, die innerhalb der nchsten 24 Stunden laufen. Je nach +Einstellung erscheint dieses Men vor oder nach den EPG-Mens mit +benutzerdef. Zeiten. Die Auswahl von Sendungen wird durch setzen der Option +'In Favoriten-Men verw.' innerhalb einer Suche geregelt. + +=item - B + +Mit diesem Wert wird die Zeitspanne eingestellt, fr die Favoriten angezeigt +werden sollen. + +=back + +=head3 1.4.3 Benutzerdef. EPG-Zeiten + +=over 4 + +=item - B + +Bis zu 4 benutzerdefinierte Zeiten knnen zu 'Jetzt' und 'Nchste' +hinzugefgt werden. + +=item - B + +Name der benutzerdef. Zeit, z.B. 'Nachmittags', 'Abends', +'Sptabends'. + +=item - B + +zugehrige Uhrzeit. + +=back + +=head3 1.4.4 Timer-Programmierung + +=over 4 + +=item - B + +Beim normalen Programmieren eines Timers verwendet epgsearch ein +erweitertes Timer-Edit-Men, das einen Verzeichniseintrag, +benutzerdefinierte Wochentage und die Vervollstndigung um +Untertitel anbietet. Falls man einen gepatchten VDR verwendet der +ebenfalls ein erweitertes Timer-Edit-Men anbietet und lieber dieses +verwenden will, dann einfach diese Option auf 'Ja' setzen. + +=item - B + +Dieser Eintrag wird beim normalen Programmieren eines Timers +verwendet. Man kann auch EPG-Variablen verwenden (z.B.. 'Meine +Filme~%Category%~%Genre%'). Wird das Timer-Edit-Men aufgerufen +versucht epgsearch alle Variablen durch die Werte in der +Beschreibung der Sendung zu ersetzen. Konnten nicht alle ersetzt +werden, bleibt der Verzeichniseintrag leer. + +=item - B + +Beim manuellen Programmieren eines Timers kann epgsearch den +Untertitel automatisch im Dateinamen ergnzen, wodurch die sptere +Aufnahme in einem Unterverzeichnis fr diese Episode gespeichert +wird. Hier whlt man wie die Ergnzung gemacht werden +soll. 'Intelligent' versucht zu prfen, ob es Sinn macht und prft +dazu die Lnge einer Sendung. Ist diese lnger als 80min wird keine +Untertitel ergnzt. + +=item - B + +Manuell angelegte Timer knnen auf nderungen im EPG berprft werden. Hier +kann die Standardeinstellung fr die Prfmethode je Kanal hinterlegt +werden. Folgende Prfmethoden existieren: + * ohne berwachung + * anhand Sendungskennung: geprft wird anhand einer Kennung, die durch den + Sender vergeben wird. (Achtung: nicht jeder Sender liefert vernnftige + Kennungen!) + * anhand Sender/Uhrzeit: geprft wird anhand der Sendung, die am besten zur + Dauer der ursprnglichen Sendung passt. + +Nicht alle Sender liefern eine vernnftige Sendungskennung. Deshalb kann hier +die Standardeinstellung fr jeden Kanal einzeln gesetzt werden. Bei der +Programmierung eines manuellen Timers wird diese im Timer-Edit-Men +vorgegeben, falls das epgsearch-eigene Men benutzt wird. + +=back + +=head3 1.4.5 Suche und Suchtimer + +=over 4 + +=item - B + +falls ja, untersucht das Plugin im Hintergrund die EPG-Daten und +erzeugt Timer, falls passende Eintrge gefunden werden. Dies +betrifft nur Sucheintrge, die mit 'Als Suchtimer verwenden' +markiert sind. + +=item - B + +Das Intervall in Minuten, in dem die Hintergrundsuche vorgenommen +wird. + +=item - B + +Falls nicht der Standard-SVDRP-Port 2001 verwendet wird, dann bitte +hier anpassen, damit die Suchtimer funktionieren. + +=item - B + +Voreinstellungen + +=item - B + +zum Unterdrcken von Sendungs-Ankndigungen whrend einer aktiven Wiedergabe. + +=item - B + +epgsearch merkt sich standardmig welche Timer bereits durch Suchtimer +angelegt wurden und programmiert diese nicht erneut, wenn sie gelscht +wurden. Zum Abschalten dieses Verhaltens bitte 'Ja' whlen. + +=item - B + +Auf 'Ja' setzen, wenn man bei der Suche nach Wiederholungen keine Sendungen +von PayTV-Sendern haben will. + +=item - B + +Hier knnen Suchvorlagen verwaltet werden, die beim Anlegen neuer Suchen +verwendet werden knnen. + +=item - B + +Hier knnen Ausschlusslisten verwalten werden. Diese knnen innerhalb einer +Suche verwendet werden um unerwnschte Sendungen zu vermeiden. + +=item - B + +verwaltet die Kanalgruppen, die als Suchkriterium in einer Suche +verwendet werden knnen. Die Verwaltung ist auch im Edit-Men einer +Suche mglich. + +=back + +B: wenn der EPG aus einer externen Quelle bezogen wird, sollte dafr +gesorgt werden, dass die Suchtimer-Updates whrend des EPG-Updates +abgeschaltet sind. Der Grund dafr ist, dass epgsearch Timer lscht, denen +keine Sendungen zugeordnet sind. Whrend der neue EPG an VDR bermittelt wird, +kann diese Situation auftreten. Am einfachsten geht das mit dem SVDRP-Befehl +SETS im EPG-Update-Skript: + +svdrpsend.pl plug epgsearch SETS off + + + +svdrpsend.pl plug epgsearch SETS on + + +=head3 1.4.6 Timer-Konflikt-Prfung + +=over 4 + +=item - B + +Falls ein Timer fehlschlagen wird, dessen Prioritt unter dem angegebene +Wert liegt, wird darauf nicht per OSD-Nachricht hingewiesen und der Konflikt +wird als 'nicht relevant' in der Konflikt-bersicht angezeigt. + +=item - B + +Falls ein Konflikt nicht lnger als die angegebene Anzahl Minuten dauert, +wird darauf nicht per OSD-Nachricht hingewiesen und der Konflikt wird als +'nicht relevant' in der Konflikt-bersicht angezeigt. + +=item - B + +Hier kann der Zeitraum der Prfung angegeben werden. + +=item - B + +Das bewirkt eine Konfliktprfung nach jeder manuellen Timer-Programmierung +und erzeugt eine OSD-Nachricht, falls der neue/genderte Timer in einen +Konflikt verwickelt ist. + +=item - B + +Hier auf 'Ja' setzen, wenn die Konfliktprfung beim Beginn jeder Aufnahme erfolgen soll. +Im Falle eines Konflikts wird dann sofort eine Nachricht angezeigt. Diese erscheint nur, +wenn der Konflikt innerhalb der nchsten 2 Stunden auftritt. + +=item - B + +Hier kann eingestellt werden, ob eine Konfliktprfung nach jedem +Suchtimer-Update erfolgen soll. Falls nicht: + +=item - B + +gibt an nach wievielen Minuten im Hintergrund eine automatische +Konfliktprfung erfolgen soll. Bei relevanten Konflikten erfolgt eine +Nachricht per OSD. Mit '0' wird diese Funktion deaktiviert. + +=item - B + +Wenn nchster Konflikt in ... Minuten eintritt, verwende folgendes +Prfintervall. + +=over 4 + +=item - B + +um einen Konflikt in Krze nicht zu bersehen, kann hier ein krzeres +Prfintervall eingestellt werden. + +=back + +=item - B + +Bitte auf 'Ja' setzen, wenn whrend einer Wiedergabe keine OSD-Benachrichtigungen +ber Timer-Konflikte gewnscht sind. Die Benachrichtigung erfolgt trotzdem, +wenn der nchste Konflikt innerhalb der nchsten 2 Stunden auftritt. + +=back + +Bitte ebenfalls den Abschnitt 'Working with the timer conflict menu' im MANUAL +bercksichtigen. + +=head3 1.4.7 Email-Benachrichtigungen + +(Bitte sicherstellen, dass 'sendEmail.pl' im Pfad der ausfhrbaren Dateien +liegt und 'epgsearchupdmail.templ' und 'epgsearchconflmail.templ' im +Konfig-Verzeichnis von epgsearch existieren!) + +=over 4 + +=item - B + +Diese Option aktivieren, wenn man eine Email-Benachrichtigung wnscht, sobald +der Suchtimer-Hintergrund-Thread + + - neue Timer angelegt hat + - vorhandene Timer gendert hat + - Timer gelscht hat, weil diese wegen EPG-nderungen oder anderen + Benutzeraktionen nicht mehr gltig sind. + +(Dazu muss ebenfalls die Option 'Verwende Suchtimer' im Suchtimer-Setup aktiv sein.) + +=item - B + +Diese Option aktivieren, wenn man eine Email-Benachrichtigung bei +Timer-Konflikten wnscht. Es werden nur Konflikte gemeldet, die laut +Setup-Einstellungen 'relevant' sind. Neue Benachrichtigungen werden nur +versandt, sobald sich etwas bei den Konflikten verndert. + +(Dazu muss ebenfalls die Option 'Nach jedem Suchtimer-Update' oder 'nach +... Minuten' im Timer-Konflikt-Setup aktiv sein.) + +=item - B + +Hier bitte die volle (!) Email-Adresse hinterlegen, an die die Nachrichten +verschickt werden sollen. Hinweis: Einigen Provider (z.B. Arcor) erlauben nicht +die gleiche Adresse fr Sender und Empfnger. + +=item - B + +Zur Auswahl stehen + + - sendEmail.pl: ein einfaches Skript, das auch auf Systemen ohne + konfigurierten Mailserver den Versand von Emails erlaubt. Das Skript wird + mit epgsearch ausgeliefert und sollte im $PATH liegen. + - sendmail: setzt ein korrekt aufgesetzes Mailsystem voraus. + +=item - B + +Hier bitte die volle (!) Email-Adresse hinterlegen, von der die Nachricht versandt +werden soll. + +=item - B + +Der Name des SMTP Servers, ber den der Mailversand erfolgt. + +=item - B + +'Ja' whlen wenn das Emailkonto eine SMTP-Authentifizierung fr den +Emailversand bentigt. + +=item - B + +Hier bitte den Benutzernamen angeben, falls das Email-Konto mit +Authentifizierung arbeitet. + +=item - B + +Hier bitte das Passwort angeben, falls das Email-Konto mit +Authentifizierung arbeitet. +Achtung: Das Passwort wird im Klartext gespeichert. Man muss selber dafr +sorgen, dass das System sicher ist und nicht authorisierten Personen kein +Zugriff auf VDR-Konfigurations-Dateien mglich ist. + +=back + +Nach Angabe der Email-Konto-Daten bitte mit 'Test' prfen, ob alles +funktioniert. Wenn mit 'sendEmail.pl' gearbeitet wird, sollte am Ende der +Test-Ausgabe etwas wie 'Email sent successfully' auftauchen. Die Testfunktion +gibt es bei der Methode 'sendmail' leider nicht. + +Bitte ebenfalls den Abschnitt 'Email notifications' im Manual bercksichtigen. + +=head1 2. Suchtimer + +Das ist ziemlich das gleiche wie VDRAdmin's Autotimer, bentigt jedoch +kein externes Programm. Beim Anlegen einer Suche kann man die Option +setzen, ob diese als Suchtimer verwendet werden soll. Das Plugin sucht +nun im Hintergrund in bestimmten Zeitabstnden (->Setup->Update +Intervall [min]) nach passenden Sendungen und erzeugt Timer fr die +Ergebnisse. Gerade fr Serien ist dies sehr praktisch, weshalb es in +der Suche die Option "Serienaufnahme" gibt. In diesem Fall wird ein +Timer mit zustzlichem Episodennamen angelegt. Die Aufnahme erscheint +dann in einem Ordner mit dem Seriennamem. Falls es keinen Episodennamen gibt +wird stattdessen automatisch Datum und Uhrzeit verwendet. + +Die Suchtimer-Funktion muss ausserdem im Setup aktiviert werden. +Falls fr SVDRP nicht der Standardport 2001 verwendet wird, bitte +ebenfalls im Setup eintragen. + +Falls man eine Hintergrund-Suche manuell anstoen will, gengt ein + +touch /etc/vdr/plugins/epgsearch/.epgsearchupdate + +Das kann ebenfalls Teil des shutdown-Skripts sein (hier sollte man +dann noch einen sleep von ein paar Sekunden anhngen, damit das Plugin +Zeit hat, den Scan zu beenden). + +Mehr Infos zu Suchtimern gibts im MANUAL unter 'Description of the +search process' und 'How do Search Timers work?'. + +=head1 2.1 'Wiederholungen vermeiden' - Im Detail + +Hier soll erklrt werden wie die Option 'Wiederholungen vermeiden' +eines Suchtimers funktioniert. + +Nicht immer lsst sich durch entsprechende Suchkriterien vermeiden, +dass auch Timer fr Wiederholungen erzeugt werden. + +Um das zu verhindern, versucht das Feature 'Wiederholungen vermeiden' +vor dem Programmieren einer Sendung zu prfen, ob eine gleiche Sendung +schon mal aufgenommen wurde oder ein Timer existiert, der die gleiche +(nicht dieselbe!) Sendung aufzeichnet. Ist dies der Fall, wird kein +Timer fr die zu berprfende Sendung erzeugt. + +=head2 2.2 Wie funktioniert der Vergleichstest zwischen 2 Sendungen? + +Fr den Test auf Gleichheit zwischen 2 Sendungen gibt es viele +Einstellmglichkeiten beim Suchtimer. Man kann whlen, ob Titel, +Untertitel, Beschreibung und bestimmte Kategorien innerhalb der +Beschreibung einer Sendung mit den jeweiligen Angaben einer anderen +Sendung verglichen werden sollen. + +Der Vergleich der einzelnen Angaben selbst prft immer auf +vollstndige Identitt. Die Beschreibung einer Sendung bildet hier +aber eine Ausnahme. Hier wird zunchst alles aus dem Text entfernt, +das einer Kategorie-Angabe gleicht, z.B. 'Bewertung: Tagestipp'. Als +Kategorie-Angabe wird alles gewertet, was am Anfang einer Zeile +maximal 40 Zeichen hat, von einem ':' gefolgt wird und dann maximal +weitere 60 Zeichen hat. Hintergrund fr dieses Rausschneiden sind die +oft vorhandenen Bewertungen wie 'Tagestipp', die bei der Wiederholung +aber nicht mehr enthalten sind. + +Der verbleibende Text wird nun zunchst in der Lnge verglichen. Ist +der Unterschied grer als 90% wird die Beschreibung als +unterschiedlich gewertet. Andernfalls wird ber den +Levinsthein-Distance-Algorithmus (LD), der einen Fuzzy-Textvergleich +macht, ein Test vorgenommen. Hier wird die Beschreibung als gleich +akzeptiert, wenn LD mehr als 90% Identitt zurckgibt. + +Da dieser Algorithmus ziemlich laufzeitintensiv ist (O(mn)), sollte +nach Mglichkeit nicht nur 'Vergleiche Beschreibung' als einziges +Vergleichskriterium ausgewhlt werden, sondern am besten immer nur in +Kombination mit anderen Vergleichen. + +=head2 2.3 Wie und wo wird der Vergleichstest eingesetzt? + +Wie zuvor erwhnt wird bei einem Suchtimer-Update fr Suchtimer mit +diesem Feature zustzlich geprft, ob eine Sendung bereits irgendwann +schon aufgezeichnet wurde, oder in der Timerliste ein Timer steht, der +die gleiche Sendung aufzeichnen wrde. Letzteres sollte klar sein, +whrend fr ersteres das File epgsearchdone.data ins Spiel kommt. + +Nach jeder Aufnahme, die durch einen Suchtimer mit 'Wiederholung vermeiden' +erzeugt wurde, werden alle Angaben zu dieser Sendung im genannten File +gespeichert. ber das Aktionenmen im Men 'Suche' kann man sich alle +Sendungen, die ein solcher Timer bisher aufgenommen hat, anzeigen +lassen und diese auch bearbeiten. In dieses File werden nur Aufnahmen +aufgenommen, die bezglich der Timerangaben korrekt begonnen und auch +beendet wurden. D.h. dass teilweise unvollstndige Aufnahmen nicht +registriert werden und somit beim nchsten Suchtimer-Update +automatisch ein neuer Timer fr diese Sendung erzeugt wird, falls +gefunden. + +B + +Man sieht, dass das ganze Feature stark von der Qualitt und dem +Umfang des verwendeten EPGs abhngt. Hat man einen entsprechenden +Suchtimer angelegt, ist es sinnvoll erstmal zu prfen, ob er auch das +richtige macht. Dazu gibt es fr solche Timer im Suchergebnis-Men auf +der Taste 'Blau' die zustzliche Belegung 'Timer-Vorschau'. Sendungen, +die noch keinen Timer haben ('T'), aber fr die einer aufgrund des +Features beim nchsten Suchtimer-Update programmiert wrde, haben dort +ein 'P' stehen. + +Hinweis: Mchte man wegen Konflikten einen bereits programmierten +Timer nicht verwenden, dann sollte dieser im Timermen deaktiviert +werden. Beim nchsten Suchtimer-Update wird dann einfach die nchste +mgliche Wiederholung programmiert, falls vorhanden. + +B + +Damit das Programmieren oder Nicht-Programmieren von Timern gerade bei +Verwendung dieses Features besser nachvollziehbar ist, wurde ein +Logfile fr epgsearch eingefhrt. Startet man epgsearch mit einem +Loglevel >= 2 (-P'epgsearch -v 2) werden beim Suchtimer-Update +in der Datei epgsearch.log hilfreiche Infos abgelegt. Siehe MANUAL fr +'command line options'. + +=head1 3. Verwendung der Suche durch andere Plugins oder Skripte + +Siehe C. + +=head1 4. Verwendung erweiterter EPG Infos + +Einige EPG Provider liefern zustzliche EPG Infos wie die Art der +Sendung, das Video und Audio Format, die Besetzung,... +Mit tvmovie2vdr oder epg4vdr knnen diese Daten in den VDR importiert +werden. + +Somit kann man also z.B. einfach einen Suchtimer erzeugen, der alle +Tagestipps findet, die in 16:9 ausgestrahlt werden. +Um diese Informationen in Suchtimern zu verwenden, muss anhand der +Datei epgsearchcats.conf im epgsearch-Konfig-Verzeichnis eine +Konfiguration vorgenommen werden. + +Das Format dieser Datei ist folgendes: + + ID|category name|name in menu|values separated by ','(option)|searchmode(option) + + - 'ID' sollte eine eindeutige ganze Zahl sein + Achtung: ndert man spter aus irgendeinem Grund diese ID mssen + die Suchtimer neu editiert werden! + - 'category name' ist der Name der Info lt. EPG Provider, z.B. 'Genre' + - 'name in menu' ist der Name im Men von epgsearch. + - 'values' ist eine optionale Liste von Werten fr diese Info. + - 'searchmode' gibt optional an, wie gesucht werden soll: + Textvergleich: + 0 - Der gesamte Begriff muss als Substring erscheinen + 1 - Die einzelnen Worte (getrennt durch ',', ';', '|' oder + '~') mssen alle als Substring auftauchen. Diese Einstellung ist + der Standardwert. + 2 - mindestens ein Wort (getrennt durch ',', ';', '|' oder + '~') muss als Substring auftauchen + 3 - exakte bereinstimmung + 4 - als regulrer Ausdruck + Numerischer Vergleich: + 10 - kleiner + 11 - kleiner oder gleich + 12 - grer + 13 - grer oder gleich + 14 - gleich + 15 - ungleich + +Beispiel-Dateien fr epgsearchcats.conf kommen mit dem +Plugin im Verzeichnis 'conf'. Einfach die passende ins +epgsearch-Konfig-Verzeichnis als epgsearchcats.conf kopieren, VDR neu starten und +dann das Eingabe-Men eines Suchtimers aufrufen. + +Weil das Aufsetzen einer neuen epgsearchcats.conf ziemlich lstig ist, +habe ich ein kleines Tool 'createcats' mitgeliefert, das den Groteil +der Arbeit erledigt. Es sollte mit dem Plugin bersetzt worden sein +und sich im Quellverzeichnis befinden. Einfach folgendermaen aufrufen: + +createcats /pfad_zu/epg.data + +Dieses Tool scannt nun die vorhandenen EPG infos und versucht daraus +die erweiterten Infos zu extrahieren. Das Ergebnis ist eine neue +epgsearchcats.conf, die aber noch editiert werden muss, weil sicher +nicht alles genau passt. Danach ins epgsearch-Konfig-Verzeichnis kopieren. +(Mehr ber createcats im Manual 'Using createcats') + +Details: epgsearch durchsucht die Zusammenfassung einer Sendung nach +dem Namen einer Kategorie gefolgt von ': '. Das geschieht fr alle +Kategorien, fr die im Suchtimer ein Wert gesetzt wurde. Die Suche +bercksichtigt die Gro/Kleinschreibung sowohl bezglich des +Kategorie-Namens als auch des Wertes. + +=head1 5. Ersetzen des Standardmen + +Um das Plugin als Ersatz fr VDR's Standard-Men zu verwenden, gengt +es die Zeile + + Green @epgsearch + +in die Datei keymacros.conf zu setzen. Falls kein weiterer Meneintrag +im Hauptmen erscheinen soll, dann den Eintrag des Plugins zunchst im +Setup ausblenden. Um das Plugin trotzdem mit der Taste "Grn" aufrufen +zu knnen, knnte man z.B. mein launcher-Plugin verwenden und +die Zeile + + Green @launcher x + +in die keymacros.conf schreiben, wobei x die Position von epgsearch +innerhalb des launcher listings ist. + +Achtung: Versteckt man das Plugin ohne die Verwendung des launcher +plugins oder anderer Patches, die das Aufrufen versteckter Plugins +erlauben, erhlt man das VDR-Standard-Men beim Drcken von Grn. Ab +VDR 1.3.32 sind dazu keine Patches oder Plugins mehr notwendig. + +Ein weiterer Ansatz ist ein Patch gegen VDR, der das Standardmen +'Programm' gegen epgsearch austauscht. +Hierzu VDR mit dem Patch vdr-replace-schedulemenu.diff.gz aus dem +Patches-Verzeichnis patchen. Danke an den Autor Uwe/egal@vdrportal. +Bei Anwendung dieses Patches sollte der Eintrag + + Green Schedule + +heien. Dieser Patch ist bereits in manchen Patchsammlungen, +z.B. Bigpatch, enthalten. + +=head1 6. Addons + +Mit epgsearch werden 2 weitere 'Mini'-Plugins ausgeliefert. Beide Plugins +erfordern, dass epgsearch ebenfalls installiert ist (epgsearch kann aber aus +dem Hauptmen ausgeblendet werden): + +=over 4 + +=item - B + +Wer nur die Suchfunktionen und/oder die Suchtimer von +epgsearch verwenden mchte oder einfach einen eigenen Hauptmeneintrag fr die +Suche wnscht, kann dies mit diesem Plugin erreichen. Es wird damit ein +Hauptmeneintrag "Suche" erzeugt, der einen direkt in das Suchenmen fhrt. +Aktivierung im VDR-Startskript mit "-Pepgsearchonly". + +=item - B + +Die Timer-Konfliktprfung kann ebenfalls als eigener +Hauptmeneintrag angelegt werden. ber eine Setup-Option lt sich auch +das Ergebniss der letzten Konfliktprfung direkt im Hauptmen anzeigen. +Aktivierung im VDR-Startskript mit "-Pconflictcheckonly". + +=back + +Viel Spass! + +Christian Wieninger + +=head1 Ausfhrliche Beschreibung + +Die ausfhrliche Beschreibung der internen Funktionen des Plugins findest +Du in der Datei MANUAL, die dem Plugin beigelegt sein sollten. + +Ob Du diese auf deinem System hast verrt dir + +C + +Sollte Deine Distribution diese Dateien nicht enthalten, kannst Du sie +dir online durchlesen + +L + +L + +L + +=head1 SIEHE AUCH + +C, C, C, C, C, C, C, C, C, C + +=head1 DATEIEN + +F + +Enthlt die Suchtimer. Siehe C. + +F + +Enthlt die Kategorien des erweiterten EPG. Siehe C. + +F + +Enthlt Befehle hnlich der commands.conf, die auf EPG-Eintrge angewandt werden knnen. Siehe C. + +F + +Enthlt Pfade die beim Bearbeiten eines Suchtimers ausgewhlt werden knnen. Siehe C. + +F + +Enthlt die vom User gewhlte Konfiguration der OSD Mendarstellung. Siehe C. + +F + +Enthlt die User-Variablen. Siehe C. + +F + +Enthlt die done-Liste. Siehe C. + +F + +Enthlt die Umschalttimer. Siehe C. + +F + +Enthlt die Ausschlussliste. Siehe C. + +F + +Enthlt die Kanalgruppen. Siehe C. + +F + +Enthlt die Vorlagen fr Suchtimer. Siehe C. + +=head1 AUTOR (man pages) + +Mike Constabel + +=head1 FEHLER MELDEN + +Fehlerberichte bitte im Bugtracker. + +L + +Mailinglist: + +L + +=head1 COPYRIGHT and LIZENZ + +Copyright 2004-2007 Christian Wieninger + +Dieses Programm ist freie Software. Sie knnen es unter den Bedingungen +der GNU General Public License, wie von der Free Software Foundation +verffentlicht, weitergeben und/oder modifizieren, entweder gem Version 2 +der Lizenz oder (nach Ihrer Option) jeder spteren Version. + +Die Verffentlichung dieses Programms erfolgt in der Hoffnung, dass es +Ihnen von Nutzen sein wird, aber OHNE IRGENDEINE GARANTIE, sogar ohne die +implizite Garantie der MARKTREIFE oder der VERWENDBARKEIT FR EINEN BESTIMMTEN +ZWECK. Details finden Sie in der GNU General Public License. + +Sie sollten ein Exemplar der GNU General Public License zusammen mit +diesem Programm erhalten haben. Falls nicht, schreiben Sie an die +Free Software Foundation, Inc. 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. +Oder rufen Sie in Ihrem Browser http://www.gnu.org/licenses/old-licenses/gpl-2.0.html +auf. + +Der Author kann ber cwieninger@gmx.de erreicht werden. + +Die Projektseite ist http://winni.vdr-developer.org/epgsearch + +Der MD5-Code ist abgeleitet aus dem Message-Digest Algorithm +von RSA Data Security, Inc.. + + + + + diff --git a/doc-src/de/epgsearch.conf.5.txt b/doc-src/de/epgsearch.conf.5.txt new file mode 100644 index 0000000..daae063 --- /dev/null +++ b/doc-src/de/epgsearch.conf.5.txt @@ -0,0 +1,142 @@ +=head1 NAME + +F - Die gespeicherten Suchtimer + +=head1 BESCHREIBUNG + +Die in epgsearch angelegten Suchtimer werden in dieser Datei gespeichert. + +Sie sollte nicht manuell editiert werden. Verwende stattdessen lieber SVDRP. + +=head1 FORMAT + +Aufgrund von mglichen Formatnderungen enthlt die Datei eine Versionsangabe. +Die Format-Version befindet sich in der ersten Zeile der Datei. + +Der allgemeine Feldtrenner ist C<':'>. + +Folgende Felder sind mglich: + + 1 - Einmalige Suchtimer ID + 2 - Suchstring + 3 - Verwende Zeit? 0/1 + 4 - Startzeit in HHMM + 5 - Stopzeit in HHMM + 6 - Verwende Kanal? 0 = nein, 1 = Intervall, 2 = Kanalgruppe, 3 = nur FTA + 7 - Wenn 'verwende Kanal' = 1 dann ist Kanal ID[|Kanal ID] im VDR Format, + Eintrge oder min/max Eintrge getrennt durch |, wenn 'Verwende Kanal' = 2 + dann der Kanalgruppenname + 8 - Beachte Gross-/Kleinschreibung? 0/1 + 9 - Suchmodus: + 0 - Der gesamte Suchbegriff muss genau so enthalten sein + 1 - Alle Suchbegriffe (Trenner sind Leerzeichen,',', ';', '|' oder '~') + mssen enthalten sein. + 2 - Mindestens ein Suchbegriff muss enthalten sein (Trenner sind + Leerzeichen, ',', ';', '|' oder '~'). + 3 - Der Suchbegriff muss genau zutreffen + 4 - Regulrer Ausdruck + 10 - Suche in Titel? 0/1 + 11 - Suche in Untertitel? 0/1 + 12 - Suche in Beschreibung? 0/1 + 13 - Verwende Lnge? 0/1 + 14 - Minimale Lnge der Sendung in Minuten + 15 - Maximale Lnge der Sendung in Minuten + 16 - Verwende als Suchtimer? 0/1 + 17 - Verwende Tag der Woche? 0/1 + 18 - Tag der Woche (0 = Sonntag, 1 = Montag...; + -1 Sonntag, -2 Montag, -4 Dienstag, ...; -7 So, Mo, Di) + 19 - Verwende als Serienaufnahme? 0/1 + 20 - Verzeichnis fr Aufnahme + 21 - Prioritt der Aufnahme + 22 - Lebensdauer der Aufnahme + 23 - Zeitpuffer am Anfang in Minuten + 24 - Zeitpuffer am Ende in Minuten + 25 - Verwende VPS? 0/1 + 26 - Aktion: + 0 = Lege Timer an + 1 = Benachrichtige nur per OSD (kein Timer) + 2 = Schalte nur um (kein Timer) + 27 - Verwende erweitertes EPG? 0/1 + 28 - Felder des erweiterten EPGs. Dieser Eintrag hat folgendes Format + (Trenner ist '|' fr jede Kategorie, '#' trennt ID vom Wert): + 1 - Die ID der Kategorie des erweiterten EPGs, festgelegt in + F, s. C + 2 - Wert des erweiterten EPGs fr diese Kategorie + (Ein ':' wird bersetzt in "!^colon^!", z.B. "16:9" -> "16!^colon^!9") + 29 - vermeide Wiederholungen? 0/1 + 30 - erlaubte Anzahl Wiederholungen + 31 - Vergleiche Titel bei Prfung auf Wiederholung? 0/1 + 32 - Vergleiche Untertitel bei Prfung auf Wiederholung? 0/1 + 33 - Vergleiche Beschreibung bei Prfung auf Wiederholung? 0/1 + 34 - Vergleiche erweitertes EPG bei Prfung auf Wiederholung? + Dieser Eintrag ist ein Bitfeld von Kategorie IDs. + 35 - Erlaube Wiederholungen nur innerhalb x Tagen + 36 - Lsche eine Aufnahme automatisch nach x Tagen + 37 - Aber behalte mindestens x Aufnahmen + 38 - Schalte x Minuten vor der Sendung um, wenn Aktion = 2 + 39 - Pausiere das Anlegene von Timern wenn x Aufnahmen vorhanden sind + 40 - Modus der Ausschlussliste: 0 = Aus, 1 = Whle aus, 2 = Alle + 41 - Verwende diese Ausschluss-Suchtimer, IDs getrennt durch '|' + 42 - Fuzzy Toleranz fr Suche + 43 - Verwende diese Suche im Favoriten Men, 0 = Nein, 1 = Ja + 44 - ID einer Menvorlage fr das Suchergebnis + +Folgende Zeichen werden bei der Speicherung bersetzt: + + : => | + | => !^pipe^! + +Es mssen nicht alle Felder belegt sein. Gefordert sind lediglich die ersten +11. + +=head1 BEISPIELE + + #version 2 - DONT TOUCH THIS! + 1:Kommissar Beck:0:::2:ffRecht:0:0:1:0:0:0:::1:0:0:1:%Category%~%Genre%:50:99:10:60:0:0:0::1:0:1:1:0:0:0:0:0 + 2:* Sgebrecht:0:::2:Hauptsender:0:0:0:0:0:0:::0:0:0:0:%Category%~%Genre%:50:99:10:10:0:0:1:1#|2#|3#|4#|5#|6#Marianne Sgebrecht|7#|8#|9#|10#|11#|12#|13#:1:0:1:0:0:0:0:0:0 + +=head1 SIEHE AUCH + +C + +=head1 AUTOR (man pages) + +Mike Constabel + +=head1 FEHLER MELDEN + +Fehlerberichte bitte im Bugtracker. + +L + +Mailinglist: + +L + +=head1 COPYRIGHT and LIZENZ + +Copyright 2004-2007 Christian Wieninger + +Dieses Programm ist freie Software. Sie knnen es unter den Bedingungen +der GNU General Public License, wie von der Free Software Foundation +verffentlicht, weitergeben und/oder modifizieren, entweder gem Version 2 +der Lizenz oder (nach Ihrer Option) jeder spteren Version. + +Die Verffentlichung dieses Programms erfolgt in der Hoffnung, dass es +Ihnen von Nutzen sein wird, aber OHNE IRGENDEINE GARANTIE, sogar ohne die +implizite Garantie der MARKTREIFE oder der VERWENDBARKEIT FR EINEN BESTIMMTEN +ZWECK. Details finden Sie in der GNU General Public License. + +Sie sollten ein Exemplar der GNU General Public License zusammen mit +diesem Programm erhalten haben. Falls nicht, schreiben Sie an die +Free Software Foundation, Inc. 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. +Oder rufen Sie in Ihrem Browser http://www.gnu.org/licenses/old-licenses/gpl-2.0.html +auf. + +Der Author kann ber cwieninger@gmx.de erreicht werden. + +Die Projektseite ist http://winni.vdr-developer.org/epgsearch + +Der MD5-Code ist abgeleitet aus dem Message-Digest Algorithm +von RSA Data Security, Inc.. + diff --git a/doc-src/de/epgsearchblacklists.conf.5.txt b/doc-src/de/epgsearchblacklists.conf.5.txt new file mode 100644 index 0000000..ea3784d --- /dev/null +++ b/doc-src/de/epgsearchblacklists.conf.5.txt @@ -0,0 +1,72 @@ +=head1 NAME + +F - Die gespeicherten Auschlusslisten-Suchtimer + +=head1 BESCHREIBUNG + +In epgsearch knnen Ausschlusslisten (Blacklists) angelegt werden. + +Dies sind im Grunde normale Suchtimer die in der Datei +F gespeichert werden. Zu jedem Suchtimer kann +man dann einen oder mehrere Eintrge aus der Ausschlussliste auswhlen. + +=head2 Funktion + +Suchtimer "Krimi" verwendet Ausschlusssuchtimer "Tatort" + +Ausschlusssuchtimer "Tatort" sucht "Tatort" + +Es werden alle Krimis gesucht und anschliessend wird nachgesehen ob ein +Ergebnisse auf den Ausschlusssuchtimer zutrifft. Dieses wird dann verworfen. + +=head1 FORMAT + +Diese Datei hat dasselbe Format wie die Datei F. Fr den +Aufbau verweise ich auf C. + +=head1 SIEHE AUCH + +C + +=head1 AUTOR (man pages) + +Mike Constabel + +=head1 FEHLER MELDEN + +Fehlerberichte bitte im Bugtracker. + +L + +Mailinglist: + +L + +=head1 COPYRIGHT and LIZENZ + +Copyright 2004-2007 Christian Wieninger + +Dieses Programm ist freie Software. Sie knnen es unter den Bedingungen +der GNU General Public License, wie von der Free Software Foundation +verffentlicht, weitergeben und/oder modifizieren, entweder gem Version 2 +der Lizenz oder (nach Ihrer Option) jeder spteren Version. + +Die Verffentlichung dieses Programms erfolgt in der Hoffnung, dass es +Ihnen von Nutzen sein wird, aber OHNE IRGENDEINE GARANTIE, sogar ohne die +implizite Garantie der MARKTREIFE oder der VERWENDBARKEIT FR EINEN BESTIMMTEN +ZWECK. Details finden Sie in der GNU General Public License. + +Sie sollten ein Exemplar der GNU General Public License zusammen mit +diesem Programm erhalten haben. Falls nicht, schreiben Sie an die +Free Software Foundation, Inc. 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. +Oder rufen Sie in Ihrem Browser http://www.gnu.org/licenses/old-licenses/gpl-2.0.html +auf. + +Der Author kann ber cwieninger@gmx.de erreicht werden. + +Die Projektseite ist http://winni.vdr-developer.org/epgsearch + +Der MD5-Code ist abgeleitet aus dem Message-Digest Algorithm +von RSA Data Security, Inc.. + + diff --git a/doc-src/de/epgsearchcats.conf.5.txt b/doc-src/de/epgsearchcats.conf.5.txt new file mode 100644 index 0000000..d682254 --- /dev/null +++ b/doc-src/de/epgsearchcats.conf.5.txt @@ -0,0 +1,140 @@ +=head1 NAME + +F - Die Kategorien des erweiterten EPGs, sofern vorhanden. + +=head1 BESCHREIBUNG + +Wenn man das EPG aus dem Internet bezieht, z.B. von Hrzu, enthlt das EPG +erweiterte Daten. Zustzlich zum Titel, Untertitel un der Beschreibung findet +man dann eine Liste der Darsteller, Jahr des Drehs, Episode der Serie, Kategorie +und Genre des Film, etc. + +Damit epgsearch diese verwenden kann mssen die Felder des erweiterten EPGs +Variablen zugeordnet werden. + +Einige Beispieldateien werden dem Plugin mitgeliefert und finden sich im +Verzeichnis "conf". + +Um eine eigene F zu erstellen dient das mitgelieferte Tool +F. + +Es scannt das vorhandene EPG und erstellt eine F. Diese +sollte an die eigenen Wnscche angepasst werden, eine Formatbeschreibung +findet sich im Kopf der Datei. + +=head1 FORMAT + +Auszug aus einer F: + +-------------------------------------------------------------------- + + This is just a template based on your current epg.data. Please edit! + Perhaps a category or its value list should be removed. Also the + 'name in menu' should be adjusted to your language. + The order of items determines the order listed in epgsearch. It does not + depend on the ID, which is used by epgsearch. + Format: + ID|category name|name in menu|values separated by ',' (option)|searchmode + - 'ID' should be a unique positive integer + (changing the id later on will force you to reedit your search timers!) + - 'category name' is the name in your epg.data + - 'name in menu' is the name displayed in epgsearch. + - 'values' is an optional list of possible values + if you omit the list, the entry turns to an edit field in epgsearch, + else it's an list of items to select from + - 'searchmode' is an optional parameter specifying the mode of search: + text comparison: + 0 - the whole term must appear as substring + 1 - all single terms (delimiters are ',', ';', '|' or '~') + must exist as substrings. This is the default search mode. + 2 - at least one term (delimiters are ',', ';', '|' or '~') + must exist as substring. + 3 - matches exactly + 4 - regular expression + numerical comparison: + 10 - less + 11 - less or equal + 12 - greater + 13 - greater or equal + 14 - equal + 15 - not equal + +-------------------------------------------------------------------- + +=head1 BEISPIELE + +(Die Zeilen sind gekrzt, daher unvollstndig) + +Beispiel fr EPG von Hrzu, bezogen von epgdata.com mit tvmovie2vdr. + + 1|Category|Kategorie|Information,Kinder,Musik,Serie,Show,Spielfilm,Sport|2 + + 2|Genre|Genre|Abenteuer,Action,Wirtschaft,Wissen,Zeichentrick|2 + + 3|Format|Video-Format|16:9,4:3|2 + + 4|Audio|Audio|Dolby Surround,Dolby,Hoerfilm,Stereo|2 + + 5|Year|Jahr||2 + + 6|Cast|Besetzung||2 + + 7|Director|Regisseur||2 + + 8|Moderator|Moderation||2 + + 9|Rating|Bewertung|Groartig besonders wertvoll,Annehmbar,Schwach|2 + + 10|FSK|FSK|6,12,16,18|2 + + 11|Country|Land||2 + + 12|Episode|Episode||4 + + 13|Themes|Thema||4 + +=head1 SIEHE AUCH + +C + +=head1 AUTOR (man pages) + +Mike Constabel + +=head1 FEHLER MELDEN + +Fehlerberichte bitte im Bugtracker. + +L + +Mailinglist: + +L + +=head1 COPYRIGHT and LIZENZ + +Copyright 2004-2007 Christian Wieninger + +Dieses Programm ist freie Software. Sie knnen es unter den Bedingungen +der GNU General Public License, wie von der Free Software Foundation +verffentlicht, weitergeben und/oder modifizieren, entweder gem Version 2 +der Lizenz oder (nach Ihrer Option) jeder spteren Version. + +Die Verffentlichung dieses Programms erfolgt in der Hoffnung, dass es +Ihnen von Nutzen sein wird, aber OHNE IRGENDEINE GARANTIE, sogar ohne die +implizite Garantie der MARKTREIFE oder der VERWENDBARKEIT FR EINEN BESTIMMTEN +ZWECK. Details finden Sie in der GNU General Public License. + +Sie sollten ein Exemplar der GNU General Public License zusammen mit +diesem Programm erhalten haben. Falls nicht, schreiben Sie an die +Free Software Foundation, Inc. 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. +Oder rufen Sie in Ihrem Browser http://www.gnu.org/licenses/old-licenses/gpl-2.0.html +auf. + +Der Author kann ber cwieninger@gmx.de erreicht werden. + +Die Projektseite ist http://winni.vdr-developer.org/epgsearch + +Der MD5-Code ist abgeleitet aus dem Message-Digest Algorithm +von RSA Data Security, Inc.. + diff --git a/doc-src/de/epgsearchchangrps.conf.5.txt b/doc-src/de/epgsearchchangrps.conf.5.txt new file mode 100644 index 0000000..4ae4703 --- /dev/null +++ b/doc-src/de/epgsearchchangrps.conf.5.txt @@ -0,0 +1,73 @@ +=head1 NAME + +F - Liste der Kanalgruppen + +=head1 BESCHREIBUNG + +In epgsearch kann man Sender zu Kanalgruppen zusammenfassen die dann in +den Suchtimern verwendet werden knnen. + +Hierdurch knnen fr viele Suchtimer auf einmal die durchsuchten Kanle zentral +neu konfiguriert werden. + +In dieser Datei werden die Kanalgruppen gespeichert. + +=head1 FORMAT + +Jede Zeile eine Kanalgruppe. Jede Zeile beginnt mit dem Gruppennamen, dahinter, getrennt durch '|', +die Liste der Kanle. + +=head1 BEISPIELE + +(Die Zeilen sind gekrzt, daher unvollstndig) + + Private|S19.2E-133-33-46|S19.2E-133-33-51 + ProsiebenSat.1|S19.2E-133-33-46|S19.2E-133-33-47 + RTL World|S19.2E-1-1089-12003||S19.2E-1-1089-12090 + +=head1 SIEHE AUCH + +C + +=head1 AUTOR (man pages) + +Mike Constabel + +=head1 FEHLER MELDEN + +Fehlerberichte bitte im Bugtracker. + +L + +Mailinglist: + +L + +=head1 COPYRIGHT and LIZENZ + +Copyright 2004-2007 Christian Wieninger + +Dieses Programm ist freie Software. Sie knnen es unter den Bedingungen +der GNU General Public License, wie von der Free Software Foundation +verffentlicht, weitergeben und/oder modifizieren, entweder gem Version 2 +der Lizenz oder (nach Ihrer Option) jeder spteren Version. + +Die Verffentlichung dieses Programms erfolgt in der Hoffnung, dass es +Ihnen von Nutzen sein wird, aber OHNE IRGENDEINE GARANTIE, sogar ohne die +implizite Garantie der MARKTREIFE oder der VERWENDBARKEIT FR EINEN BESTIMMTEN +ZWECK. Details finden Sie in der GNU General Public License. + +Sie sollten ein Exemplar der GNU General Public License zusammen mit +diesem Programm erhalten haben. Falls nicht, schreiben Sie an die +Free Software Foundation, Inc. 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. +Oder rufen Sie in Ihrem Browser http://www.gnu.org/licenses/old-licenses/gpl-2.0.html +auf. + +Der Author kann ber cwieninger@gmx.de erreicht werden. + +Die Projektseite ist http://winni.vdr-developer.org/epgsearch + +Der MD5-Code ist abgeleitet aus dem Message-Digest Algorithm +von RSA Data Security, Inc.. + + diff --git a/doc-src/de/epgsearchcmds.conf.5.txt b/doc-src/de/epgsearchcmds.conf.5.txt new file mode 100644 index 0000000..68995b3 --- /dev/null +++ b/doc-src/de/epgsearchcmds.conf.5.txt @@ -0,0 +1,78 @@ +=head1 NAME + +F - EPG-Befehle + +=head1 BESCHREIBUNG + +Diese Datei enthlt hnlich der commands.conf oder der reccmds.conf Befehle, die +auf die in der Programmbersicht ausgewhlte Sendung angewandt werden knnen. + +Intern besitzt epgsearch 8 nicht vernderbare EPG-Befehle. + +Wenn eine F existiert, werden die darin aufgefhrten Befehle +beginnend mit Nummer 9 gelistet. + +=head2 Sprachen + +Man kann fr verschiedene Sprachen unterschiedliche Dateien anlegen. Sie +mssen dann z.B. F fr deutsch oder +F fr englisch heissen. + +Wenn eine Datei entsprechend der im VDR eingestellten Sprache existiert wird +diese geladen. Existiert eine solche nicht wird versucht F +zu laden. + +=head1 FORMAT + +Befehlsname : Befehl + +=head1 BEISPIELE + +epg2taste (de): /usr/local/vdr/epg2taste.sh + +=head1 SIEHE AUCH + +C + +=head1 AUTOR (man pages) + +Mike Constabel + +=head1 FEHLER MELDEN + +Fehlerberichte bitte im Bugtracker. + +L + +Mailinglist: + +L + +=head1 COPYRIGHT and LIZENZ + +Copyright 2004-2007 Christian Wieninger + +Dieses Programm ist freie Software. Sie knnen es unter den Bedingungen +der GNU General Public License, wie von der Free Software Foundation +verffentlicht, weitergeben und/oder modifizieren, entweder gem Version 2 +der Lizenz oder (nach Ihrer Option) jeder spteren Version. + +Die Verffentlichung dieses Programms erfolgt in der Hoffnung, dass es +Ihnen von Nutzen sein wird, aber OHNE IRGENDEINE GARANTIE, sogar ohne die +implizite Garantie der MARKTREIFE oder der VERWENDBARKEIT FR EINEN BESTIMMTEN +ZWECK. Details finden Sie in der GNU General Public License. + +Sie sollten ein Exemplar der GNU General Public License zusammen mit +diesem Programm erhalten haben. Falls nicht, schreiben Sie an die +Free Software Foundation, Inc. 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. +Oder rufen Sie in Ihrem Browser http://www.gnu.org/licenses/old-licenses/gpl-2.0.html +auf. + +Der Author kann ber cwieninger@gmx.de erreicht werden. + +Die Projektseite ist http://winni.vdr-developer.org/epgsearch + +Der MD5-Code ist abgeleitet aus dem Message-Digest Algorithm +von RSA Data Security, Inc.. + + diff --git a/doc-src/de/epgsearchdirs.conf.5.txt b/doc-src/de/epgsearchdirs.conf.5.txt new file mode 100644 index 0000000..e252332 --- /dev/null +++ b/doc-src/de/epgsearchdirs.conf.5.txt @@ -0,0 +1,97 @@ +=head1 NAME + +F - Liste von Aufnahmepfaden zur einfachen Auswahl + +=head1 BESCHREIBUNG + +In epgsearch, speziell beim Editieren von Suchtimern, muss man hufig ganze +Verzeichnisspfade eingeben. Da dies oft mhselig ist, knnen in dieser Datei +hufig genutzte Pfade vorgegeben werden, die dann im Men einfach ausgewhlt +werden knnen. + +=head1 FORMAT + +Pro Zeile ein Pfad. Pfade knnen Variablen enthalten. + +Verwendet werden knnen interne Variablen, die Variablen des erweiterten EPG +(F) sowie die in der Datei F +konfigurierten Variablen. + +Folgende internen Variablen stehen zur Verfgung: + + %title% - Title der Sendung + %subtitle% - Subtitle der Sendung + %time% - Startzeit im Format HH:MM + %date% - Startzeit im Format TT.MM.YY + %datesh% - Startdatum im Format TT.MM. + %time_w% - Name des Wochentages + %time_d% - Tag der Sendung im Format TT + %chnr% - Kanalnummer + %chsh% - Kanalname kurz + %chlng% - Kanalname lang + +Fr weitere Variablen siehe C und C. + +Im Auswahlmen werden die Pfade alphabetisch sortiert dargestellt. Pfade die Variablen +enthalten stehen am Anfang der Liste. + +=head1 BEISPIELE + + %Category%~%Genre% + %Category%~%Genre%~%Title%~%Episode%: %Subtitle% + Information~Natur~%Title%~%Episode%: %Subtitle% + %Serie% + Spielfilm~Action + Spielfilm~Doku + Spielfilm~Drama + Spielfilm~Horror + Musik + Sport + Show + Serie + +=head1 SIEHE AUCH + +C, C, C + +=head1 AUTOR (man pages) + +Mike Constabel + +=head1 FEHLER MELDEN + +Fehlerberichte bitte im Bugtracker. + +L + +Mailinglist: + +L + +=head1 COPYRIGHT and LIZENZ + +Copyright 2004-2007 Christian Wieninger + +Dieses Programm ist freie Software. Sie knnen es unter den Bedingungen +der GNU General Public License, wie von der Free Software Foundation +verffentlicht, weitergeben und/oder modifizieren, entweder gem Version 2 +der Lizenz oder (nach Ihrer Option) jeder spteren Version. + +Die Verffentlichung dieses Programms erfolgt in der Hoffnung, dass es +Ihnen von Nutzen sein wird, aber OHNE IRGENDEINE GARANTIE, sogar ohne die +implizite Garantie der MARKTREIFE oder der VERWENDBARKEIT FR EINEN BESTIMMTEN +ZWECK. Details finden Sie in der GNU General Public License. + +Sie sollten ein Exemplar der GNU General Public License zusammen mit +diesem Programm erhalten haben. Falls nicht, schreiben Sie an die +Free Software Foundation, Inc. 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. +Oder rufen Sie in Ihrem Browser http://www.gnu.org/licenses/old-licenses/gpl-2.0.html +auf. + +Der Author kann ber cwieninger@gmx.de erreicht werden. + +Die Projektseite ist http://winni.vdr-developer.org/epgsearch + +Der MD5-Code ist abgeleitet aus dem Message-Digest Algorithm +von RSA Data Security, Inc.. + diff --git a/doc-src/de/epgsearchmenu.conf.5.txt b/doc-src/de/epgsearchmenu.conf.5.txt new file mode 100644 index 0000000..1c9b0e6 --- /dev/null +++ b/doc-src/de/epgsearchmenu.conf.5.txt @@ -0,0 +1,133 @@ +=head1 NAME + +F - Konfiguration der Mendarstellung + +=head1 BESCHREIBUNG + +Die Darstellung des Mens des Plugins kann auf die eigenen Wnsche +angepasst werden. Die Konfiguration erfolgt mit Hilfe dieser Datei. + +=head1 FORMAT + + In dieser Datei knnen den Variablen + + MenuWhatsOnNow + MenuWhatsOnNext + MenuWhatsOnElse + MenuSchedule + MenuSearchResults + +Zeichenketten zugewiesen werden die die Darstellung der Mens im OSD regeln. + +Eine Besonderheit stellt MenuSearchResults. Hier kann man der Variablen +MenuSearchResults eine beliebige Zeichenkette anhngen: + + MenuSearchResultsSerienlayout=... + +Dies bewirkt das man beim Editieren eines Suchtimers nun auch dieses Layout +unter dem Namen "Serienlayout" auswhlen kann. + +So kann man jedem Suchtimer seine eigene OSD Darstellung verpassen. + +Es knnen alle Variablen verwendet werden. Die Variablen aus dem erweiterten +EPG, die in der F konfigurierten sowie die folgenden +internen: + + %title% - Title der Sendung + %subtitle% - Subtitle der Sendung + %time% - Startzeit im Format HH:MM + %date% - Startzeit im Format TT.MM.YY + %datesh% - Startdatum im Format TT.MM. + %time_w% - Name des Wochentages + %time_d% - Tag der Sendung im Format TT + %time_lng% - Startzeit in Sekunden seit 1970-01-01 00:00 + %t_status% - Timerstatus ('T', 't', 'R') + %v_status% - VPS Status + %r_status% - Running Status + %status% - Kompletter Status, das selbe wie + '%t_status%%v_status%%r_status%' + +Fr die Mens "Was luft jetzt" und "Suchergebniss", also die Variablen +MenuWhatsOnNow und MenuSearchResults, stehen fnf weitere Variablen +zur Verfgung: + + %chnr% - Kanalnummer + %chsh% - Kanalname kurz + %chlng% - Kanalname lang + %chdata% - VDR's interne Kanaldarstellung (z.B. 'S19.2E-1-1101-28106') + %progr% - Grafischer Fortschrittsbalken (nicht fr das Men "Suchergenis") + %progrT2S% - Fortschrittsbalken im text2skin Stil (nicht fr das Men "Suchergenis") + +Es wird bei den Variablen nicht zwischen Gross-/Kleinschreibung unterschieden. + +Ein Eintrag besteht aus bis zu 6 Tabellenspalten, die Spalten werden durch +'|' getrennt. Der letzte Eintrag jeder Spalte kann die Spaltenbreite durch +angabe einer Breite in Zeichen festlegen. Die Breitenangabe wird durch ':' +vom Variablennamen getrennt. + +Wenn du Trenner wie '~', '-' oder '#' verwendest um einzelne Bestandteile zu +trennen, z.B. %title% ~ %subtitle%, dann achtet epgsearch darauf das ein +solcher Trenner nicht am Ende einer Spalte steht. + +Die einzelnen Spaltenbreiten sollten angepasst werden, das Aussehen ist vom +verwendeten Skin abhngig. + +Wenn diese Datei verndert werden soll whrend VDR luft kann man dem Plugin +den Startparamter '-r' oder '--reloadmenuconf' bergeben, die Datei wird dann +bei jedem ffnen des Mens neu eingelesen. + +=head1 BEISPIELE + + MenuWhatsOnNow=%chnr%:3|%progrt2s%:5| %time% %t_status%:8|%category%:6| %title% ~ %subtitle%:35 + MenuWhatsOnNext=%chnr%:3|%time% %t_status%:8|%category%:8| %title% ~ %subtitle%:35 + MenuWhatsOnElse=%chnr%:3|%time% %t_status%:8|%category%:8| %title% ~ %subtitle%:35 + MenuSchedule=%time% %t_status%:8|%genre%:14| %title% ~ %subtitle%:35 + MenuSearchResults=%chnr%:3|%datesh% %time% %t_status%:14|%genre%:8| %title%%colon% %subtitle%:35 + MenuFavorites=%chnr%:3|%datesh% %time% %t_status%:14|%genre%:8| %title%%colon%%subtitle%:35 + +=head1 SIEHE AUCH + +C, C, C + +=head1 AUTOR (man pages) + +Mike Constabel + +=head1 FEHLER MELDEN + +Fehlerberichte bitte im Bugtracker. + +L + +Mailinglist: + +L + +=head1 COPYRIGHT and LIZENZ + +Copyright 2004-2007 Christian Wieninger + +Dieses Programm ist freie Software. Sie knnen es unter den Bedingungen +der GNU General Public License, wie von der Free Software Foundation +verffentlicht, weitergeben und/oder modifizieren, entweder gem Version 2 +der Lizenz oder (nach Ihrer Option) jeder spteren Version. + +Die Verffentlichung dieses Programms erfolgt in der Hoffnung, dass es +Ihnen von Nutzen sein wird, aber OHNE IRGENDEINE GARANTIE, sogar ohne die +implizite Garantie der MARKTREIFE oder der VERWENDBARKEIT FR EINEN BESTIMMTEN +ZWECK. Details finden Sie in der GNU General Public License. + +Sie sollten ein Exemplar der GNU General Public License zusammen mit +diesem Programm erhalten haben. Falls nicht, schreiben Sie an die +Free Software Foundation, Inc. 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. +Oder rufen Sie in Ihrem Browser http://www.gnu.org/licenses/old-licenses/gpl-2.0.html +auf. + +Der Author kann ber cwieninger@gmx.de erreicht werden. + +Die Projektseite ist http://winni.vdr-developer.org/epgsearch + +Der MD5-Code ist abgeleitet aus dem Message-Digest Algorithm +von RSA Data Security, Inc.. + + diff --git a/doc-src/de/epgsearchswitchtimers.conf.5.txt b/doc-src/de/epgsearchswitchtimers.conf.5.txt new file mode 100644 index 0000000..edeaf7f --- /dev/null +++ b/doc-src/de/epgsearchswitchtimers.conf.5.txt @@ -0,0 +1,75 @@ +=head1 NAME + +F - Die gespeicherten Umschalttimer + +=head1 BESCHREIBUNG + +In epgsearch kann man ber das Programmen und die Suchtimer +Umschalttimer anlegen, die einem zu beginn der Sendung auf die +Sendung hinweisen oder gleich umschalten. + +Die Umschalttimer werden in dieser Datei gespeichert. + +=head1 FORMAT + +Der allgemeine Feldtrenner ist C<':'>. + +Folgende Felder sind mglich: + + 1 - Kanal + 2 - Event ID + 3 - Startzeit + 4 - Vorlaufzeit + 5 - Nur ankndigen + +=head1 BEISPIELE + + S19.2E-1-1089-12060:52221:1153322700:1:0 + +=head1 SIEHE AUCH + +C + +=head1 AUTOR (man pages) + +Mike Constabel + +=head1 FEHLER MELDEN + +Fehlerberichte bitte im Bugtracker. + +L + +Mailinglist: + +L + +=head1 COPYRIGHT and LIZENZ + +Copyright 2004-2007 Christian Wieninger + +Dieses Programm ist freie Software. Sie knnen es unter den Bedingungen +der GNU General Public License, wie von der Free Software Foundation +verffentlicht, weitergeben und/oder modifizieren, entweder gem Version 2 +der Lizenz oder (nach Ihrer Option) jeder spteren Version. + +Die Verffentlichung dieses Programms erfolgt in der Hoffnung, dass es +Ihnen von Nutzen sein wird, aber OHNE IRGENDEINE GARANTIE, sogar ohne die +implizite Garantie der MARKTREIFE oder der VERWENDBARKEIT FR EINEN BESTIMMTEN +ZWECK. Details finden Sie in der GNU General Public License. + +Sie sollten ein Exemplar der GNU General Public License zusammen mit +diesem Programm erhalten haben. Falls nicht, schreiben Sie an die +Free Software Foundation, Inc. 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. +Oder rufen Sie in Ihrem Browser http://www.gnu.org/licenses/old-licenses/gpl-2.0.html +auf. + +Der Author kann ber cwieninger@gmx.de erreicht werden. + +Die Projektseite ist http://winni.vdr-developer.org/epgsearch + +Der MD5-Code ist abgeleitet aus dem Message-Digest Algorithm +von RSA Data Security, Inc.. + + + diff --git a/doc-src/de/epgsearchtemplates.conf.5.txt b/doc-src/de/epgsearchtemplates.conf.5.txt new file mode 100644 index 0000000..71ef8af --- /dev/null +++ b/doc-src/de/epgsearchtemplates.conf.5.txt @@ -0,0 +1,60 @@ +=head1 NAME + +F - Die gespeicherten Suchtimer-Vorlagen + +=head1 BESCHREIBUNG + +Fr die Suchtimer knnen Vorlagen angelegt werden. Diese werden hier +gespeichert. + +=head1 FORMAT + +Diese Datei hat dasselbe Format wie die Datei F. Fr den +Aufbau verweise ich auf C. + +=head1 SIEHE AUCH + +C + +=head1 AUTOR (man pages) + +Mike Constabel + +=head1 FEHLER MELDEN + +Fehlerberichte bitte im Bugtracker. + +L + +Mailinglist: + +L + +=head1 COPYRIGHT and LIZENZ + +Copyright 2004-2007 Christian Wieninger + +Dieses Programm ist freie Software. Sie knnen es unter den Bedingungen +der GNU General Public License, wie von der Free Software Foundation +verffentlicht, weitergeben und/oder modifizieren, entweder gem Version 2 +der Lizenz oder (nach Ihrer Option) jeder spteren Version. + +Die Verffentlichung dieses Programms erfolgt in der Hoffnung, dass es +Ihnen von Nutzen sein wird, aber OHNE IRGENDEINE GARANTIE, sogar ohne die +implizite Garantie der MARKTREIFE oder der VERWENDBARKEIT FR EINEN BESTIMMTEN +ZWECK. Details finden Sie in der GNU General Public License. + +Sie sollten ein Exemplar der GNU General Public License zusammen mit +diesem Programm erhalten haben. Falls nicht, schreiben Sie an die +Free Software Foundation, Inc. 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. +Oder rufen Sie in Ihrem Browser http://www.gnu.org/licenses/old-licenses/gpl-2.0.html +auf. + +Der Author kann ber cwieninger@gmx.de erreicht werden. + +Die Projektseite ist http://winni.vdr-developer.org/epgsearch + +Der MD5-Code ist abgeleitet aus dem Message-Digest Algorithm +von RSA Data Security, Inc.. + + diff --git a/doc-src/de/epgsearchuservars.conf.5.txt b/doc-src/de/epgsearchuservars.conf.5.txt new file mode 100644 index 0000000..e40256a --- /dev/null +++ b/doc-src/de/epgsearchuservars.conf.5.txt @@ -0,0 +1,188 @@ +=head1 NAME + +F - Die Uservariablen + +=head1 BESCHREIBUNG + +In dieser Datei knnen Variablen definiert werden die dann in epgsearch +in allen Feldern, in denen Variablen mglich sind, zur Verfgung stehen. + +=head1 FORMAT + +Die Variablen selbst sind in dem Format %Variablenname% aufgebaut. + +"Variablenname" kann aus alphanumerischen Zeichen bestehen, Leerzeichen +und Sonderzeichen sind nicht erlaubt. + +Zwischen Gross-/und Kleinschreibung wird nicht unterscheiden. + +Beispiele fr mgliche Namen: + + %Serie% %DokuVar1% %ThemesSubtitleDate1% + +=head2 Zuweisung + +Die Zuweisung eines Wertes erfolgt so: + + %Serie%=Neue Serie~Krimi + +Hier wird der Variablen %Serie% die Zeichenkette "Neue Serie~Krimi" zugewiesen. + +Es wird immer eine Zeichenkette zugewiesen. Leerzeichen werden daher auch +als Leerzeichen mit bernommen. + + %Pfad%=%Serie% + +Hier wird der Variablen %Pfad% der Inhalt der Variablen %Serie% zugewiesen. + +Das lsst sich beliebig verwenden. + + %Pfad%=%Serie%~Tatort + +Pfad enthlt hier den String "Neue Serie~Krimi~Tatort". + +=head2 Kontroll-Strukturen + +Einfache "if then else" Konstrukte sind mgliche. + +Innerhalb dieser Konstrukte knnen keine Strings, wohl aber Variablen +zugwiesen werden. Leerzeichen werden ignoriert. + + %Foo%=Verschiedenes + + %Variable%=%Pfad% ? %Pfad% : %Foo% + +Ist Pfad nicht leer, weise %Variable% den Inhalt aus %Pfad% zu, sonst +den Inhalt aus %Foo%. + +"%Pfad% ?" bedeutet also "nicht leer?". Es sind auch andere Prfungen +mglich. + + %Variable%=%Pfad%!=5 ? %Pfad% : %Foo% + +"%Pfad%!=5 ?" bedeutet "ist %Pfad% ungleich 5?" + +Es knnen auch Variablen verglichen werden. + + %Fuenf%=5 + + %Variable%=%Pfad%!=%Fuenf% ? %Pfad% : %Foo% + + +Folgende Prfungen sind mglich: + + == ist gleich + != ist nicht gleich + +=head2 Systemaufruf + +Es knnen auch externe Programme/Scripte aufgerufen werden. Die zurck- +gegebene Zeichenkette wird dann einer Variablen zugewiesen. + + %Ergebnis%=system(scriptname,%Variable1% %Variable2% -f %Variable3% --dir=%Variable4% --dummy) + +Ruft das Script "scriptname" mit den Parametern "%Variable1%", +"%Variable2%", usw. auf. Das Ergebnis wird der Variablen %Ergebnis% +zugewiesen. + +Es sind beliebig viele Variablen mglich. + +Wenn ntig, umfasst epgsearch die Variablen automatisch mit "". + +Das Script darf nur eine Zeichenkette ohne Zeilenumbruch zurckgeben. + +Erfolgt keine Rckgabe wird der Variablen %Ergebnis% eine leere Zeichenkette +zugewiesen. + +=head2 Verfgbare Variablen + +Folgende Variablen sind bereits intern definiert und knnen verwendet +werden. + + %title% - Title der Sendung + %subtitle% - Subtitle der Sendung + %time% - Startzeit im Format HH:MM + %timeend% - Endzeit im Format HH:MM + %date% - Startzeit im Format TT.MM.YY + %datesh% - Startdatum im Format TT.MM. + %time_w% - Name des Wochentages + %time_d% - Tag der Sendung im Format TT + %time_lng% - Startzeit in Sekunden seit 1970-01-01 00:00 + %chnr% - Kanalnummer + %chsh% - Kanalname kurz + %chlng% - Kanalname lang + %chdata% - VDR's interne Kanaldarstellung (z.B. 'S19.2E-1-1101-28106') + + %summary% - Beschreibung + %htmlsummary% - Beschreibung, alle CR ersetzt durch '
' + %eventid% - Event ID + + %colon% - Das Zeichen ':' + %datenow% - Aktuelles Datum im Format TT.MM.YY + %dateshnow% - Aktuelles Datum im Format TT.MM. + %timenow% - Aktuelle Zeit im Format HH:MM + %videodir% - VDRs Aufnahme-Verzeichnis (z.B. /video) + %plugconfdir% - VDRs Verzeichnis fr Plugin-Konfigurationsdateien (z.B. /etc/vdr/plugins) + %epgsearchdir% - epgsearchs Verzeichnis fr Konfiguratzionsdateien (z.B. /etc/vdr/plugins/epgsearch) + +Desweiteren knnen die in der Datei F definierten Variablen +verwendet werden. Siehe dazu C. + +=head1 BEISPIELE + + # Wochentag, Datum, Uhrzeit + %Datum%=%time_w% %date% %time% + + # Themes oder Subtitle oder Datum + %ThemesSubtitleDate1%=%Subtitle% ? %Subtitle% : %Datum% + %ThemesSubtitleDate%=%Themes% ? %Themes% : %ThemesSubtitleDate1% + + # Rufe das Script auf das den Aufnahmepfad erzeugt + %DokuScript%=system(doku.pl,%Title%,%Subtitle%,%Episode%,%Themes%,%Category%,%Genre%) + %Doku%=%DokuScript% + +=head1 SIEHE AUCH + +C, C + +=head1 AUTOR (man pages) + +Mike Constabel + +=head1 FEHLER MELDEN + +Fehlerberichte bitte im Bugtracker. + +L + +Mailinglist: + +L + +=head1 COPYRIGHT and LIZENZ + +Copyright 2004-2007 Christian Wieninger + +Dieses Programm ist freie Software. Sie knnen es unter den Bedingungen +der GNU General Public License, wie von der Free Software Foundation +verffentlicht, weitergeben und/oder modifizieren, entweder gem Version 2 +der Lizenz oder (nach Ihrer Option) jeder spteren Version. + +Die Verffentlichung dieses Programms erfolgt in der Hoffnung, dass es +Ihnen von Nutzen sein wird, aber OHNE IRGENDEINE GARANTIE, sogar ohne die +implizite Garantie der MARKTREIFE oder der VERWENDBARKEIT FR EINEN BESTIMMTEN +ZWECK. Details finden Sie in der GNU General Public License. + +Sie sollten ein Exemplar der GNU General Public License zusammen mit +diesem Programm erhalten haben. Falls nicht, schreiben Sie an die +Free Software Foundation, Inc. 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. +Oder rufen Sie in Ihrem Browser http://www.gnu.org/licenses/old-licenses/gpl-2.0.html +auf. + +Der Author kann ber cwieninger@gmx.de erreicht werden. + +Die Projektseite ist http://winni.vdr-developer.org/epgsearch + +Der MD5-Code ist abgeleitet aus dem Message-Digest Algorithm +von RSA Data Security, Inc.. + diff --git a/doc-src/de/noannounce.conf.5.txt b/doc-src/de/noannounce.conf.5.txt new file mode 100644 index 0000000..83a3ba6 --- /dev/null +++ b/doc-src/de/noannounce.conf.5.txt @@ -0,0 +1,53 @@ +=head1 NAME + +F - Liste von Sendungen, die nicht mehr per OSD angekndigt +werden sollen. + +=head1 BESCHREIBUNG + +Diese Datei enthlt eine Liste von Sendungen die markiert wurden, sodass diese +nicht mehr durch den Suchtimer-Hintergrund-Thread per OSD angekndigt werden. + +Wenn whrend der Ankndigung einer Sendung eine der Tasten '0', ... '9' oder +'Ok' gedrckt wird, wird nachgefragt, ob zuknftige Ankndigungen vollstndig +(bei den Tasten '0' oder 'Ok') oder nur fr die nchsten x Tage (bei den +Tasten '1' bis '9') unterdrckt werden sollen. Besttigt man diese Abfrage +durch ein erneutes 'Ok', wird die Einstellung entsprechend bernommen. + +=head1 FORMAT + +Pro Zeile eine Sendung, die Felder werden durch ':' getrennt. + +Folgende Felder existieren: + + 1 - Titel + 2 - Episode + 3 - Kanal-Kennung + 4 - Startzeit + 5 - Zeitpunkt fr nchste Ankndigung + +=head1 SIEHE AUCH + +C + +=head1 AUTOR (man pages) + +Mike Constabel + +=head1 FEHLER MELDEN + +Fehlerberichte bitte im Bugtracker. + +L + +Mailinglist: + +L + +=head1 COPYRIGHT und LIZENZ + +Copyright 2005 - 2007 Christian Wieninger + +Dieses Dokument wird unter den Bedingungen der Gnu Public License +(GPL) verffentlicht. Alle Angaben sind nach bestem Wissen, aber +natrlich ohne Gewhr (no warranty in any kind). diff --git a/doc-src/de/timersdone.conf.5.txt b/doc-src/de/timersdone.conf.5.txt new file mode 100644 index 0000000..b61d096 --- /dev/null +++ b/doc-src/de/timersdone.conf.5.txt @@ -0,0 +1,55 @@ +=head1 NAME + +F - Liste von anstehenden Timern, die von Suchtimern erzeugt +wurden. + +=head1 BESCHREIBUNG + +Diese Datei enthlt eine Liste von anstendenden Timern, die von Suchtimern +erzeugt wurden. Wenn die Setup-Option 'Timer nach Lschen neuprogrammieren' +auf nein steht, benutzt epgsearch diese Liste, um zu prfen, ob ein Timer +bereits angelegt wurde und erstellt den Timer in diesem Fall nicht nochmals. +Sobald die zugehrige Aufnahme stattgefunden hat, wird der Timer automatisch +aus dieser Liste entfernt. + +=head1 FORMAT + +Pro Zeile ein Timer, die Felder werden durch ':' getrennt. + +Folgende Felder existieren: + + 1 - Kanal-Kennung + 2 - Startzeit + 3 - Stopzeit + 4 - Suchtimer-ID + 5 - Titel der Sendung + 6 - Untertitel der Sendung + +=head1 SIEHE AUCH + +C + +=head1 AUTOR (man pages) + +Mike Constabel + +=head1 FEHLER MELDEN + +Fehlerberichte bitte im Bugtracker. + +L + +Mailinglist: + +L + +=head1 COPYRIGHT und LIZENZ + +Copyright (c) 2005-2006 Christian Wieninger + +L + +Dieses Programm ist freie Software. Es darf nach belieben benutzt, +kopiert, modifiziert, verteilt und verkauft werden, solange niemand +anderem das Recht abgesprochen wird dasselbe zu tun. + diff --git a/doc-src/en/createcats.1.txt b/doc-src/en/createcats.1.txt new file mode 100644 index 0000000..cca13dd --- /dev/null +++ b/doc-src/en/createcats.1.txt @@ -0,0 +1,120 @@ +=head1 NAME + +B - helps you creating your own F + +=head1 SYNOPSIS + +B [OPTIONS] F + +=head1 DESCRIPTION + +This tool is deliverd with the plugin and should exist in the plugins +source directory after compilation. It helps you in creating your own +epgsearchcats.conf, if the samples in directory 'conf' don't fit your needs. + +createcats takes your epg.data as argument and scans it for suitable +EPG infos. Such an info is a set of a category name and a coresponding +value at the beginning of a line (represented with '|') and has the +form '|category: value', e.g. + + |Genre: Action + +So simply call it with + +B /path_to/epg.data + +The output is a file epgsearchcats.conf, that should be copied to your +plugins config dir. Before using it, you should do some customizing, +since not all things in the file will be suitable to be used as +extended EPG info. + +=head1 OPTIONS + +The full set of arguments is: + +usage: B [OPTIONS] F + + -m N, --minappearance=N the minimum number a category has to appear + to be used + -v N, --maxvalues=N values of a category are omitted if they exceed + this number + -l N, --maxlength=N the maximum length of a text to be accepted + as a category value + -h, --help this help + +Some notes: + +=over 4 + +=item -m N, --minappearance=N + +createcats counts how often a category is used in your current +epg.data. If this is less than N, then this category will not be part +of the resulting epgsearchcats.conf. + +=item -v N, --maxvalues=N + +if the number of values for a category is more than N then createcats +will not output a value list for this category. As a consequence in +epgsearch the menu item gets an edit item, that can be filled with +every text. Else, the item gets a selection item, that lets you select +from a list of values. + +=item -l N, --maxlength=N + +if the text length of a value is more than N, this value is not part +of the value list. + +=back + +B Results are best, if your current EPG is as big as possible. So +update it, if you are using an external EPG provider, before calling +createcats. + +Please edit this file now, since it will contain also things not suitable. + +After that copy it to your plugins config directory. + +=head1 SEE ALSO + +C, C, C + +=head1 AUTHOR (man pages) + +Mike Constabel + +=head1 REPORT BUGS + +Bugreports (german): + +L + +Mailinglist: + +L + + +=head1 COPYRIGHT and LICENSE + +Copyright (C) 2004-2007 Christian Wieninger + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +Or, point your browser to http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + +The author can be reached at cwieninger@gmx.de + +The project's page is at http://winni.vdr-developer.org/epgsearch + +The MD5 code is derived from the RSA Data Security, Inc. MD5 Message-Digest Algorithm. diff --git a/doc-src/en/epgsearch.1.txt b/doc-src/en/epgsearch.1.txt new file mode 100644 index 0000000..51e9e58 --- /dev/null +++ b/doc-src/en/epgsearch.1.txt @@ -0,0 +1,1116 @@ +=head1 NAME + +F - Searchtimer and replacement of the VDR program menu + +=head1 OVERVIEW + +EPG-Search can be used as a replacement for the default schedules +menu entry. It looks like the standard schedules menu, but adds some +additional functions: + + - Commands for EPG entries with 5 built-in commands like 'show repeats', + 'create search'. One can add own commands for other needs, like adding a + VDRAdmin auto-timer. + + - Add up to 4 user-defined times to 'now' and 'next' and an optional + favorites menu + + - Searching the EPG: Create reusable queries, which can also be used + as 'search timers'. + + - Search timers: Search for broadcasts in the background and add a + timer if one matches (similar to VDRAdmin's auto-timers) or simply + make an announcement about it via OSD + + - Avoid double recordings of the same event + * timer preview + * recognition of broken recordings + * fuzzy event comparison + + - Progress bar in 'What's on now' and 'What's on next' + + - Shift the time displayed by key press, e.g. 'What's on now' + 30 minutes + + - Start menu can be setup between 'Schedule' or 'What's on now' + + - background check for timer conflicts with a timer conflict manager + + - detailed EPG menu (summary) allows jumping to the next/previous + event + + - support for extended EPG info for search timers + + - extension of the timer edit menu with a directory item, user + defined weekday selection and a subtitle completion. + + - Timer conflict check, informs you over the OSD about conflicts + + - Timer conflict menu, show detailed information about the conflicts + and let you resolve them + + - Email notifications about search timer updates and timer conflicts + +Works only with >= vdr-1.3.46 or newer. + +Parts of the sources are based on the repeating-ECG patch from Gerhard Steiner, who gave me the permission to use them. Thanks for his work! + +=head1 OPTIONS + +=over 4 + +=item -f file, --svdrpsendcmd=file + +the path to svdrpsend.pl for external SVDRP communication (default is +internal communication, so this is usually not needed anymore) + +=item -c path, --config=path + +to specify a specific config directory for all epgsearch config files, default +is '/epgsearch' + +=item -l file, --logfile=file + +to specify a specific log file for epgsearch (default log file is +epgsearch.log in the epgsearchs config directory) + +=item -v n, --verbose=n + +verbose level for log file. Value 0 means no logging. Other values +are 1 (general messages), 2 (detailed messages), 3 (planned for extra +detailed info for debugging purposes) + +=item -r, --reloadmenuconf + +reload epgsearchmenu.conf with plugin call. This can be useful when testing +customized menu layouts. + +=item -m file, --mailcmd=file + +the external command to be used for mail delivery. The default uses +'sendEmail.pl'. If you are using a different command or script make sure that +it has the same parameter interface as sendEmail.pl. + +=back + +=head1 CONTENT + + 1. Description + 1.1 Menu commands + 1.2 Menu search + 1.2.1 Menu edit search + 1.2.2 Menu search results + 1.3 Extended 'now' and 'next' + 1.4 Menu setup + 2. Search timers + 2.1 'Avoid repeats' - internals + 2.2 How do we compare two events? + 2.3 How and when do we compare? + 3. Usage from other plugins or scripts + 4. Using extended EPG info + 5. Replacing the standard schedule menu + 6. Add-ons + +=head1 1. Description + +At first glance EPG-Search looks like the schedules menu entry of VDR. +By pressing the key '0', one can toggle the bottom color keys to access +additional functions (the default assignment of the color keys can be +adjusted by setup): + + +=head2 1.1 Menu Commands + +This menu displays commands that can be executed on the current +item. There are 8 built-in commands: + + - Repeats: Searches for repeats + + - Record + + - Switch + + - Create search + Switches to search menu and adds a new search with the name of the current + item (to avoid editing the name manually) + + - Search in recordings: + Search the recordings for a broadcast with the same name + + - Mark as 'already recorded': + This puts the selected event in the file epgsearchdone.data and instructs + epgsearch to avoid recording this event if an according search timer is set + to "avoid repeats". An already created timer will be automatically removed + with the next search timer update. + + - Add/Remove to/from switch list?: + Controls the switch list. If there is an event in the switch list, epgsearch + will announce it and switch to the event before it starts. To access the + complete switch list, call 'Search/Actions/Switch list'. + + - Create blacklist: + A blacklist is used to ignore events when using search timers. A search + timer can be setup to ignore events from arbitrary blacklists. + +You can add your own commands to this menu by editing the file +epgsearchcmds.conf in epgsearchs config directory. There's a sample +conf file with some sample commands (see directory 'scripts', taken +from vdr-wiki.de, thanks to the authors). + +The format of the file is the same as VDR's commands.conf or +reccmds.conf. When a command is executed the following parameters +are passed to it: + + $1: the title of the EPG entry + $2: the start time of the EPG entry as time_t value (like in the + shutdown script) + $3: the end time + $4: the channel number of the EPG entry + $5: the long channel name of the EPG entry + $6: the subtitle of the EPG entry, "" if not present + +To execute a command from the main menu you can also press its +associated number without opening the commands menu. + +=head2 1.2 Menu search + +Here you can add, edit, delete and execute your own queries on the +EPG. The usage and behavior of this menu is similar to VDR's timer +menu. + +=head3 1.2.1 Menu edit search + +Most things in this menu are quite clear, so only some notes on: + +=over 4 + +=item - B + +The term to search for. If you like to search for more words, separate +them by blanks. Leaving this empty (combined with search mode +'Phrase') will match anything. This is useful, if you search e.g. for +anything that starts between some times on a specific channel. + +With 'blue' you can also select a template for the new search. If +one of the templates is set to default, new searches will +automatically get the settings of the default template. + +Note: fuzzy searching is limited to 32 chars! + +=item - B + +'Phrase' searches for the expression within the EPG. 'All words' +requires, that each word of the expression occurs in the EPG item. +'at least one word' requires, that only one word occurs in the EPG item. +'Match exactly' requires, that your search term matches exactly the +found title, subtitle or description. + +With 'Regular expression' you can setup a regular expression as +search term. You don't need a leading and trailing '/' in the +expression. By default these are POSIX extended regular expressions. +If you like to have Herl compatible regular expression, simply edit +the plugins Makefile and uncomment #HAVE_PCREPOSIX=1 to +HAVE_PCREPOSIX=1 (you will need pcreposix installed, comes with +libpcre from www.pcre.org, but it's already part of most distributions). + +See also C 'Description of the search process'. + +=item - B + +Only available if configured, see below 'Using extended EPG info'. + +=item - B + +If set to 'Yes' this tells epgsearch that a missing EPG category +should not exclude an event from the results. Caution: Using this without +any other criterions could flood your timers. + +=item - B + +Search only for events in the given channels interval, channel +groups or FTA channels only. + +Channel groups (e.g. sport channels or Pay-TV channels) can be +managed with a sub-menu called with 'blue'. + +ATTENTION: After changing the channels order please check the +settings of your search timers! + +=item - B + +Besides the weekdays you can also set up a user-defined selection, +e.g. search only on Monday and Friday. + +You'll find the user-defined selection in the list after Friday. + +=item - B + +You can select one or more or all blacklists here. If any search result +is also contained in one of the selected blacklists it will be skipped. + +=item - B + +Only available if turned on in setup. With this option you can mark a search +to be used in the favorites menu. The search results of all these searches are +listed in the favorites menu. + +=item - B + +Only available if you have defined more than one menu template for search +results in epgsearchmenu.conf. This option is used to assign a different menu +layout for the search results of this search. + +=item - B + +If set to yes, the plugin will do a background scan of the EPG in +certain intervals and add a timer, if there is a match. You have to +activate the 'search timers' in the setup. If set to "user defined" one +can specify time margins with key 'blue' where the search timer is active +or not. + +=item - B + +Default action is creating a timer for the search results. But you can +also choose to simply announce the found event via OSD or to switch +to the event one minute before it starts. + +=item - B + +If set to yes, the recordings will be stored in a folder with the name +of the broadcasting and the recordings itself will have the name of +the episode. If there is no episode name, the date and time of the +recording will be used. + +=item - B + +Here you can assign a directory, where the recording should be stored, +e.g. 'SciFi'. Use the key 'blue' to select directory entries already +used in other search entries or given by entries in the file +epgsearchdirs.conf (simply place your directories here one at each line +without the leading video directory, also see MANUAL). +If your provider delivers extended EPG infos you can also use +variables like "%Genre%" or "%Category%" in your directory +entry. These are replaced with the current EPG info, when a timer is +created. + +See also C 'Using variables in the directory +entry of a search timer'. + +=item - B + +Some recordings should only be kept for a few days, like news. With +this feature you can tell epgsearch to delete them automatically +after ... days. + +=item - B + +If the given numbers of recordings currently exists, then epgsearch +will not create further timers. After deleting one or more +recordings it will go on generating new timers. + +=item - B + +If you don't want to record repeats, this feature tries to check if +an event was already recorded/programmed and skips it. Please refer +to the section 'Avoid repeats - internals' below before using it. + +=item - B + +If you like to accept a certain amount of repeats you can give here +their number. + +=item - B + +Give here the number of days a repeat has to follow its first +broadcast. 0 is equal to no restriction. + +=item - B + +When comparing to events then specify here if the title should be +compared. + +=item - B + +When comparing to events then specify here if the subtitle should be +compared. If there is no subtitle than this event is always +different to an event with/without a subtitle. + +=item - B + +When comparing to events then specify here if the description should +be compared. + +For comparison all parts of the description, that look like a +category value, are removed first. The remaining text will be +compared. If this is similar at 90% (regarding the +Levinshtein-Distance algorithm) then it will be accepted as equal. + +=item - B + +With the button 'setup' you can also specify which categories should +be compared. As with subtitles an event is different if it has no +according category value. + +=item - B + +Each search timer can have its own settings for these parameters. +Defaults can be adjusted in the plugins setup. + +=item - B + +If set to yes, VPS is used, but only, if activated in VDR's setup menu and +if the broadcasting has VPS information. + +=item - B + +to automatically delete a search timer if the following is true: + + * after x recordings, or + * after x days after the first recording + +Only complete recordings are counted. The deletion is executed directly after +the correspondig recording + +=back + +To toggle the flag 'Use as search timer' without editing the search +entry you can use the key '2'. This will call directly the second +command of the command menu. + +=head3 1.2.2 Menu search results + +This menu displays the search results. A 'T' lets you know, that there +is already a timer for the event. A 't' means that there's only a +partial timer for it, as in standard schedules menu. + +=head2 1.3 Extended 'now' and 'next' and favorites + +By setup, one can add up to 4 additional times to extend the green +button, e.g. 'afternoon', 'prime time', 'late night'. Times, that are +already passed, are skipped (you will not get 'afternoon' at evening) with the +exception that a time will be displayed for the next day, if it is less then +20h in the future. +In these menus you can shift the currently displayed time by pressing +FastRew or FastFwd to move back and forward in time. If you don't have +these keys on your remote, you can access this function by pressing +'0' to toggle the green and yellow button to '<<' and '>>'. This toggling +can be adjusted by setup. + +You can display a progress bar in 'now' and 'next'. When using text2skin you +should use the setup option "text2skin" in the setup option "Show progress in +'Now'"/Show progress in 'Next'" (the setting 'graphical' may also work with +text2skin, but this depends on the selected skin). + +Furthermore you can enable in the setup an favorites list. You can configure +your searchtimers ("Use in favorite list") to display their results in +you favorite list. This list display event in the next 24 hours ordered by time. + +=head2 1.4 Menu setup + +=head3 1.4.1 General + +=over 4 + +=item - B + +This hides the main menu entry 'search'. Attention: when the plugin is +assigned to key 'green' then hiding the plugin will give you VDR's +standard schedule menu (see below to avoid this). + +=item - B
+ +If not hidden, the name of main menu entry can be set here. Default is +'Program guide'. Note: If you set it to something different from the default +then the main menu entry is no longer dependent on the OSD language. Setting +it back to default or empty restores this behavior again. + +=item - B + +Select the starting menu 'Schedules' or 'Now' + +=back + +=head3 1.4.2 EPG menus + +=over 4 + +=item - B + +Choose here the behavior of key 'Ok'. You can use it to display the summary +or to switch to the corresponding channel. Note: the functionality of key +'blue' (Switch/Info/Search) depends on this setting. + +=item - B + +Select if you like to have Standard ('Record') or 'Commands' as +assignment for key 'red'. + +=item - B + +select if you like to have Standard ('Switch') or 'Search' as +assignment for key 'blue'. + +=item - B + +In the menu 'what's on now' you can display a progress bar, that +displays the progress of the current item. When using text2skin you +should use the setup option "text2skin" (the setting 'graphical' may also +work with text2skin, but this depends on the selected skin). + +=item - B + +Select this if you like to have a leading channel number before each +item in the EPG menus. + +=item - B + +Display channel group separators between channel in the menus +'Overview now',... + +=item - B + +Display a day separator between events on different days in the +schedule menu. + +=item - B + +Also list radio channels. + +=item - B + +If you have a large channel set you can speed up things when you limit the +displayed channels with this setting. Use '0' to disable the limit. If the +current channel is above the limit, the limit is ignored and all channels will +be displayed again. + +=item - B<'One press' timer creation:> + +If set to 'yes' a timer is immediately created when pressing 'Record' as +introduced in vdr-1.3.38, else the timer edit menu is displayed. + +=item - B + +Display channels without EPG to allow switching or create a timer. + +=item - B