Changeset 99
- Timestamp:
- 18/03/08 14:06:43 (8 months ago)
- Files:
-
- trunk/README.TXT (modified) (1 diff)
- trunk/src/vlcskineditor/Item.java (modified) (1 diff)
- trunk/src/vlcskineditor/Layout.java (modified) (2 diffs)
- trunk/src/vlcskineditor/Main.java (modified) (17 diffs)
- trunk/src/vlcskineditor/Resource.java (modified) (1 diff)
- trunk/src/vlcskineditor/Skin.java (modified) (2 diffs)
- trunk/src/vlcskineditor/Window.java (modified) (2 diffs)
- trunk/src/vlcskineditor/items/Anchor.java (modified) (1 diff)
- trunk/src/vlcskineditor/items/Button.java (modified) (1 diff)
- trunk/src/vlcskineditor/items/Checkbox.java (modified) (1 diff)
- trunk/src/vlcskineditor/items/Group.java (modified) (2 diffs)
- trunk/src/vlcskineditor/items/Image.java (modified) (1 diff)
- trunk/src/vlcskineditor/items/Panel.java (modified) (2 diffs)
- trunk/src/vlcskineditor/items/Playtree.java (modified) (2 diffs)
- trunk/src/vlcskineditor/items/RadialSlider.java (modified) (3 diffs)
- trunk/src/vlcskineditor/items/Slider.java (modified) (2 diffs)
- trunk/src/vlcskineditor/items/SliderBackground.java (modified) (1 diff)
- trunk/src/vlcskineditor/items/Text.java (modified) (1 diff)
- trunk/src/vlcskineditor/items/Video.java (modified) (1 diff)
- trunk/src/vlcskineditor/resources/Bitmap.java (modified) (3 diffs)
- trunk/src/vlcskineditor/resources/BitmapFont.java (modified) (1 diff)
- trunk/src/vlcskineditor/resources/Font.java (modified) (4 diffs)
- trunk/src/vlcskineditor/resources/SubBitmap.java (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/README.TXT
r90 r99 1 VLC Skin Editor release 0. 6.1b1 VLC Skin Editor release 0.7.0b 2 2 ----------------------------------------------------------- 3 3 Changelog: 4 4 ----------------------------------------------------------- 5 0.7.0 a- Preview can be saved as image5 0.7.0b - Preview can be saved as image 6 6 - Improved SubBitmap editing 7 - Resources/windows/layouts can be duplicated easily 8 - XML output is now indented 9 - Slider backgrounds can be generated in a wizard 7 10 0.6.1b - Critical bufix for the Preview Window 8 11 - Bugfix for slider points parsing and XML parsing trunk/src/vlcskineditor/Item.java
r96 r99 77 77 public abstract void update(); 78 78 /** Creates the XML code representing the item */ 79 public abstract String returnCode( );79 public abstract String returnCode(String indent); 80 80 /** Draws the item to a graphics context */ 81 81 public abstract void draw(Graphics2D g); trunk/src/vlcskineditor/Layout.java
r96 r99 364 364 /** 365 365 * Generates the XML code represented by this Layout. 366 * @param ident Indentation 366 367 * @return The XML code. 367 368 */ 368 public String returnCode( ) {369 String code = "<Layout";370 if ( id!=ID_DEFAULT) code+=" id=\""+id+"\"";369 public String returnCode(String indent) { 370 String code =indent+"<Layout"; 371 if (!id.equals(ID_DEFAULT)) code+=" id=\""+id+"\""; 371 372 code+=" width=\""+String.valueOf(width)+"\" height=\""+String.valueOf(height)+"\""; 372 373 if (minwidth!=MINWIDTH_DEFAULT) code+=" minwidth=\""+String.valueOf(minwidth)+"\""; … … 376 377 code+=">"; 377 378 for (int i=0;i<items.size();i++) { 378 code+="\n"+items.get(i).returnCode( );379 } 380 code+="\n </Layout>";379 code+="\n"+items.get(i).returnCode(indent+Skin.indentation); 380 } 381 code+="\n"+indent+"</Layout>"; 381 382 return code; 382 383 } trunk/src/vlcskineditor/Main.java
r98 r99 47 47 48 48 //The version identification of the current build. 49 public final String VERSION = "0.7.0. a";49 public final String VERSION = "0.7.0.b"; 50 50 //The directory in which the VLC executable is found 51 51 String vlc_dir = ""; … … 1036 1036 if(r.getClass()==Bitmap.class) { 1037 1037 Bitmap b = (Bitmap)r; 1038 Bitmap b2 = new Bitmap(b.returnCode( ),s);1038 Bitmap b2 = new Bitmap(b.returnCode(""),s); 1039 1039 b2.renameForCopy(p); 1040 1040 s.resources.add(b2); … … 1044 1044 else if(r.getClass()==SubBitmap.class) { 1045 1045 SubBitmap sb = (SubBitmap)r; 1046 SubBitmap sb2 = new SubBitmap(sb.returnCode( ),s,sb.getParentBitmap());1046 SubBitmap sb2 = new SubBitmap(sb.returnCode(""),s,sb.getParentBitmap()); 1047 1047 sb2.renameForCopy(p); 1048 1048 sb.getParentBitmap().SubBitmaps.add(sb2); … … 1052 1052 else { 1053 1053 vlcskineditor.resources.Font f = (vlcskineditor.resources.Font)r; 1054 vlcskineditor.resources.Font f2 = new vlcskineditor.resources.Font(f.returnCode( ),s);1054 vlcskineditor.resources.Font f2 = new vlcskineditor.resources.Font(f.returnCode(""),s); 1055 1055 f2.renameForCopy(p); 1056 1056 s.resources.add(f2); … … 1068 1068 Window w = s.getWindow(selected_window); 1069 1069 if(w==null) return; 1070 Window w_ = new Window(w.returnCode( ), s);1070 Window w_ = new Window(w.returnCode(""), s); 1071 1071 w_.renameForCopy(p); 1072 1072 s.windows.add(w_); … … 1076 1076 Window w = s.getWindow(selected_window); 1077 1077 Layout l = w.getLayout(selected_layout); 1078 Layout l_ = new Layout(l.returnCode( ), w, s);1078 Layout l_ = new Layout(l.returnCode(""), w, s); 1079 1079 l_.renameForCopy(p); 1080 1080 w.layouts.add(l_); … … 1092 1092 if(i==null) return; 1093 1093 if(i.getClass()==Anchor.class) { 1094 Anchor a = new Anchor(i.returnCode( ), s);1094 Anchor a = new Anchor(i.returnCode(""), s); 1095 1095 //Because IDs of Anchors are not stored in the XML and can thus not be copied via returnCode() 1096 1096 a.id = i.id; … … 1101 1101 } 1102 1102 else if(i.getClass()==vlcskineditor.items.Button.class) { 1103 vlcskineditor.items.Button b = new vlcskineditor.items.Button(i.returnCode( ), s);1103 vlcskineditor.items.Button b = new vlcskineditor.items.Button(i.returnCode(""), s); 1104 1104 b.renameForCopy(p); 1105 1105 s.getParentListOf(i.id).add(b); … … 1108 1108 } 1109 1109 else if(i.getClass()==vlcskineditor.items.Checkbox.class) { 1110 vlcskineditor.items.Checkbox c = new vlcskineditor.items.Checkbox(i.returnCode( ), s);1110 vlcskineditor.items.Checkbox c = new vlcskineditor.items.Checkbox(i.returnCode(""), s); 1111 1111 c.renameForCopy(p); 1112 1112 s.getParentListOf(i.id).add(c); … … 1115 1115 } 1116 1116 else if(i.getClass()==Group.class) { 1117 Group g = new Group(i.returnCode( ), s);1117 Group g = new Group(i.returnCode(""), s); 1118 1118 g.renameForCopy(p); 1119 1119 s.getParentListOf(i.id).add(g); … … 1122 1122 } 1123 1123 else if(i.getClass()==vlcskineditor.items.Image.class) { 1124 vlcskineditor.items.Image im = new vlcskineditor.items.Image(i.returnCode( ), s);1124 vlcskineditor.items.Image im = new vlcskineditor.items.Image(i.returnCode(""), s); 1125 1125 im.renameForCopy(p); 1126 1126 s.getParentListOf(i.id).add(im); … … 1129 1129 } 1130 1130 else if(i.getClass()==vlcskineditor.items.Panel.class) { 1131 vlcskineditor.items.Panel pa = new vlcskineditor.items.Panel(i.returnCode( ), s);1131 vlcskineditor.items.Panel pa = new vlcskineditor.items.Panel(i.returnCode(""), s); 1132 1132 pa.renameForCopy(p); 1133 1133 s.getParentListOf(i.id).add(pa); … … 1136 1136 } 1137 1137 else if(i.getClass()==Playtree.class) { 1138 Playtree pl = new Playtree(i.returnCode( ), s);1138 Playtree pl = new Playtree(i.returnCode(""), s); 1139 1139 pl.renameForCopy(p); 1140 1140 s.getParentListOf(i.id).add(pl); … … 1143 1143 } 1144 1144 else if(i.getClass()==RadialSlider.class) { 1145 RadialSlider r = new RadialSlider(i.returnCode( ), s);1145 RadialSlider r = new RadialSlider(i.returnCode(""), s); 1146 1146 r.renameForCopy(p); 1147 1147 s.getParentListOf(i.id).add(r); … … 1150 1150 } 1151 1151 else if(i.getClass()==Slider.class) { 1152 Slider sl = new Slider(i.returnCode( ), s);1152 Slider sl = new Slider(i.returnCode(""), s); 1153 1153 sl.renameForCopy(p); 1154 1154 java.util.List<Item> l = s.getParentListOf(i.id); … … 1168 1168 } 1169 1169 else if(i.getClass()==Text.class) { 1170 Text t = new Text(i.returnCode( ), s);1170 Text t = new Text(i.returnCode(""), s); 1171 1171 t.renameForCopy(p); 1172 1172 s.getParentListOf(i.id).add(t); … … 1175 1175 } 1176 1176 else if(i.getClass()==Video.class) { 1177 Video v = new Video(i.returnCode( ), s);1177 Video v = new Video(i.returnCode(""), s); 1178 1178 v.renameForCopy(p); 1179 1179 s.getParentListOf(i.id).add(v); trunk/src/vlcskineditor/Resource.java
r96 r99 43 43 public abstract void update(); 44 44 /** Creates the XML code representing the resource */ 45 public abstract String returnCode( );45 public abstract String returnCode(String indent); 46 46 /** Creates a DefaultMutableTreeNode to be displayed in the resources tree */ 47 47 public abstract DefaultMutableTreeNode getTreeNode(); trunk/src/vlcskineditor/Skin.java
r98 r99 79 79 //Central window handle for all editing dialogs of res/win/layout/items 80 80 public JFrame edit_frame; 81 82 //Default indentation of generated XML code 83 public static String indentation = " "; 81 84 82 85 public Skin(Main m_) { … … 552 555 if(theme_movealpha!=THEME_MOVEALPHA_DEFAULT) code+=" movealpha=\""+String.valueOf(theme_movealpha)+"\""; 553 556 code+=">\n"; 554 code+= "<ThemeInfo";557 code+=Skin.indentation+"<ThemeInfo"; 555 558 code+=" name=\""+themeinfo_name+"\""; 556 559 code+=" author=\""+themeinfo_author+"\""; 557 560 code+=" email=\""+themeinfo_email+"\""; 558 561 code+=" webpage=\""+themeinfo_webpage+"\""; 559 code+="/>\n ";560 code+= "<!-- Created using the VLC Skin Editor "+m.VERSION+" (http://www.videolan.org/vlc/skineditor.php)-->\n";562 code+="/>\n\n"; 563 code+=Skin.indentation+"<!-- Created using the VLC Skin Editor "+m.VERSION+" (http://www.videolan.org/vlc/skineditor.php)-->\n\n"; 561 564 for (int i=0;i<resources.size();i++) { 562 code+=resources.get(i).returnCode( );565 code+=resources.get(i).returnCode(Skin.indentation); 563 566 } 564 567 code+="\n"; 565 568 for (int i=0;i<windows.size();i++) { 566 code+=windows.get(i).returnCode( );569 code+=windows.get(i).returnCode(Skin.indentation); 567 570 } 568 571 code += "\n</Theme>"; trunk/src/vlcskineditor/Window.java
r96 r99 257 257 layouts.add(new Layout(this,s)); 258 258 } 259 public String returnCode( ) {260 String code = "<Window";261 if( id!=ID_DEFAULT) code+=" id=\""+id+"\"";262 if( visible!=VISIBLE_DEFAULT) code+=" visible=\""+String.valueOf(visible)+"\"";259 public String returnCode(String indent) { 260 String code = indent+"<Window"; 261 if(!id.equals(ID_DEFAULT)) code+=" id=\""+id+"\""; 262 if(!visible.equals(VISIBLE_DEFAULT)) code+=" visible=\""+String.valueOf(visible)+"\""; 263 263 if(x!=X_DEFAULT) code+=" x=\""+String.valueOf(x)+"\""; 264 264 if(y!=Y_DEFAULT) code+=" y=\""+String.valueOf(y)+"\""; … … 267 267 code+=">"; 268 268 for (int i=0;i<layouts.size();i++) { 269 code+="\n"+layouts.get(i).returnCode( );270 } 271 code+="\n </Window>\n";269 code+="\n"+layouts.get(i).returnCode(indent+Skin.indentation); 270 } 271 code+="\n"+indent+"</Window>\n"; 272 272 return code; 273 273 } trunk/src/vlcskineditor/items/Anchor.java
r92 r99 270 270 } 271 271 } 272 public String returnCode( ) {273 String code = "<Anchor";272 public String returnCode(String indent) { 273 String code = indent+"<Anchor"; 274 274 if (x!=X_DEFAULT) code+=" x=\""+String.valueOf(x)+"\""; 275 275 if (y!=Y_DEFAULT) code+=" y=\""+String.valueOf(y)+"\""; trunk/src/vlcskineditor/items/Button.java
r92 r99 372 372 if(ae==action_ae) action_tf.setText(ae.getCode()); 373 373 } 374 public String returnCode( ) {375 String code = "<Button";374 public String returnCode(String indent) { 375 String code = indent+"<Button"; 376 376 code+=" up=\""+up+"\""; 377 377 if (!down.equals(DOWN_DEFAULT)) code+=" down=\""+down+"\""; trunk/src/vlcskineditor/items/Checkbox.java
r92 r99 508 508 else if(ae==action2_ae) action2_tf.setText(action2_ae.getCode()); 509 509 } 510 public String returnCode( ) {511 String code = "<Checkbox";510 public String returnCode(String indent) { 511 String code = indent+"<Checkbox"; 512 512 code+=" state=\""+state+"\" up1=\""+up1+"\" up2=\""+up2+"\""; 513 513 if (!down1.equals(ID_DEFAULT)) code+=" down1=\""+down1+"\""; trunk/src/vlcskineditor/items/Group.java
r96 r99 246 246 } 247 247 } 248 public String returnCode( ) {249 String code = "<Group";248 public String returnCode(String indent) { 249 String code = indent+"<Group"; 250 250 if (x!=X_DEFAULT) code+=" x=\""+String.valueOf(x)+"\""; 251 251 if (y!=Y_DEFAULT) code+=" y=\""+String.valueOf(y)+"\""; … … 253 253 //if (id!=ID_DEFAULT) code+="<!-- id=\""+id+"\" -->"; 254 254 for (int i=0;i<items.size();i++) { 255 code+="\n"+items.get(i).returnCode( );256 } 257 code+="\n </Group>";255 code+="\n"+items.get(i).returnCode(indent+Skin.indentation); 256 } 257 code+="\n"+indent+"</Group>"; 258 258 return code; 259 259 } trunk/src/vlcskineditor/items/Image.java
r92 r99 355 355 if(ae==action2_ae) action2_tf.setText(action2_ae.getCode()); 356 356 } 357 public String returnCode( ) {358 String code = "<Image";357 public String returnCode(String indent) { 358 String code = indent+"<Image"; 359 359 if (!id.equals(ID_DEFAULT)) code+=" id=\""+id+"\""; 360 360 if (x!=X_DEFAULT) code+=" x=\""+String.valueOf(x)+"\""; trunk/src/vlcskineditor/items/Panel.java
r96 r99 353 353 } 354 354 } 355 public String returnCode( ) {356 String code = "<Panel";355 public String returnCode(String indent) { 356 String code = indent+"<Panel"; 357 357 if (x!=X_DEFAULT) code+=" x=\""+String.valueOf(x)+"\""; 358 358 if (y!=Y_DEFAULT) code+=" y=\""+String.valueOf(y)+"\""; … … 365 365 if (!id.equals(ID_DEFAULT)) code+="<!-- id=\""+id+"\" -->"; 366 366 for (int i=0;i<items.size();i++) { 367 code+="\n"+items.get(i).returnCode( );368 } 369 code+="\n </Panel>";367 code+="\n"+items.get(i).returnCode(indent+Skin.indentation); 368 } 369 code+="\n"+indent+"</Panel>"; 370 370 return code; 371 371 } trunk/src/vlcskineditor/items/Playtree.java
r96 r99 602 602 } 603 603 } 604 public String returnCode( ) {605 String code = "<Playtree";604 public String returnCode(String indent) { 605 String code = indent+"<Playtree"; 606 606 if (!id.equals(ID_DEFAULT)) code+=" id=\""+id+"\""; 607 607 code+=" font=\""+font+"\""; … … 626 626 if (!visible.equals(VISIBLE_DEFAULT)) code+=" visible=\""+visible+"\""; 627 627 code+=">\n"; 628 code+=slider.returnCode( );629 code+="\n </Playtree>";628 code+=slider.returnCode(indent+Skin.indentation); 629 code+="\n"+indent+"</Playtree>"; 630 630 return code; 631 631 } trunk/src/vlcskineditor/items/RadialSlider.java
r71 r99 25 25 import vlcskineditor.*; 26 26 import java.awt.*; 27 import javax.swing.*;28 27 import javax.swing.tree.*; 29 28 … … 77 76 78 77 } 79 public String returnCode( ) {80 String code = "<RadialSlider";81 if ( id!=ID_DEFAULT) code+=" id=\""+id+"\"";78 public String returnCode(String indent) { 79 String code = indent+"<RadialSlider"; 80 if (!id.equals(ID_DEFAULT)) code+=" id=\""+id+"\""; 82 81 if (x!=X_DEFAULT) code+=" x=\""+String.valueOf(x)+"\""; 83 82 if (y!=Y_DEFAULT) code+=" y=\""+String.valueOf(y)+"\""; … … 85 84 if (minangle!=MINANGLE_DEFAULT) code+=" minangle=\""+String.valueOf(minangle)+"\""; 86 85 if (maxangle!=MAXANGLE_DEFAULT) code+=" maxangle=\""+String.valueOf(maxangle)+"\""; 87 if ( value!=VALUE_DEFAULT) code+=" value=\""+value+"\"";88 if ( tooltiptext!=TOOLTIPTEXT_DEFAULT) code+=" tooltiptext=\""+tooltiptext+"\"";89 if ( lefttop!=LEFTTOP_DEFAULT) code+=" lefttop=\""+lefttop+"\"";90 if ( rightbottom!=RIGHTBOTTOM_DEFAULT) code+=" rightbottom=\""+rightbottom+"\"";86 if (!value.equals(VALUE_DEFAULT)) code+=" value=\""+value+"\""; 87 if (!tooltiptext.equals(TOOLTIPTEXT_DEFAULT)) code+=" tooltiptext=\""+tooltiptext+"\""; 88 if (!lefttop.equals(LEFTTOP_DEFAULT)) code+=" lefttop=\""+lefttop+"\""; 89 if (!rightbottom.equals(RIGHTBOTTOM_DEFAULT)) code+=" rightbottom=\""+rightbottom+"\""; 91 90 if (xkeepratio!=XKEEPRATIO_DEFAULT) code+=" xkeepratio=\""+String.valueOf(xkeepratio)+"\""; 92 91 if (ykeepratio!=YKEEPRATIO_DEFAULT) code+=" ykeepratio=\""+String.valueOf(ykeepratio)+"\""; 93 if ( help!=HELP_DEFAULT) code+=" help=\""+help+"\"";94 if ( visible!=VISIBLE_DEFAULT) code+=" visible=\""+visible+"\"";92 if (!help.equals(HELP_DEFAULT)) code+=" help=\""+help+"\""; 93 if (!visible.equals(VISIBLE_DEFAULT)) code+=" visible=\""+visible+"\""; 95 94 code+="/>"; 96 95 return code; trunk/src/vlcskineditor/items/Slider.java
r96 r99 516 516 sbg_btn.setEnabled(false); 517 517 } 518 public String returnCode( ) {519 String code = "<Slider";518 public String returnCode(String indent) { 519 String code = indent+"<Slider"; 520 520 if (!id.equals(ID_DEFAULT)) code+=" id=\""+id+"\""; 521 521 if (x!=X_DEFAULT) code+=" x=\""+String.valueOf(x)+"\""; … … 538 538 } 539 539 else { 540 code+=">\n"+sbg.returnCode( );541 code+="\n </Slider>";540 code+=">\n"+sbg.returnCode(indent+Skin.indentation); 541 code+="\n"+indent+"</Slider>"; 542 542 } 543 543 return code; trunk/src/vlcskineditor/items/SliderBackground.java
r94 r99 252 252 } 253 253 } 254 public String returnCode( ) {255 String code = "<SliderBackground";254 public String returnCode(String indent) { 255 String code = indent+"<SliderBackground"; 256 256 if (!id.equals(ID_DEFAULT)) code+=" id=\""+id+"\""; 257 257 code+=" image=\""+image+"\""; trunk/src/vlcskineditor/items/Text.java
r92 r99 384 384 } 385 385 } 386 public String returnCode( ) {387 String code = "<Text";386 public String returnCode(String indent) { 387 String code = indent+"<Text"; 388 388 code+=" text=\""+text+"\""; 389 389 code+=" font=\""+font+"\""; trunk/src/vlcskineditor/items/Video.java
r92 r99 327 327 } 328 328 } 329 public String returnCode( ) {330 String code = "<Video";329 public String returnCode(String indent) { 330 String code = indent+"<Video"; 331 331 if (!id.equals(ID_DEFAULT)) code+=" id=\""+id+"\""; 332 332 if (x!=X_DEFAULT) code+=" x=\""+String.valueOf(x)+"\""; trunk/src/vlcskineditor/resources/Bitmap.java
r98 r99 151 151 else if(image.getRGB(x,y)!=alphargb && alpha>0) { 152 152 float amount = alpha; 153 amount = amount/255; 154 System.out.println(alpha +" --> "+amount); 153 amount = amount/255; 155 154 g2d.setColor(new Color((int)(red*amount), (int)(green*amount), (int)(blue*amount))); 156 155 g2d.drawRect(x,y,0,0); … … 353 352 } 354 353 } 355 public String returnCode( ) {356 String code = "<Bitmap id=\""+id+"\" file=\""+file+"\"";354 public String returnCode(String indent) { 355 String code = indent+"<Bitmap id=\""+id+"\" file=\""+file+"\""; 357 356 code+=" alphacolor=\""+alphacolor+"\""; 358 357 if (nbframes!=NBFRAMES_DEFAULT) code+=" nbframes=\""+String.valueOf(nbframes)+"\""; … … 361 360 code+=">\n"; 362 361 for (int i=0;i<SubBitmaps.size();i++) { 363 code+=SubBitmaps.get(i).returnCode( );364 } 365 code+= "</Bitmap>\n";362 code+=SubBitmaps.get(i).returnCode(indent+Skin.indentation); 363 } 364 code+=indent+"</Bitmap>\n"; 366 365 } 367 366 else { trunk/src/vlcskineditor/resources/BitmapFont.java
r71 r99 53 53 54 54 } 55 public String returnCode( ) {56 String code= "<BitmapFont id=\""+id+"\" file=\""+file+"\"";55 public String returnCode(String indent) { 56 String code=indent+"<BitmapFont id=\""+id+"\" file=\""+file+"\""; 57 57 if (type!=TYPE_DEFAULT) code+=" type=\""+type+"\""; 58 58 code+="/>\n"; trunk/src/vlcskineditor/resources/Font.java
r92 r99 25 25 import vlcskineditor.*; 26 26 import vlcskineditor.history.*; 27 import java.util.*;28 27 import javax.swing.*; 29 28 import javax.swing.tree.*; 30 29 import javax.swing.border.*; 31 import javax.imageio.*;32 30 import java.awt.*; 33 31 import java.awt.event.*; … … 251 249 desktop = Desktop.getDesktop(); 252 250 try { 253 desktop.browse(new java.net.URI("http://www.videolan.org/vlc/skin s2-create.html#Font"));251 desktop.browse(new java.net.URI("http://www.videolan.org/vlc/skinedhlp/res-font.html")); 254 252 } 255 253 catch (Exception ex) { … … 258 256 } 259 257 else { 260 JOptionPane.showMessageDialog(null,"Could not launch Browser","Go to the following URL manually:\nhttp://www.videolan.org/vlc/skin s2-create.html",JOptionPane.WARNING_MESSAGE);258 JOptionPane.showMessageDialog(null,"Could not launch Browser","Go to the following URL manually:\nhttp://www.videolan.org/vlc/skinedhlp/res-font.html",JOptionPane.WARNING_MESSAGE); 261 259 } 262 260 } … … 267 265 } 268 266 } 269 public String returnCode( ) {270 String code= "<Font id=\""+id+"\" file=\""+file+"\"";267 public String returnCode(String indent) { 268 String code=indent+"<Font id=\""+id+"\" file=\""+file+"\""; 271 269 if (size!=SIZE_DEFAULT) code+=" size=\""+String.valueOf(size)+"\""; 272 270 code+="/>\n"; trunk/src/vlcskineditor/resources/SubBitmap.java
r92 r99 24 24 25 25 import vlcskineditor.*; 26 import java.util.*;27 26 import javax.swing.*; 28 27 import javax.swing.tree.*; 29 28 import javax.swing.border.*; 30 import javax.imageio.*;31 29 import java.awt.*; 32 30 import java.awt.image.*; 33 31 import java.awt.event.*; 34 import java.io.*;35 32 import vlcskineditor.history.SubBitmapAddEvent; 36 33 /** … … 284 281 desktop = Desktop.getDesktop(); 285 282 try { 286 desktop.browse(new java.net.URI("http://www.videolan.org/vlc/skin s2-create.html#Bitmap"));283 desktop.browse(new java.net.URI("http://www.videolan.org/vlc/skinedhlp/res-subbitmap.html")); 287 284 } 288 285 catch (Exception ex) { … … 291 288 } 292 289 else { 293 JOptionPane.showMessageDialog(null,"Could not launch Browser","Go to the following URL manually:\nhttp://www.videolan.org/vlc/skin s2-create.html",JOptionPane.WARNING_MESSAGE);290 JOptionPane.showMessageDialog(null,"Could not launch Browser","Go to the following URL manually:\nhttp://www.videolan.org/vlc/skinedhlp/res-subbitmap.html",JOptionPane.WARNING_MESSAGE); 294 291 } 295 292 } … … 313 310 sbew = null; 314 311 } 315 public String returnCode( ) {316 String code= "<SubBitmap id=\""+id+"\" x=\""+String.valueOf(x)+"\" y=\""+String.valueOf(y)+"\"";312 public String returnCode(String indent) { 313 String code=indent+"<SubBitmap id=\""+id+"\" x=\""+String.valueOf(x)+"\" y=\""+String.valueOf(y)+"\""; 317 314 code+=" width=\""+String.valueOf(width)+"\" height=\""+String.valueOf(height)+"\""; 318 315 if (nbframes!=NBFRAMES_DEFAULT) code+=" nbframes=\""+String.valueOf(nbframes)+"\"";
