I ended up coding 
this: 
https://github.com/brewster76/fuzzy-archer/blob/lang/bin/user/largeimagegenerator.py
 
to achieve the latter asked question. It probably isn't the most pythonic 
way to do things, but it seems to work. Since deepcopy took a tremendous 
amount of time and shallow copying the image configs didn't let me override 
image_height and image_width, I'm going through the configs manually and 
adjusting the sizes.

Tom Keffer schrieb am Donnerstag, 16. Februar 2023 um 14:00:13 UTC+1:

> Unfortunately, no.
>
> On Thu, Feb 16, 2023 at 12:34 AM [email protected] <[email protected]> 
> wrote:
>
>>
>> Another Question, regarding this Topic: is it possible to create two 
>> different sized images with a minimum of duplicated configuration? 
>> Something like this:
>> [ImageGenerator]
>>
>>     #... some configs...
>>
>>     [[day_images]]
>>         
>>         # ...a hell lot of special configs...
>>         
>>         [[[daybarometer]]]
>>             [[[[barometer]]]]
>>             # ...more special configs...
>>             
>>         #...really many, many images with much more special configs
>>     
>>     [[large-day-images]]
>>
>>         image_width = 900
>>         image_height = 600
>>         
>>         #the same as [[day images]] but names 
>> [[large-{whatever_image_from_day_images}]] without having to copy all the 
>> configs
>>         copy_of = day_image, "large-"
>> Tom Keffer schrieb am Mittwoch, 15. Februar 2023 um 20:39:14 UTC+1:
>>
>>> This is the way ConfigObj 
>>> <https://configobj.readthedocs.io/en/latest/configobj.html> works. An 
>>> option is a member of the section above it.
>>>
>>> Also, see the section *Options 
>>> <http://weewx.com/docs/customizing.htm#How_options_work>* in the 
>>> Customizing Guide, in particular the paragraph that starts "Configuration 
>>> files are read..."
>>>
>>> On Wed, Feb 15, 2023 at 10:30 AM [email protected] <
>>> [email protected]> wrote:
>>>
>>>>
>>>> Thanks Tom! So this is something with the way the config works in 
>>>> general or specific to weewx? Do the "attributes" (or however the correct 
>>>> terminus technicus is in this context) always have to appear before the 
>>>> next [[[]]]]-Level?
>>>> Tom Keffer schrieb am Mittwoch, 15. Februar 2023 um 15:59:43 UTC+1:
>>>>
>>>>> Yes, it is possible, but you have the options in the wrong spot. You 
>>>>> want
>>>>>
>>>>>         #will be 700x500
>>>>>         [[[daytempdew]]]
>>>>>           image_width = 700
>>>>>           image_height = 500
>>>>>           [[[[outTemp]]]]
>>>>>           [[[[dewpoint]]]]
>>>>>
>>>>> The dimensions must be under the image name "daytempdew", not the 
>>>>> observation type "dewpoint".
>>>>>
>>>>>
>>>>>
>>>>> On Wed, Feb 15, 2023 at 6:53 AM [email protected] <
>>>>> [email protected]> wrote:
>>>>>
>>>>>> Hi all,
>>>>>>
>>>>>> I wanted to know if it is possible to configure different image sizes 
>>>>>> per image, something like:
>>>>>>
>>>>>> [ImageGenerator]
>>>>>>     image_width = 350
>>>>>>     image_height = 250
>>>>>>     [[day_images]]
>>>>>>         x_label_format = %H:%M
>>>>>>         bottom_label_format = %x %X
>>>>>>         time_length = 97200 # 27 hours
>>>>>>
>>>>>>         #will bee 350x250
>>>>>>         [[[daybarometer]]]
>>>>>>            [[[[barometer]]]]
>>>>>>
>>>>>>         #will be 700x500
>>>>>>         [[[daytempdew]]]
>>>>>>           [[[[outTemp]]]]
>>>>>>           [[[[dewpoint]]]]
>>>>>>           image_width = 700
>>>>>>           image_height = 500
>>>>>>
>>>>>> -- 
>>>>>> You received this message because you are subscribed to the Google 
>>>>>> Groups "weewx-user" group.
>>>>>> To unsubscribe from this group and stop receiving emails from it, 
>>>>>> send an email to [email protected].
>>>>>> To view this discussion on the web visit 
>>>>>> https://groups.google.com/d/msgid/weewx-user/7543d268-18eb-4abc-b405-ae10e5224d72n%40googlegroups.com
>>>>>>  
>>>>>> <https://groups.google.com/d/msgid/weewx-user/7543d268-18eb-4abc-b405-ae10e5224d72n%40googlegroups.com?utm_medium=email&utm_source=footer>
>>>>>> .
>>>>>>
>>>>> -- 
>>>> You received this message because you are subscribed to the Google 
>>>> Groups "weewx-user" group.
>>>> To unsubscribe from this group and stop receiving emails from it, send 
>>>> an email to [email protected].
>>>>
>>> To view this discussion on the web visit 
>>>> https://groups.google.com/d/msgid/weewx-user/d48e00ea-15b5-4361-8916-effe94698b92n%40googlegroups.com
>>>>  
>>>> <https://groups.google.com/d/msgid/weewx-user/d48e00ea-15b5-4361-8916-effe94698b92n%40googlegroups.com?utm_medium=email&utm_source=footer>
>>>> .
>>>>
>>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "weewx-user" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to [email protected].
>>
> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/weewx-user/381c2ec1-ff9d-4aac-8ebe-599a38d063e6n%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/weewx-user/381c2ec1-ff9d-4aac-8ebe-599a38d063e6n%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/bb6e3f6b-3d31-4257-8bd5-f21f32897d8bn%40googlegroups.com.

Reply via email to