[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [sc-dev] request for comments and/or committing : GUI references in standard libraries

p.s. attached are the updated but not yet released class files required to test the new methods with SwingOSC. For example, you should be able to switch:

	{ SinOsc.ar( 441 )}.plot;
	{ SinOsc.ar( 441 )}.plot;

etc. Note that JSCSoundFileView obviously doesn't work as the java class is not yet in v0.43. everything else should work.

ciao, -sciss-

Am 06.12.2006 um 16:08 schrieb Sciss:


i have modified the classes in the standard lib referring to GUI objects in a way to use the GUI class instead of direct calls to cocoa GUI objects. i have tested all methods, but it would be cool if anyone can independantly verify there are no errors. for cocoa GUI, there should be no visible changes whatsoever (apart from the 'resizable = false' i added to Server->makeWindow and the corrected window height in SynthDescPlusGUI.sc). for SwingOSC, some stuff doesn't work with v0.43 because I have decided to add a few helper methods in (J)Stethoscope and (J)Font such as to provide better interoperability between the two GUI kits:

- In (J)Stethoscope, *defaultServer tells you on which server this scope should be used, and *isValidServer checks any server for usability with that scope. For example, isValidServer ( Server.internal ) will return true on cocoa and false on SwingOSC, while for isValidServer( Server.local ) will be just the opposite results.

- In (J)Font, *defaultSansFace, *defaultSerifFace, *defaultMonoFace will return the default font names that should be used for the particular use. The instance method 'boldVariant' returns a new font with same face and size as the current font, but as a bold variant.

I'd be happy to hear if you are happy with making these changes. Please drop me note if when commited, because i would have to put an updated SwingOSC online as well.

ciao, -sciss-

Attachment: updatedSwing.zip
Description: Zip archive