Java-Gaming.org Hi !
Featured games (83)
games approved by the League of Dukes
Games in Showcase (540)
Games in Android Showcase (133)
games submitted by our members
Games in WIP (603)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  JAR weirdness  (Read 3410 times)
0 Members and 1 Guest are viewing this topic.
Offline alexxz4

Junior Devvie


Projects: 1



« Posted 2008-02-12 17:25:53 »

Just wanna ask whats up with java randomly changing file extensions from ".jpg" to ".JPG" and from ".png" to ".PNG". So a few of the images do not show in an applet. Its annoying to have to check every image if its extension was changed.
And whats up with those pointless "Thumbs.db" files that are huge and in every folder inside my JAR.  Huh

PS. unrelated: If my jarsigning certificate expired, what does it mean? I didnt notice any change with my expired-jarsinger-signed applet...

Its not a very big problem thats why i posted it here.

[ Motherload Unlimited looking for programmers ] [ Solitaire ]
Offline kappa
« League of Dukes »

JGO Kernel


Medals: 81
Projects: 15


★★★★★


« Reply #1 - Posted 2008-02-12 17:47:22 »

I believe that its Windows thats at fault here and not java. Windows creates the Thumbs.db files in your folders and applications like paint have a bad habit of saving images with a *.PNG, *.JPG, etc caps case.
Offline Orangy Tang

JGO Kernel


Medals: 56
Projects: 11


Monkey for a head


« Reply #2 - Posted 2008-02-12 17:59:17 »

You can stop windows generating a Thumbs.db (which really annoy me when they get generated in an svn directory and it gets flagged as changed). From an explorer window go Tools->Folder Options. Then the "view" tab and uncheck "do not cache thumbnails".

[ TriangularPixels.com - Play Growth Spurt, Rescue Squad and Snowman Village ] [ Rebirth - game resource library ]
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline alexxz4

Junior Devvie


Projects: 1



« Reply #3 - Posted 2008-02-12 18:11:13 »

u mean check it? cause it was unchecked.
Well i checked it and it still puts Thumbs.db in the folders... Do i need to restart my computer for it to work?

>I believe that its Windows thats at fault here and not java. Windows creates the Thumbs.db files in your folders and applications like paint have a bad habit of saving images with a *.PNG, *.JPG, etc caps case.

So u mean there is no way to prevent that? Maybe its my way of JARing. I use command line batch file to jar all the stuff cause my IDE's jar-er totally sux.

[ Motherload Unlimited looking for programmers ] [ Solitaire ]
Offline Orangy Tang

JGO Kernel


Medals: 56
Projects: 11


Monkey for a head


« Reply #4 - Posted 2008-02-12 18:19:58 »

Oops, yeah you need to check it. And it won't clean up any existing Thumbs.db files, so you'll have to go and delete them manually afterwards.

[ TriangularPixels.com - Play Growth Spurt, Rescue Squad and Snowman Village ] [ Rebirth - game resource library ]
Offline alexxz4

Junior Devvie


Projects: 1



« Reply #5 - Posted 2008-02-12 18:33:34 »

well, i checked it, then created a new jar file and it still puts those things in folders...
Anyways, its not a big problem, i only have to delete 5 of .db files every time. So is there a way to prevent windows from modifying file extensions?

[ Motherload Unlimited looking for programmers ] [ Solitaire ]
Offline oNyx

JGO Coder


Medals: 2


pixels! :x


« Reply #6 - Posted 2008-02-12 18:58:39 »

Windows itself doesn't change file extensions. However, MSPaint likes to use uppercase file extensions (because that interferes with case sensitive file systems Wink). Always use lowercase file extensions.

I don't have any issues with thumbs.db because I use the detail view for all directories. If I want thumbnails I just click on one of the images (opens with irfanview) and then I only need to press T.

弾幕 ☆ @mahonnaiseblog
Offline alexxz4

Junior Devvie


Projects: 1



