View unanswered posts    View active topics

All times are UTC - 6 hours





Post new topic Reply to topic  [ 13 posts ] 
Print view Previous topic   Next topic  
Author Message
Search for:
PostPosted: Fri May 13, 2005 2:54 pm 
Offline
Joined: Fri Jan 21, 2005 9:14 am
Posts: 124
Location: New York
Does anyone know of a simple way to change the Mythweather screen sequence? I'd like to change it to 1) current conditions, 2) today's forecast, 3) extended forecast, 4) weather map (i.e. swapping the order of the middle two screens).

TIA,
Russ


Top
 Profile  
 
 Post subject:
PostPosted: Fri May 13, 2005 5:08 pm 
Offline
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location: Arlington, MA
No easy way. You have to change the MythWeather code and recompile to make those kinds of changes.

Oh, and I agree that the order is screwy, I even filed a bug report over on the MythTv bugzilla to that effect...


Top
 Profile  
 
 Post subject:
PostPosted: Sun May 15, 2005 8:32 am 
Offline
Joined: Fri Jan 21, 2005 9:14 am
Posts: 124
Location: New York
tjc wrote:
Oh, and I agree that the order is screwy, I even filed a bug report over on the MythTv bugzilla to that effect...


...which was disposed as "RESOLVED WONTFIX" :? I'll have a look at the Mythweather code & see if I can't make a patch.


Top
 Profile  
 
 Post subject:
PostPosted: Sun May 15, 2005 11:22 am 
Offline
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location: Arlington, MA
If you're feeling really ambitious you could always make the order configurable... ;-)


Top
 Profile  
 
 Post subject:
PostPosted: Sun May 15, 2005 11:53 am 
Offline
Joined: Fri Jan 21, 2005 9:14 am
Posts: 124
Location: New York
tjc wrote:
If you're feeling really ambitious you could always make the order configurable... ;-)


I can do that - once I figure out how to change the order correctly. :)


Top
 Profile  
 
 Post subject:
PostPosted: Sun May 15, 2005 1:30 pm 
Offline
Joined: Fri Jan 21, 2005 9:14 am
Posts: 124
Location: New York
Okay, one can easily change the Mythweather screen order by editing /usr/share/mythtv/themes/default/weather-ui.xml.

The <context> tag determines the screen order. So to swap the order of the second (extended forecast) and third (today's forecast) screens, simply change every instance of <context>2</context> to <context>3</context> and vice versa.

Or better yet, use this patch file that will do the work for you:

Code:
124c124
<         <context>2</context>
---
>         <context>3</context>
129c129
<         <context>2</context>
---
>         <context>3</context>
134c134
<         <context>3</context>
---
>         <context>2</context>
139c139
<         <context>3</context>
---
>         <context>2</context>
263c263
<         <context>2</context>
---
>         <context>3</context>
269c269
<         <context>2</context>
---
>         <context>3</context>
275c275
<         <context>2</context>
---
>         <context>3</context>
280c280
<         <context>2</context>
---
>         <context>3</context>
285c285
<         <context>2</context>
---
>         <context>3</context>
291c291
<         <context>2</context>
---
>         <context>3</context>
297c297
<         <context>2</context>
---
>         <context>3</context>
303c303
<         <context>2</context>
---
>         <context>3</context>
309c309
<         <context>2</context>
---
>         <context>3</context>
315c315
<         <context>2</context>
---
>         <context>3</context>
320c320
<         <context>2</context>
---
>         <context>3</context>
325c325
<         <context>2</context>
---
>         <context>3</context>
331c331
<         <context>2</context>
---
>         <context>3</context>
337c337
<         <context>2</context>
---
>         <context>3</context>
343c343
<         <context>2</context>
---
>         <context>3</context>
349c349
<         <context>2</context>
---
>         <context>3</context>
355c355
<         <context>2</context>
---
>         <context>3</context>
360c360
<         <context>2</context>
---
>         <context>3</context>
365c365
<         <context>2</context>
---
>         <context>3</context>
371c371
<         <context>2</context>
---
>         <context>3</context>
377c377
<         <context>2</context>
---
>         <context>3</context>
383c383
<         <context>2</context>
---
>         <context>3</context>
389c389
<         <context>2</context>
---
>         <context>3</context>
395c395
<         <context>2</context>
---
>         <context>3</context>
402c402
<         <context>3</context>
---
>         <context>2</context>
408c408
<         <context>3</context>
---
>         <context>2</context>
414c414
<         <context>3</context>
---
>         <context>2</context>
419c419
<         <context>3</context>
---
>         <context>2</context>
426c426
<         <context>3</context>
---
>         <context>2</context>


Cheers,
Russ


Top
 Profile  
 
 Post subject:
PostPosted: Sat Jun 04, 2005 11:30 pm 
Offline
Joined: Thu Mar 31, 2005 6:17 pm
Posts: 70
Ok, I give... how does one use that patch?

I used "pico" on /usr/share/mythtv/themes/default/weather-ui.xml and didn't see anything that looked like that sequence. A lot of content with "context" clauses, but not sure if I can just go manually change all the 2's to 3's, or whatever.

is there a script to do this?


Top
 Profile  
 
 Post subject:
PostPosted: Sun Jun 05, 2005 6:52 am 
Offline
Joined: Fri Jan 21, 2005 9:14 am
Posts: 124
Location: New York
dvanbrunt wrote:
Ok, I give... how does one use that patch?

I used "pico" on /usr/share/mythtv/themes/default/weather-ui.xml and didn't see anything that looked like that sequence. A lot of content with "context" clauses, but not sure if I can just go manually change all the 2's to 3's, or whatever.

is there a script to do this?


Copy the patch shown above into a file named, for example, weather.patch, then cd to /usr/share/mythtv/themes/default, then:

# patch weather-ui.xl weather.patch

For more info on patching:

# man patch


Top
 Profile  
 
 Post subject:
PostPosted: Sun Jun 05, 2005 2:19 pm 
Offline
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location: Arlington, MA
BTW - It's better to use "diff -c" when publishing something intended to be used with "patch" since it makes the results more reliable.


Top
 Profile  
 
 Post subject:
PostPosted: Sun Jun 05, 2005 4:08 pm 
Offline
Joined: Thu Mar 31, 2005 6:17 pm
Posts: 70
tjc wrote:
BTW - It's better to use "diff -c" when publishing something intended to be used with "patch" since it makes the results more reliable.


So, then how does one apply a patch this way?

His insruction to copy into a file and then run patch seemed straightforward enough. Is "diff -c" a patch option? or a separate utility?

Thx!


Top
 Profile  
 
 Post subject:
PostPosted: Sun Jun 05, 2005 4:17 pm 
Offline
Joined: Thu Apr 28, 2005 4:00 pm
Posts: 37
tjc was talking to Russ


Top
 Profile  
 
 Post subject:
PostPosted: Sun Jun 05, 2005 6:48 pm 
Offline
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location: Arlington, MA
Yes, I was. He used diff with no options to generate the patch. That works OK if you have EXACTLY the same file as he started with. If he'd used "diff -c" then the patch utility has more clues which can allow it to work even if there have been non-conflicting changes to the file and will let it better detect when there have been conflicting changes.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jun 06, 2005 6:48 am 
Offline
Joined: Fri Jan 21, 2005 9:14 am
Posts: 124
Location: New York
Duly noted! Thanks for the tip.


Top
 Profile  
 

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 13 posts ] 


All times are UTC - 6 hours




Who is online

Users browsing this forum: No registered users and 18 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group

Theme Created By ceyhansuyu