Oh no, I was right, I AM a stupid fool! I just checked every single possible problem, that could cause this unnormal effect in my real project. Because in fact, in the testfiles, most of the time,...
Type: Posts; User: Mythano
Oh no, I was right, I AM a stupid fool! I just checked every single possible problem, that could cause this unnormal effect in my real project. Because in fact, in the testfiles, most of the time,...
Firsty located under "G:\JavaApplication11\dist" - Java returned: "jar:file:/G:\JavaApplication11/dist/JavaApplication11.jar!/TestCode23.class"
Then located at "G:\asd\JavaApplication11\dist" - Java...
Yes, thanks, now it works.:o But I don't understand why? What was now the problem, or differently asked, how can I apply this success to my real project, where the jar still doesn't work. May it...
You are right, it isn't "TestCode23.jar\testcode23.class", but it is "TestCode23.jar\testcode23\TestCode23.class". So I changed the code to:
public class TestCode23 {
public static void...
Okay. Either I am a stupid fool, or my Java installation is crap. I reprodused exactly the same what you did; please look at the Screenshot, isn't it the same? 3243
But it still returns "null", I...
I don't see what the location of the jar itself can change much, even so I did what you proposed. I actually tested the jar-file now from four different locations, including one form my USB-Device;...
Okay. My InputStream is obviously null in the jar (only in the jar). When I try to catch the path using what Google told me for that:
File jarDir = new...
Yes, of course that, but it is still the same command the programm uses, isn't it? I mean, in NetBeans it works very well, just the jar does not work. And with this.getClass(), shouldn't it search...
But indeed what's strange is, that if I call it in NetBeans after having add this
System.out.println(inputStream);
to the code, so I will get
java.io.BufferedInputStream@6bf7606bBut when I...
Well, it remains the same: "fonts/myFont.ttf" (I've added a screenshot showing it). And in the code it is called by
InputStream inputStream=...
Of course you are right! Now I changed the code to
g.setFont(myFont.deriveFont(18.0f));
Now it works when I run it in NetBeans. But the problem still exists, when I build it and execute it as...
Hello everyone,
I just wanted to change the font-family of a String drawed in the Graphics, and thus included in the contructor of my class:
InputStream inputStream=...