Skip to content

Commit

Permalink
Release last version of the demo
Browse files Browse the repository at this point in the history
  • Loading branch information
vincenzopalazzo committed Dec 24, 2019
1 parent eadff70 commit 209c077
Show file tree
Hide file tree
Showing 39 changed files with 1,163 additions and 1,080 deletions.
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,8 @@ If you are a java programmer you will surely have studied this project, now I'm
The look and feel I'm working on is the following
https://github.com/vincenzopalazzo/material-ui-swing
https://github.com/atarw/material-ui-swing

## Build information.

Is used the gradle build system, for compiling the source add the path of the library inside the file **build.gradle**.
You can find the last version of the library material-ui-swing [here](https://github.com/vincenzopalazzo/material-ui-swing/releases) or you can use [online repository](https://search.maven.org/search?q=g:%22io.github.vincenzopalazzo%22%20AND%20a:%22material-ui-swing%22)
Binary file modified set_swing/.gradle/3.4.1/fileContent/annotation-processors.bin
Binary file not shown.
Binary file modified set_swing/.gradle/3.4.1/fileContent/fileContent.lock
Binary file not shown.
Binary file modified set_swing/.gradle/3.4.1/taskHistory/fileHashes.bin
Binary file not shown.
Binary file modified set_swing/.gradle/3.4.1/taskHistory/fileSnapshots.bin
Binary file not shown.
Binary file modified set_swing/.gradle/3.4.1/taskHistory/jvmClassSignatures.bin
Binary file not shown.
Binary file modified set_swing/.gradle/3.4.1/taskHistory/taskHistory.bin
Binary file not shown.
Binary file modified set_swing/.gradle/3.4.1/taskHistory/taskHistory.lock
Binary file not shown.
Binary file added set_swing/.gradle/5.0/fileChanges/last-build.bin
Binary file not shown.
Binary file added set_swing/.gradle/5.0/fileContent/fileContent.lock
Binary file not shown.
Binary file added set_swing/.gradle/5.0/fileHashes/fileHashes.bin
Binary file not shown.
Binary file added set_swing/.gradle/5.0/fileHashes/fileHashes.lock
Binary file not shown.
Binary file not shown.
File renamed without changes.
Binary file not shown.
Binary file added set_swing/.gradle/5.0/javaCompile/jarAnalysis.bin
Binary file not shown.
Binary file added set_swing/.gradle/5.0/javaCompile/javaCompile.lock
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added set_swing/.gradle/5.0/taskHistory/taskHistory.lock
Binary file not shown.
Binary file not shown.
4 changes: 2 additions & 2 deletions set_swing/.gradle/buildOutputCleanup/cache.properties
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
#Sat Apr 06 22:23:47 CEST 2019
gradle.version=3.4.1
#Wed Jun 19 12:34:03 CEST 2019
gradle.version=5.0
1 change: 0 additions & 1 deletion set_swing/.gradle/buildOutputCleanup/cache.properties.lock

This file was deleted.

Binary file not shown.
Empty file.
32 changes: 5 additions & 27 deletions set_swing/build.gradle
Original file line number Diff line number Diff line change
@@ -1,53 +1,30 @@
/*
* This build file was generated by the Gradle 'init' task.
*
* This generated file contains a sample Java project to get you started.
* For more details take a look at the Java Quickstart chapter in the Gradle
* user guide available at https://docs.gradle.org/3.4.1/userguide/tutorial_java_projects.html
*/

// Apply the java plugin to add support for Java
apply plugin: 'java'

// Apply the application plugin to add support for building an application
apply plugin: 'application'

// In this section you declare where to find the dependencies of your project
repositories {
// Use jcenter for resolving your dependencies.
// You can declare any Maven/Ivy/file repository here.
jcenter()
flatDir {
dirs '../set_swing/libs/'
dirs '/home/vincenzo/Github/material-ui-swing/build/libs'
}

}

dependencies {

//implementation 'com.github.vincenzopalazzo:material-ui-swing:V9.9'
//implementation 'io.github.vincenzopalazzo:material-ui-swing:1.0-Beta-1.4.2'


compile(name: 'iconloader', ext: 'jar')
compile(name: 'material-ui-swing-0.9.9', ext: 'jar')
//compile(name: 'material-ui-swing-0.9.3.3', ext: 'jar')
compile(name: 'material-ui-swing-1.1.1_beta', ext: 'jar')
compile(name: 'darcula', ext: 'jar')
compile(name: 'AnimatedTransitions', ext: 'jar')
compile(name: 'AppFramework', ext: 'jar')
compile(name: 'filters-2.0.235', ext: 'jar')
compile(name: 'swing-worker-1.1', ext: 'jar')
compile(name: 'swingx-1.6.1', ext: 'jar')

// Use JUnit test framework
testCompile 'junit:junit:4.12'
}

allprojects {
repositories {
maven { url 'https://jitpack.io' }
}
}


jar {
manifest {
attributes("Class-Path": configurations.compile.collect { it.getName() }.join(','))
Expand All @@ -63,6 +40,7 @@ sourceSets {
integTest {
compileClasspath += files('src/main/java/')
runtimeClasspath += output + compileClasspath + files('src/main/resources/')
//runtimeClasspath += files('src/main/java/') this resolved the problem soruces file?? try this
}
}

Expand Down
2 changes: 1 addition & 1 deletion set_swing/gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-3.4.1-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-5.0-all.zip
Binary file removed set_swing/libs/material-ui-swing-0.9.9.jar
Binary file not shown.
Binary file not shown.
114 changes: 58 additions & 56 deletions set_swing/src/main/java/ColorChooserDemo.java
Original file line number Diff line number Diff line change
Expand Up @@ -91,32 +91,32 @@ public ColorChooserDemo(SwingSet2 swingset) {

ActionListener l = new ActionListener() {
public void actionPerformed(ActionEvent e) {
Color current = bezAnim.getOuterColor();

if(e.getSource() == backgroundColorButton) {
current = bezAnim.getBackgroundColor();
} else if(e.getSource() == gradientAButton) {
current = bezAnim.getGradientColorA();
} else if(e.getSource() == gradientBButton) {
current = bezAnim.getGradientColorB();
}

// Bring up a color chooser
Color c = JColorChooser.showDialog(
getDemoPanel(),
getString("ColorChooserDemo.chooser_title"),
current
);

if(e.getSource() == outerColorButton) {
bezAnim.setOuterColor(c);
} else if(e.getSource() == backgroundColorButton) {
bezAnim.setBackgroundColor(c);
} else if(e.getSource() == gradientAButton) {
bezAnim.setGradientColorA(c);
} else {
bezAnim.setGradientColorB(c);
}
Color current = bezAnim.getOuterColor();

if(e.getSource() == backgroundColorButton) {
current = bezAnim.getBackgroundColor();
} else if(e.getSource() == gradientAButton) {
current = bezAnim.getGradientColorA();
} else if(e.getSource() == gradientBButton) {
current = bezAnim.getGradientColorB();
}

// Bring up a color chooser
Color c = JColorChooser.showDialog(
getDemoPanel(),
getString("ColorChooserDemo.chooser_title"),
current
);

if(e.getSource() == outerColorButton) {
bezAnim.setOuterColor(c);
} else if(e.getSource() == backgroundColorButton) {
bezAnim.setBackgroundColor(c);
} else if(e.getSource() == gradientAButton) {
bezAnim.setGradientColorA(c);
} else {
bezAnim.setGradientColorB(c);
}
}
};

Expand Down Expand Up @@ -152,36 +152,38 @@ public void actionPerformed(ActionEvent e) {
}

class ColorSwatch implements Icon {
String gradient;
BezierAnimationPanel bez;

public ColorSwatch(String g, BezierAnimationPanel b) {
bez = b;
gradient = g;
}

public int getIconWidth() {
return 11;
}

public int getIconHeight() {
return 11;
}

public void paintIcon(Component c, Graphics g, int x, int y) {
g.setColor(Color.black);
g.fillRect(x, y, getIconWidth(), getIconHeight());
if(gradient.equals("GradientA")) {
g.setColor(bez.getGradientColorA());
} else if(gradient.equals("GradientB")) {
g.setColor(bez.getGradientColorB());
} else if(gradient.equals("Background")) {
g.setColor(bez.getBackgroundColor());
} else if(gradient.equals("OuterLine")) {
g.setColor(bez.getOuterColor());
}
g.fillRect(x+2, y+2, getIconWidth()-4, getIconHeight()-4);
}

String gradient;
BezierAnimationPanel bez;

public ColorSwatch(String g, BezierAnimationPanel b) {
bez = b;
gradient = g;
}

public int getIconWidth() {
return 11;
}

public int getIconHeight() {
return 11;
}

public void paintIcon(Component c, Graphics g, int x, int y) {
g.setColor(Color.black);
g.fillRect(x, y, getIconWidth(), getIconHeight());
if(gradient.equals("GradientA")) {
g.setColor(bez.getGradientColorA());
} else if(gradient.equals("GradientB")) {
g.setColor(bez.getGradientColorB());
} else if(gradient.equals("Background")) {
g.setColor(bez.getBackgroundColor());
} else if(gradient.equals("OuterLine")) {
g.setColor(bez.getOuterColor());
}
g.fillRect(x+2, y+2, getIconWidth()-4, getIconHeight()-4);
}

}

}
Loading

0 comments on commit 209c077

Please sign in to comment.