Closed EpicNet closed 2 years ago
No.3 can already be done with $pic(filename).frames No.5 has been added. No.7 has been added.
@OokEek maybe use styles upon creation for 5 and 7 instead of wasting flags on these?
By the way, yes, could of course try to do it using styles animation
and fixratio
, but also add the ability to disable "0" and enable "1" these styles on the fly, in case their use would be unnecessary in the created control.
Style animation
- to automatic start of a looped animated image in the format "GIF". (There is no animation without this style).
Style fixratio
- to keep the aspect ratio of the image within the size of the control.
Which control method is more convenient (styles or commands), it will be possible to find out only after practical use.
P.S. Please, if possible, after each small set of working changes in the code, do build the file "dcx.dll (beta)" from the source code, so that we can immediately test the update and leave comments in case of errors. Thanks.
I am using "mIRC v7.66" + "DCX dll v3.1-git428" in system "Windows 8.1 x64".
When I used this control, I ran into a lack of presence of a number of functions, which might be helpful. If possible, I would like to receive extended support for working with images in different extensions. Thanks.
My proposals for what needs to be corrected and added in "Image", to make it maximally functional and beautiful:
+a
new flag: "/xdid -x dcx 4 +a 1".+a
new flag: "/xdid -C dcx 4 +a $rgb(255,0,0)".+g
to enable looped frame-by-frame animation in the "GIF" file. For example: "/xdid -i dcx 4 +g file.gif".+u
to display the image by direct link "URL". For example: "/xdid -i dcx 4 +u http://domen/file.gif".+r
to preserve the aspect ratio of the image when set to the specified dimensions of the control. For example: "/xdid -i dcx 4 +r file.gif".P.S. Perhaps I did not take into account something, forgot to mention or lost sight of what else needs to be done, or on the contrary, made a request about something useless, or maybe after that you have new interesting ideas, therefore, in order to avoid misunderstandings expressed in multiple corrections and rewriting of the code - we can always preliminarily think about this update and discuss in detail the innovations in the chat, so that this control becomes versatile enough, functional, maximally customizable and suitable for any design, in a own peculiar style. Thanks.
Here is a test piece of script to reproduce this the problem. To run the script click on "F5" or enter the command "/image_test":