« Reply #7 - Posted 2008-02-12 19:40:32 »

Once images get jarred they start changing their extensions. Their just fine outsida jar.
I have images made in paint and in a high-tech graphics program change extensions. So it gotta be something else. I just cant see any patterns in it...

[ Motherload Unlimited looking for programmers ] [ Solitaire ]
Offline Abuse

JGO Knight


Medals: 15


falling into the abyss of reality


« Reply #8 - Posted 2008-02-12 20:03:23 »

Once images get jarred they start changing their extensions. Their just fine outsida jar.
I have images made in paint and in a high-tech graphics program change extensions. So it gotta be something else. I just cant see any patterns in it...

Jars are case sensitive, the windows file system is not.

You do have "Hide extensions for known file types" disabled, don't you? (explorer->tools->folder options->view)

Make Elite IV:Dangerous happen! Pledge your backing at KICKSTARTER here! https://dl.dropbox.com/u/54785909/EliteIVsmaller.png
Offline alexxz4

Junior Devvie


Projects: 1



« Reply #9 - Posted 2008-02-12 20:23:20 »

Quote
You do have "Hide extensions for known file types" disabled, don't you? (explorer->tools->folder options->view)
Well, i unchecked it and all it did is it added .exe to executables, .txt to text files, etc. It didnt affect JAR extensions whatsoever...

[ Motherload Unlimited looking for programmers ] [ Solitaire ]
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline Abuse

JGO Knight


Medals: 15


falling into the abyss of reality


« Reply #10 - Posted 2008-02-12 21:10:12 »

Well, i unchecked it and all it did is it added .exe to executables, .txt to text files, etc. It didnt affect JAR extensions whatsoever...

I was more thinking that you had the extensions for .png/.jpg hidden,
so through explorer you couldn't tell whether they were lower/upper case.

The result being that only when they were jarred would:
a) the case of the extension become visible, and
b) a (negative) effect seen at runtime.

Make Elite IV:Dangerous happen! Pledge your backing at KICKSTARTER here! https://dl.dropbox.com/u/54785909/EliteIVsmaller.png
Offline alexxz4

Junior Devvie


Projects: 1



« Reply #11 - Posted 2008-02-12 21:22:28 »

well i guess thats the problem... any solution?

[ Motherload Unlimited looking for programmers ] [ Solitaire ]
Offline oNyx

JGO Coder


Medals: 2


pixels! :x


« Reply #12 - Posted 2008-02-12 21:44:13 »

As I already said... always use lowercase file extensions.

弾幕 ☆ @mahonnaiseblog
Offline alexxz4

Junior Devvie


Projects: 1



« Reply #13 - Posted 2008-02-12 22:06:56 »

Oh i get it now. When i changed all the extensions manually from .PNG to .png and .JPG to .jpg it kept them to lowercase in the jar file. Stupid windows (of course Mac is an utter suicide so im not complaining).  Grin

[ Motherload Unlimited looking for programmers ] [ Solitaire ]
Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

Mr.CodeIt (24 views)
2014-12-23 03:34:11

rwatson462 (53 views)
2014-12-15 09:26:44

Mr.CodeIt (45 views)
2014-12-14 19:50:38

BurntPizza (85 views)
2014-12-09 22:41:13

BurntPizza (110 views)
2014-12-08 04:46:31

JscottyBieshaar (79 views)
2014-12-05 12:39:02

SHC (89 views)
2014-12-03 16:27:13

CopyableCougar4 (96 views)
2014-11-29 21:32:03

toopeicgaming1999 (155 views)
2014-11-26 15:22:04

toopeicgaming1999 (152 views)
2014-11-26 15:20:36
Resources for WIP games
by kpars
2014-12-18 10:26:14

Understanding relations between setOrigin, setScale and setPosition in libGdx
by mbabuskov
2014-10-09 22:35:00

Definite guide to supporting multiple device resolutions on Android (2014)
by mbabuskov
2014-10-02 22:36:02

List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!