Jump to content


Photo

[Timer Overview] Please add full description


  • Please log in to reply
49 replies to this topic

#1 Qu@rk

  • Senior Member
  • 93 posts

+1
Neutral

Posted 25 December 2019 - 14:08

VTi and other images support this:

 

Please, would it be possible to add the full EPG description of a timer event to the Timer Overview?

 

I had a look in the source code and "description" is already there and supported by the skins.

 

Please, just add "fulldescription" as a label and widget. Would that be possible?

 

Thanks.

 



Re: [Timer Overview] Please add full description #2 Dimitrij

  • PLi® Core member
  • 6,762 posts

+224
Excellent

Posted 25 December 2019 - 17:13

I think not, although it is possible.

def parseEvent(ev, description = True):
	if description:
		name = ev.getEventName()
		description = ev.getShortDescription()
-		if description == "":
-			description = ev.getExtendedDescription()
+		ext_description = ev.getExtendedDescription()
+		if description == "" or description != ext_description:
+			description += "\n" + ext_description
	else:
		name = ""
		description = ""

 


Lunix3-4K/VU+solo4k(thanks guys to gisclub.tv)


Re: [Timer Overview] Please add full description #3 Qu@rk

  • Senior Member
  • 93 posts

+1
Neutral

Posted 25 December 2019 - 17:33

So, it will never be implemented?

 

It would be very helpful to see the full epg info of the timer event.


Edited by Qu@rk, 25 December 2019 - 17:35.


Re: [Timer Overview] Please add full description #4 Qu@rk

  • Senior Member
  • 93 posts

+1
Neutral

Posted 25 December 2019 - 18:07

How could I add this change in RecordTimer.py to enigma2 on my own STB (DUO4K)?

 

If I change the sourcecode in RecordTimer.py from GitHub and add it to the correct folder (renaming RecordTimer.pyo as backup) enigma2 will not start anymore (apologies for my naivety).



Re: [Timer Overview] Please add full description #5 betacentauri

  • PLi® Core member
  • 5,914 posts

+263
Excellent

Posted 25 December 2019 - 18:55

Which PLi version is installed?

You need to use same indentation like in the other lines(so at best tabs). A single space or tab can cause errors. Use an editor where you can see spaces and tabs.


Xtrend ET-9200, ET-8000, ET-10000, OpenPliPC on Ubuntu 12.04

Re: [Timer Overview] Please add full description #6 Qu@rk

  • Senior Member
  • 93 posts

+1
Neutral

Posted 25 December 2019 - 19:37

PLi 7.2 (latest build). I am familiar with Python. I use notepad++ or VS Code or PyCharm. 

 

So it should work if I change the source code and exchange the Python binary by the corresponding Python file? 


Edited by Qu@rk, 25 December 2019 - 19:39.


Re: [Timer Overview] Please add full description #7 Qu@rk

  • Senior Member
  • 93 posts

+1
Neutral

Posted 25 December 2019 - 20:03

Unfortunately no change in "Timer Overview": Skin is PLi-FullNightHD.

def parseEvent(ev, description = True):
	if description:
		name = ev.getEventName()
		description = ev.getShortDescription()
		ext_description = ev.getExtendedDescription()
		if description == "" or description != ext_description:
			description += "\n" + ext_description
	else:
		name = ""
		description = ""


Edited by Qu@rk, 25 December 2019 - 20:06.


Re: [Timer Overview] Please add full description #8 Qu@rk

  • Senior Member
  • 93 posts

+1
Neutral

Posted 26 December 2019 - 16:31

I am digging around. I am not sure whether I am on the right track.

 

Expanding "parseEvent" in RecordTimer.py would be only one step.

 

The other step would be to expand "TimerEdit.py".

	def updateState(self):
		cur = self["timerlist"].getCurrent()
		if cur:
			if cur.external:
				self["key_info"].setText("")
			else:
				self["key_info"].setText(_("Info"))
			text = cur.description
			if not cur.conflict_detection:
				text += _("\nConflict detection disabled!")
			self["description"].setText(text)

