aspose file tools *
The moose likes Other Open Source Projects and the fly likes resize svg image Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Other Open Source Projects
Bookmark "resize svg image" Watch "resize svg image" New topic
Author

resize svg image

mark smith
Ranch Hand

Joined: Apr 05, 2005
Posts: 250
hi

i have a main class and another for the svg:



the svg image is displayed without problem.....


are there a way to resize the svg when we resize the frame?
because when i resize the application, the svg is not resized

thanks
Ulf Dittmer
Rancher

Joined: Mar 22, 2005
Posts: 42952
    
  73
What kind of class is JSVGCanvas? Its documentation should explain how to do this.
mark smith
Ranch Hand

Joined: Apr 05, 2005
Posts: 250
Originally posted by Ulf Dittmer:
What kind of class is JSVGCanvas? Its documentation should explain how to do this.


it's a canvas

i want to display a svg image, i use batk to use it

if my main class extend a jframe and i use a canvas to display the svg image, that work fine

example


now i have a main class who extends jframe, i use a borderLayout on the center i put a panel, on this panel i put a canvas

/*
public class JonoGui extends JFrame{
public JLabel lblTimer;
public JonoGui(){
super("Jono");
setSize(640,480);
lblTimer = new JLabel("test");
JPanel pane = new JPanel();
pane.setLayout(new BorderLayout());
pane.add("West",lblTimer);
setContentPane(pane);
ImgPane imgPane = new ImgPane();
pane.add("Center", imgPane);
}
[/code]

my ImgPane to display the svg image


1. i need to resize the application to see the image
2. i i resize the application, the image is small don't take all the space

you can see the result at
http://www.laboiteaprog.com/java_problem.png

any idea?


thanks
Ulf Dittmer
Rancher

Joined: Mar 22, 2005
Posts: 42952
    
  73
A quick Google search brings up this post, which seems highly relevant. There are several more results that bear checking out.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: resize svg image