Evangelos Pallis
Forum Replies Created
-
Forum: Plugins
In reply to: [Easy Watermark] Tweak Watermark from Code (sizing and languages)Hey,
I changed the calculation of new width and height for the watermark to override the provided one. Here is a gist with the code i used https://gist.github.com/vpsnak/eacee0aa9b3315c422f99242772bb9f7
The result is that the watermark is downscaled to max_width and max_height (now defined as 25%) of the image applied to.
Here are 2 screenshots of different ratio images with watermark applied using the above sizing
https://prnt.sc/s0wd0r
https://prnt.sc/s0wdbqMy suggestion in my previous message was that you could use apply_filters before the sizing of the watermark to provide developers the ability to add custom sizing like i did above instead of changing the plugin code and having to manually update plugin for every update afterwards.
if you need more info i will be more than happy to help.
Thanks for your timeForum: Plugins
In reply to: [Easy Watermark] Tweak Watermark from Code (sizing and languages)Hello again,
I managed to tweak your plugin to match my sizing needs, by adding max-width and max-height and downscale watermark bases on the image size.
Do you think you could add a filter or a way for developers to register their own size options to fit their needs? I would like to see that in the next update in order to receive new updates and potentially the PRO version.
File Changed: AttachmentProcessorGD.php
function: apply_image_watermark