It gets the description from the stored timer.

 

So I need the correct EPG information (description + extended description) corresponding to the current selected timer.

 

So how do I get the event handler of the current timer and call the new parseEvent to get the extended descrption from the EPG?

		event = None
???		service = self.session.nav.getCurrentService()
		if service is not None:
			info = service.info()
			if info is not None:
				event = info.getEvent(0)

???            data = parseEvent(event, description = True)

Sorry if I am totally wrong. I try to understand but I have never looked into enigma2 sources before. And my Python knowledge is on a beginner's level.


Edited by Qu@rk, 26 December 2019 - 16:35.


Re: [Timer Overview] Please add full description #9 Pr2

  • PLi® Contributor
  • 4,004 posts

+167
Excellent

Posted 26 December 2019 - 18:02

Think also that you will probably need to adapt the skin too.

NO SUPPORT by PM, it is a forum make your question public so everybody can benefit from the question/answer.
If you think that my answer helps you, you can press the up arrow in bottom right of the answer.

Wanna help with OpenPLi Translation? Please read our Wiki Information for translators

Sat: Hotbird 13.0E, Astra 19.2E, Eutelsat5A 5.0W
VU+ Solo 4K: 2*DVB-S2 + 2*DVB-C/T/T2 (used in DVB-C) & Duo 4K: 2*DVB-S2X + DVB-C (FBC)
Edision OS Mio 4K: 1*DVB-S2X + 1*DVB-C/T/T2
 


Re: [Timer Overview] Please add full description #10 Qu@rk

  • Senior Member
  • 93 posts

+1
Neutral

Posted 26 December 2019 - 18:08

I checked, there is enough space within the skin for "description". PLi standard skins support this.

 

Example for PLi-FullNightHD:

	<!-- Timers -->

	<screen name="TimerEntry" position="fill" title="Timer entry" flags="wfNoBorder">
		<panel name="PigTemplate"/>
		<widget name="config" position="780,105" size="1110,765" itemHeight="38" font="Regular;28" scrollbarMode="showOnDemand"/>
	</screen>

	<screen name="TimerEditList" position="fill" title="Timer Overview" flags="wfNoBorder">
		<panel name="PigTemplate"/>
		<panel name="KeyBooleanTemplate"/>
		<widget name="timerlist" position="780,100" size="1110,912" scrollbarMode="showOnDemand" itemHeight="76" rowSplit="42" setEventNameFont="Regular;32" setServiceNameFont="Regular;28" setFont="Regular;28" satPosLeft="250"/>
		<widget name="description" position="30,528" size="720,420" transparent="1" font="Regular;30" halign="block"/>
	</screen>

Is there any chance for support how to implement and test this?



Re: [Timer Overview] Please add full description #11 Qu@rk

  • Senior Member
  • 93 posts

+1
Neutral

Posted 26 December 2019 - 19:10

 

I think not, although it is possible.

def parseEvent(ev, description = True):
	if description:
		name = ev.getEventName()
		description = ev.getShortDescription()
-		if description == "":
-			description = ev.getExtendedDescription()
+		ext_description = ev.getExtendedDescription()
+		if description == "" or description != ext_description:
+			description += "\n" + ext_description
	else:
		name = ""
		description = ""

@Dimitrij, thank you very much. Now I understand what you intended.

With every NEW timer, parseEvent is called to store the description within the timer data structure.

Of course, for existing timers nothing changes. But for new timers the extended description is stored.

That could be a solution.

 

Is there a chance for a commit?

 

Or would the other solution be better/more compatible to implement this in the TimerEdit.py and fetch the EPG info (extended description) during timer list display?



Re: [Timer Overview] Please add full description #12 Qu@rk

  • Senior Member
  • 93 posts

+1
Neutral

Posted 26 December 2019 - 19:18

Another thought:

 

The second solution, to fetch the actual event's EPG description during browsing through the timers list would be better.

