Skip to content

Web canvas saves files in the wrong format if extension is not specified #21933

@silverweed

Description

@silverweed

Check duplicate issues.

  • Checked for duplicates

Description

If you use Save As on a web canvas to save its content to an image, ROOT will only consider the file name to determine the extension, instead of the one selected in the dropdown list on the bottom left (see picture)

Image

In the above case, clicking "Ok" will save the picture in file myfile_with_no_extension as a PostScript image, rather than a png image as expected.

What should happen instead: jsroot should append .png to the file name and save the image as a png (or whatever format I selected)

Reproducer

  • draw something on a web canvas (e.g. a histogram)
  • click Save as
  • change the file name to one without an extension
  • see that the output file is always saved as a PS.

ROOT version

master

Installation method

source

Operating system

linux

Additional context

No response

Metadata

Metadata

Assignees

Type

No type

Projects

Status

No status

Status

No status

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions