Cantor-SAGE: Display image
Uwe Fechner
u.fechner at tudelft.nl
Fri Jun 10 00:14:04 CEST 2011
Hello Alexander,
you wrote:
> I don't really like the idea, as I can see it lead to very unexpected
> behaviour, for example if you start cantor from your home,
> and are downloading some files at the same time. Every image you save
> while cantor is running popping up in your worksheet
> is not something an average user(or anybody else) would expect.
I think, that Cantor should work in the same way, that the web-gui of
sage works.
I don't no exactly, how it works, but I think, that the problem, that
you mention could be limited in the following ways:
1. Start to look for new images, when you evaluate a new command entry, and
stop looking for new images e.g. 100 ms after the evaluation of a
new command entry.
2. If that should not be sufficient, adding a new option in the
configuration dialog ("look for new images in the current
directory") might be an option.
Regards:
Uwe
On 09.06.2011 21:16, Alexander Rieder wrote:
> Hi,
>
> On Wed, Jun 8, 2011 at 8:29 PM, Uwe Fechner <u.fechner at tudelft.nl> wrote:
>> Hello,
>>
>> my current idea:
>> Modify Cantor in such a way, that it also monitors the "current
>> directory" for new graphic
>> files, and displays them.
>>
> I don't really like the idea, as I can see it lead to very unexpected
> behaviour, for example if you start cantor from your home,
> and are downloading some files at the same time. Every image you save
> while cantor is running popping up in your worksheet
> is not something an average user(or anybody else) would expect.
>
> I basically see three possibilities to fix your problem:
> - add a new type of worksheet entry that lets you insert any image
> files you want/modify the Richtext Entry
> - add some regexp magic that detects if the command you run is saving
> an image, and insert it as a result to that command (possibly hard to
> get right)
> - add a custom command e.g. cantor_display("imagefile"), that adds the
> image as a result
>
>> But then I have some more questions:
>> - what is the best graphic format for the integration in Cantor documents?
> I don't think there is a "best" image format. Cantor suports every
> image format supported by your Qt install. From a personal experience
> png works everywhere, and is better suited for plots than jpeg.
> Additionally Cantor supports to display Vector graphics in .eps
> format. If it is supported by the backend to generate it, I
> personally like that solution most, as it will allow arbitrary
> resizing, and works well together with LaTeX.
>
>> - should pictures be re-sized? If yes, which is the best resolution?
> I don't know about resizing. Cantor inserts the images in their
> original size, so just use whatever looks good.
>
> best regards,
> Alexander Rieder
> _______________________________________________
> kde-edu mailing list
> kde-edu at mail.kde.org
> https://mail.kde.org/mailman/listinfo/kde-edu
--
----------------------------------------
Uwe Fechner, M.Sc.
Delft University of Technology
Faculty of Aerospace Engineering/ASSET
Kluyverweg 1,
2629 HS Delft, The Netherlands
Phone: +31-15-27-88902
More information about the kde-edu
mailing list