EPG info of events can change over time. If a timer is several days in the future the EPG info is sometimes still not available.

 

And changing parseEvent does not work for timers created by AutoTimer because it uses its own parseEvent.


Edited by Qu@rk, 26 December 2019 - 19:21.


Re: [Timer Overview] Please add full description #13 Dimitrij

  • PLi® Core member
  • 6,762 posts

+224
Excellent

Posted 26 December 2019 - 20:46

And changing parseEvent does not work for timers created by AutoTimer because it uses its own parseEvent.
A short description in the AutoTimer is very important for finding matches and we cannot change it.
And by the way, therefore, I am against the addition of this commit based on the enigma code.
 
Use the TMBD plugin to fully save the description of your recorded video, this description is taken from the Internet.

 


Lunix3-4K/VU+solo4k(thanks guys to gisclub.tv)


Re: [Timer Overview] Please add full description #14 Qu@rk

  • Senior Member
  • 93 posts

+1
Neutral

Posted 26 December 2019 - 22:33

So there would be another solution in TimerEdit.py.

Display the current description while browsing through timers.

That would be very helpful and no timers would have to be touched.

Please consider it, it is very comfortable. It is much easier if you have a lot of timers created by autotimer.



Re: [Timer Overview] Please add full description #15 Qu@rk

  • Senior Member
  • 93 posts

+1
Neutral

Posted 27 December 2019 - 06:43

In Germany the free-TV channels do not provide correct filled descriptions in their EPG data.

Almost no channel fills short description and long description correctly. There is almost never a short description, only a long description.

At best with the first line containing the short description.

 

So almost all of my timers in the TimerEdit-screen do not have any description showed at all.

It is extremely difficult to check the timers, especially for TV shows, because there is no additional information displayed.



Re: [Timer Overview] Please add full description #16 littlesat

  • PLi® Core member
  • 50,763 posts

+564
Excellent

Posted 27 December 2019 - 07:46

Or show long description when short does not exists or is empty

WaveFrontier 28.2E | 23.5E | 19.2E | 16E | 13E | 10/9E | 7E | 5E | 1W | 4/5W | 15W


Re: [Timer Overview] Please add full description #17 Qu@rk

  • Senior Member
  • 93 posts

+1
Neutral

Posted 27 December 2019 - 09:03

Yes, but it would be more comfortable to have always both the short and long description in TimerEdit screen (like in other images, sorry).



Re: [Timer Overview] Please add full description #18 Qu@rk

  • Senior Member
  • 93 posts

+1
Neutral

Posted 27 December 2019 - 14:31

I would like to try this by myself.

I was digging around but I still do not understand the classes and their context, unfortunately there is no engma2 API documentation.

 

This gets me the currently selected timer in TimerEdit.py

    def updateState(self):
        cur = self["timerlist"].getCurrent()

How do I get/create the service referene for that timer?

event = None
service = ?????getCurrentService()
if service is not None:
    info = service.info()
    if info is not None:
        event = info.getEvent(0)

So I could call:

short_description = event.getShortDescription()
ext_description = event.getExtendedDescription()


Re: [Timer Overview] Please add full description #19 Qu@rk

  • Senior Member
  • 93 posts

+1
Neutral

Posted 28 December 2019 - 09:39

@Dimitrij

Please, would you like to help me here?

I really would like to check this out.

Thanks.


Edited by Qu@rk, 28 December 2019 - 09:40.


Re: [Timer Overview] Please add full description #20 jort38

  • Senior Member
  • 406 posts

+6
Neutral

Posted 28 December 2019 - 12:18

I just noticed that the timers from the other box in my network _do_ have the long description.....

Xtrend ET10000 (3 TB HD & OpenPli 7), Xtrend ET10000 (1,5 TB HD & OpenPli 7), Xtrend ET10000 (1,5 TB HD & OpenPli 7) and Xtrend ET8000 (1 TB HD & OpenPli 7.2, located in Thailand). All stable releases.





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users