Rank: Advanced Member Groups: Registered
Joined: 03/03/2014(UTC) Posts: 418 Was thanked: 125 time(s) in 96 post(s)
|
Davide, I need your help. I just realized that if I use "Open With..." on a new blank image (say png) and edit/save it, the changes are not visible and do not load till its double clicked. If you check the code there is not too much difference between the two, except simple "Open" command also calls base.OnMouseDown() which I cannot call from a menu item, can I). If image region was double clicked prior to using "Open With..." it works OK. Any thoughts how to fix this? Fixed it... I forgot to set imageWasChanged = true in openAs()..Edited by user 13 February 2016 19:01:23(UTC)
| Reason: Not specified
|
1 user thanked Alex M. for this useful post.
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 03/03/2014(UTC) Posts: 418 Was thanked: 125 time(s) in 96 post(s)
|
|
1 user thanked Alex M. for this useful post.
|
|
|
Rank: Advanced Member Groups: Registered, Advanced Member Joined: 13/01/2012(UTC) Posts: 2,648 Location: Italy Was thanked: 1329 time(s) in 875 post(s)
|
Originally Posted by: Alex.M Fixed it... I forgot to set imageWasChanged = true in openAs().. Good Minor thing, not sure about the purpose of these 3 lines of code in the open with MenuButton, seems it works fine even without. Code: canvas.Invalidate();
canvas.PrePainter();
canvas.ReadyToPaint();
|
If you like my plugins consider to support SMath Studio buying a plan; to offer me a coffee: paypal.me/dcprojects |
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 03/03/2014(UTC) Posts: 418 Was thanked: 125 time(s) in 96 post(s)
|
Originally Posted by: mkraska IPE can create pdf and has layers plus uses latex for embedded math stuff. Thus displaying pdf images might be an option. However, I don't know how many users would appreciate that. If I want to have a nice figure, I use IPE generated pdfs (currently just screenshots to transfer them to smath)
Martin could you educate me on the use of IPE? Can you set the .PDF page size? IPE does not seem to read any PDF unfortunately. Otherwise it is a great sketching tool! How come didn't I see it earlier.. It will be super quick to add support for IPE if I could generate a .pdf that IPE can read with pre-set page size (dimensions of the image region) Thanks
|
|
|
|
Rank: Guest
Groups: Registered
Joined: 04/07/2015(UTC) Posts: 6,866 Was thanked: 981 time(s) in 809 post(s)
|
It is pretty impressive what you can achieve with matrix manipulations, Jean. Keep it up!
Wait my friend, you have not seen all what I can do with a shovel and a glass of cognac ! I hope Davide or more collabs will help in rotating by an angle. Yourself: do you have idea to rescue rotate degree ?
Andrey: where are you these days ?
Cheers, Jean
|
1 user thanked Jean Giraud for this useful post.
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 03/03/2014(UTC) Posts: 418 Was thanked: 125 time(s) in 96 post(s)
|
Originally Posted by: Davide Carpi Originally Posted by: Alex.M Fixed it... I forgot to set imageWasChanged = true in openAs().. Good Minor thing, not sure about the purpose of these 3 lines of code in the open with MenuButton, seems it works fine even without. Code: canvas.Invalidate();
canvas.PrePainter();
canvas.ReadyToPaint();
No purpose - was messing around to see what would fix "Open With..." - frankly could use some explaining on what those functions do.
|
|
|
|
Rank: Advanced Member Groups: Registered, Advanced Member Joined: 13/01/2012(UTC) Posts: 2,648 Location: Italy Was thanked: 1329 time(s) in 875 post(s)
|
Originally Posted by: Alex.M frankly could use some explaining on what those functions do. Let's say you want to change the size of the region (f.e. because you wanna keep the scale factor while you rotate the image or after the external editor changes the image size). From the region holder you can call: Code:
// do something that requires a change of the size from inside the region (no resize markers involved)
// ...
this.canv.SetSize(); // this changes the sizes of the canvas from the canvas, if the calculations are made in the canvas;
// alternatively: this.canv.Size = new Size(newWidth, newHeight); // newWidth, newHeight calculated/available in the region holder
this.PrePainter(); // this is needed to change the sizes and the positions of the region elements
this.Invalidate(); // this repaints all
While the canvas' method SetSize() contains: Code:this.Size = new Size(newWidth,newHeight); // newWidth, newHeight calculated/available in the region canvas
If you don't use PrePainter, the math placeholder doesn't fit the new canvas size/position (as well as the selection rectangle and the region canvas itself) Edited by user 14 February 2016 01:31:13(UTC)
| Reason: Not specified |
If you like my plugins consider to support SMath Studio buying a plan; to offer me a coffee: paypal.me/dcprojects |
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 03/03/2014(UTC) Posts: 418 Was thanked: 125 time(s) in 96 post(s)
|
Originally Posted by: Davide Carpi Originally Posted by: Alex.M frankly could use some explaining on what those functions do. Let's say you want to change the size of the region (f.e. because you wanna keep the scale factor while you rotate the image or after the external editor changes the image size). From the region holder you can call: Code:
// do something that requires a change of the size from inside the region (no resize markers involved)
// ...
this.canv.SetSize(); // this changes the sizes of the canvas from the canvas, if the calculations are made in the canvas;
// alternatively: this.canv.Size = new Size(newWidth, newHeight); // newWidth, newHeight calculated/available in the region holder
this.PrePainter(); // this is needed to change the sizes and the positions of the region elements
this.Invalidate(); // this repaints all
While the canvas' method SetSize() contains: Code:this.Size = new Size(newWidth,newHeight); // newWidth, newHeight calculated/available in the region canvas
If you don't use PrePainter, the math placeholder doesn't fit the new canvas size/position (as well as the selection rectangle and the region canvas itself) Thank you for explanation, Davide. As always very informative!
|
1 user thanked Alex M. for this useful post.
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 23/07/2013(UTC) Posts: 1,128 Was thanked: 509 time(s) in 339 post(s)
|
I don't know what is happening but it seems image plugin is ruining the integrity of Smath Studio I am using Nvidia GTX 1070 with 2560x1440 resolution and 125% text on Windows 10 if it will helps. Without Plugin everything seems normal, When I install the plugin the Smath Studio got crazy.
|
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 03/03/2014(UTC) Posts: 418 Was thanked: 125 time(s) in 96 post(s)
|
Originally Posted by: overlord I don't know what is happening but it seems image plugin is ruining the integrity of Smath Studio I am using Nvidia GTX 1070 with 2560x1440 resolution and 125% text on Windows 10 if it will helps.
What is the version of SMath you are using? debugging in WIN10 will be a challenge because I still use WIN7.
|
|
|
|
Rank: Guest
Groups: Registered
Joined: 04/07/2015(UTC) Posts: 6,866 Was thanked: 981 time(s) in 809 post(s)
|
Originally Posted by: overlord 2560x1440 resolution That is not resolution, it is the "pixel display". PC screen have 96 ppi resolution [ppi = pixel per inch]
|
|
|
|
Rank: Guest
Groups: Registered
Joined: 04/07/2015(UTC) Posts: 6,866 Was thanked: 981 time(s) in 809 post(s)
|
Originally Posted by: overlord it seems image plugin is ruining the integrity of Smath Studio If you get the last R,G,B,Yw,Cy,Ma => the image region is OK. This is 6179 on Win 7 ... please report for further insight. Jean Image RGBYCM.sm (293kb) downloaded 46 time(s).
|
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 23/07/2013(UTC) Posts: 1,128 Was thanked: 509 time(s) in 339 post(s)
|
Originally Posted by: Jean Giraud Originally Posted by: overlord 2560x1440 resolution That is not resolution, it is the "pixel display". PC screen have 96 ppi resolution [ppi = pixel per inch] I know you just love to correct people but according to wikipedia your statement is wrong. 2560x1440 is a resoulution and called WQHD. https://en.wikipedia.org/wiki/Graphics_display_resolutionOriginally Posted by: Jean Giraud Originally Posted by: overlord it seems image plugin is ruining the integrity of Smath Studio If you get the last R,G,B,Yw,Cy,Ma => the image region is OK. This is 6179 on Win 7 ... please report for further insight. Jean Image RGBYCM.sm (293kb) downloaded 46 time(s). I have never said image region is not working, it just scrambles the Smath (6179) window with my Windows 10 display settings. You can see that on the screenshot below too. Everything is fine if I remove Image Region. Regards
|
|
|
|
Rank: Guest
Groups: Registered
Joined: 04/07/2015(UTC) Posts: 6,866 Was thanked: 981 time(s) in 809 post(s)
|
"Resolution is the capability of the sensor to observe or measure the smallest object clearly with distinct boundaries ..." fineness ... number of details per unit area ...
The human eye is normalised 1200 ppi. A photo sensor 1" square at 15 MegaPixels is equivalent to human eye. To view the captured details you will have to display on a PC 12.5" x 12.5" ... 1200/96 ~ 12.5
What needs be doctored in your red squares: Smath Win 10 ? your box ? Can't help.
|
|
|
|
Rank: Advanced Member Groups: Registered, Advanced Member Joined: 13/01/2012(UTC) Posts: 2,648 Location: Italy Was thanked: 1329 time(s) in 875 post(s)
|
Issues are are form's fonts changed, desktop background visible through the window and these. I'll see if I can help Alex, as pointed out the issues are related to windows 10 only. |
If you like my plugins consider to support SMath Studio buying a plan; to offer me a coffee: paypal.me/dcprojects |
|
|
|
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.