Attend XDA's Second Annual Developer Conference, XDA:DevCon 2014!
5,768,353 Members 47,467 Now Online
XDA Developers Android and Mobile Development Forum

Updated:03-15-12-Better Draw9patch Program FOUND!

Tip us?
 
AndroidGraphix
Old
(Last edited by AndroidGraphix; 16th March 2012 at 05:41 AM.)
#1  
AndroidGraphix's Avatar
Senior Member - OP
Thanks Meter 374
Posts: 1,229
Join Date: Apr 2011
Location: Paradise Valley, AZ

 
DONATE TO ME
Default Updated:03-15-12-Better Draw9patch Program FOUND!

UPDATED 03-15-12:

Elex_kr has introduced a NEW DRAW9PATCH Program. Please scroll down through the post to view his work. AND DONATE. This DEV deserves a lot of credit for bringing a new improved program to the rooted community. I can attest that his program is very easy to use and extremely fast. We're working on new ways to improve the program. Please post your comments and suggestions to Elex_kr below.


03-15-12-Direct link to his latest Better 9-patch Tool

Here's quick video of what Elex_kr's Better 9-Patch Tool





Original Post:

I'm putting this thread together because it's been too long that draw9patch has been in place without any updates or improvements since its release. I'm also posting this because I'm sure there's a dev willing to redesign draw9patch and make it easier to use. Here's a quick video of why we need an improved draw9patch program.




The main issue for many themers is how time consuming it can be to fill in only ONE pixel at a time. I've been using draw9patch for almost a year and it consumes a large portion of my day. The IDEAL draw9patch would be able to select multiple pixels at the same time. For example, selecting one end of the png and holding down (Shift) while selecting the end point where the pixels would automatically fill in. I'm open to suggestions or comments. Please keep this professional.

Donation: I'm willing to give any DEV $100 for a newly improved draw9patch program. Conditions as follows:
1) Must be based off the original draw9patch
2) Must have the improvements stated above, allowing for multiple pixels to be selected based on holding (CTRL, SHIFT or ALT)
3) Must have the ability to save the PNG as a .9.png.
4) Must be compatible with Windows 7.


*-*-*
Just to give the dev an idea of how long draw9patch can take. Today I used the program to stretch 59 .9.png's. It took an average of 2 1/2 minutes per 9.png. That's 2 hours and 26 minutes of solid time spent using draw9patch. I could have done these in probably 35 minutes tops if the program was more user friendly and had the above stated actions.


Attention moderator(s). If this video can be embedded, please correct it.
The Following 10 Users Say Thank You to AndroidGraphix For This Useful Post: [ Click to Expand ]
 
Diamondback
Old
#2  
Diamondback's Avatar
Developer Committee / Senior Moderator / Recognized Developer
Thanks Meter 6316
Posts: 4,370
Join Date: Jan 2010
Well as I am fairly new to the .9 drawing itself, can you please explain the general idea and workflow?
I know that those lines and pixels are used to determine what in the image is stretchable and what not.

And I have another question:
You say that the new too lneeds to be based on the old one... What do you mean exactly with that sentence?

Is there any special kind of problem doing these .9 files? Or is it just drawing the lines and then saving the file as a normal png?

Contact the Developer Committee with any questions or concerns regarding
the Recognized Developer program.
Mention my name with @Diamondback in any post to easily get my attention.
Please use BB Codes to format your posts.
 
AndroidGraphix
Old
(Last edited by AndroidGraphix; 13th November 2011 at 11:40 PM.)
#3  
AndroidGraphix's Avatar
Senior Member - OP
Thanks Meter 374
Posts: 1,229
Join Date: Apr 2011
Location: Paradise Valley, AZ

 
DONATE TO ME
Quote:
Originally Posted by Diamondback2010 View Post
Well as I am fairly new to the .9 drawing itself, can you please explain the general idea and workflow?
I know that those lines and pixels are used to determine what in the image is stretchable and what not.

And I have another question:
You say that the new too lneeds to be based on the old one... What do you mean exactly with that sentence?

Is there any special kind of problem doing these .9 files? Or is it just drawing the lines and then saving the file as a normal png?
Thanks for dropping in Diamondback! Draw9patch places a one pixel border around the PNG. The border is used to place black pixels in areas the png will stretch.

My workflow consist of making the png from scratch in CS5 (Adobe Photoshop) then saving the image as a png. That PNG is then places into draw9patch for editing. I place the pixels around the border as needed then save the work in draw9patch. Draw9patch automatically saves the png as a .9.png.

The .9.png is in it's raw decompiled format. Which means, the pixels are still visible. The only way to hide the outer border is to place the .9.png into either Eclipse (Instructions found here on my thread:

http://forum.xda-developers.com/show....php?t=1140034

Or XUltimate draw9patch compiler(reference: xeudoxus). Website:

http://www.droidforums.net/forum/xeu...xultimate.html

Both of the programs will compile the .9.png which then can be used in any apk. XUltimate's being the quickest and easiest to use by far.

What the new draw9patch needs:

"The new Tool needs to be based on the old on." Really, I just need to be able to see how the png will look when my pixels on the border are added. When you drop a png into draw9patch, you'll know what I'm talking about. Aside from that, it's basic functions would be nice. Such as,

1) Show lock
2) Show Patches
3) Show content
4) Zoom
5) The drop and drag png's into the program
6) MOST IMPORTANTLY a faster way to draw the pixel border around the png. An example of this would be to hold shift down and select the beginning point and end point of where a pixel line should be place.

If it could compile itself upon saving, that would be another great feature to add.

There's really no kind of problem with doing .9.png's other than the draw9patch program we are forced to use is a dinosaur and lacks efficiency. Hundred's of Devs and themers use draw9patch on a daily basis. This product alone would be valuable to anyone needing a more efficient tool. With that said, I'm sure themers like myself would gladly pay to use a more efficient program.
 
Diamondback
Old
(Last edited by Diamondback; 14th November 2011 at 12:24 AM.)
#4  
Diamondback's Avatar
Developer Committee / Senior Moderator / Recognized Developer
Thanks Meter 6316
Posts: 4,370
Join Date: Jan 2010
Quote:
Originally Posted by raider3bravo View Post
Thanks for dropping in Diamondback! Draw9patch places a one pixel border around the PNG. The border is used to place black pixels in areas the png will stretch.

My workflow consist of making the png from scratch in CS5 (Adobe Photoshop) then saving the image as a png. That PNG is then places into draw9patch for editing. I place the pixels around the border as needed then save the work in draw9patch. Draw9patch automatically saves the png as a .9.png.

The .9.png is in it's raw decompiled format. Which means, the pixels are still visible. The only way to hide the outer border is to place the .9.png into either Eclipse (Instructions found here on my thread:

http://forum.xda-developers.com/show....php?t=1140034

Or XUltimate draw9patch compiler(reference: xeudoxus). Website:

http://www.droidforums.net/forum/xeu...xultimate.html

Both of the programs will compile the .9.png which then can be used in any apk. XUltimate's being the quickest and easiest to use by far.

What the new draw9patch needs:

"The new Tool needs to be based on the old on." Really, I just need to be able to see how the png will look when my pixels on the border are added. When you drop a png into draw9patch, you'll know what I'm talking about. Aside from that, it's basic functions would be nice. Such as,

1) Show lock
2) Show Patches
3) Show content
4) Zoom
5) The drop and drag png's into the program
6) MOST IMPORTANTLY a faster way to draw the pixel border around the png. An example of this would be to hold shift down and select the beginning point and end point of where a pixel line should be place.

If it could compile itself upon saving, that would be another great feature to add.

There's really no kind of problem with doing .9.png's other than the draw9patch program we are forced to use is a dinosaur and lacks efficiency. Hundred's of Devs and themers use draw9patch on a daily basis. This product alone would be valuable to anyone needing a more efficient tool. With that said, I'm sure themers like myself would gladly pay to use a more efficient program.
Hm, okay so the only real "work" is drawing lines around the image, okay.

I wonder if those lines are really needed? Does the final (compiled) image somehow has those lines too?
Or are the lines only an easy way to tell the compiler what to do?

Would it be possible choose another way of "marking" those areas instead of lines if we create a different compiler?

What about the sources of the compilers? Are they opensource?

Edit: Actually the biggest problem would be the preview... But I see that this is the most important part too

Contact the Developer Committee with any questions or concerns regarding
the Recognized Developer program.
Mention my name with @Diamondback in any post to easily get my attention.
Please use BB Codes to format your posts.
 
AndroidGraphix
Old
#5  
AndroidGraphix's Avatar
Senior Member - OP
Thanks Meter 374
Posts: 1,229
Join Date: Apr 2011
Location: Paradise Valley, AZ

 
DONATE TO ME
Quote:
Originally Posted by Diamondback2010 View Post
Hm, okay so the only real "work" is drawing lines around the image, okay.

I wonder if those lines are really needed? Does the final (compiled) image somehow has those lines too?
Or are the lines only an easy way to tell the compiler what to do?

Would it be possible choose another way of "marking" those areas instead of lines if we create a different compiler?

What about the sources of the compilers? Are they opensource?

Edit: Actually the biggest problem would be the preview... But I see that this is the most important part too
The lines are exactly what you say. They aid in telling the compiler which way to stretch the png. Sometimes if you have complex png's like I do, you have to be very specific on where you place the pixels. The same problem remains though, the bottom pixels and the right pixels take the longest.

If the compiler was modified to to automatically place these borders in a specific place each time, it would lead to png's that may not look as intended. For example:



The screen shot on the left shows several of my buttons. Look specifically at the button with the words "Set" & "Cancel". These buttons require very specific pixel alignment on the bottom of the png which tells where to place the text. If it were on the entire bottom portion of the button it may lead to text running over parts of my graphic where I didn't intend it.

I'm not sure if the compilers are opensource. I would talk to the dev that made XUltimate.

**Adding the ability to select multiple pixels at the same time with the current program in place is the ideal solution.
 
zelendel
Old
#6  
zelendel's Avatar
Moderator Committee - The Dark Knight
Thanks Meter 10938
Posts: 14,322
Join Date: Aug 2008
Location: Watching from the Shadows

 
DONATE TO ME
I would love thus as well. Now while I don't mind hold the mouse button and dragging the pointer down to draw the line instead of the single click method it would be so much easier with making 2 points and then having the rest get filled in.





If hard work pays off then easy work is worthless
SearchFu
Never Ask someone to do something your not willing to at least try to do yourself.
"Gotham is the work of a madman"- NunHugger Current Nexus 5-12 Nightly


 
Diamondback
Old
#7  
Diamondback's Avatar
Developer Committee / Senior Moderator / Recognized Developer
Thanks Meter 6316
Posts: 4,370
Join Date: Jan 2010
I would love to work on that project here but actually I don't have enough time to code and maintain two projects ( of which is one way bigger than everybody thinks)...

So maybe someone else can join me?

We do have several "harder" tasks to do:
  • Crerate an engine which can generate the patches fro mthe patch lines
  • Something that can work with the patch lines to show the previews
  • The user interface needs to be easy to work with

I would code that with C# and WPF, so if we have some talented experienced .NET WPF devs here it would be cool to make a little team

Contact the Developer Committee with any questions or concerns regarding
the Recognized Developer program.
Mention my name with @Diamondback in any post to easily get my attention.
Please use BB Codes to format your posts.
The Following User Says Thank You to Diamondback For This Useful Post: [ Click to Expand ]
 
AndroidGraphix
Old
(Last edited by AndroidGraphix; 16th December 2011 at 06:11 PM.)
#8  
AndroidGraphix's Avatar
Senior Member - OP
Thanks Meter 374
Posts: 1,229
Join Date: Apr 2011
Location: Paradise Valley, AZ

 
DONATE TO ME
Default Alternative to using draw9patch

Here's a alternative method I uncovered using Adobe Photoshop.

1.Drag and drop png's into Adobe Photoshop instead of Draw9patch
2.Increase canvass size by 2w and 2h.
3. Use the pen tool to make your corrections like you would in draw9patch.
4. Convert pen tool by right clicking on the line you created and select stroke path/pencil/ok
5. Delete the path
6. save the png as .9.png
7. Compile

Here's video on how. For now, it's the best alternative to draw9patch.

This process alone has saved me hours of time. Especially, on large png's.

http://youtu.be/kwpQ8A9r_Zo

Updated 12-16-11. Someone out of Korea just created an awesome draw 9 patch program. It's a must see. Link here.
http://fly-elex.tistory.com/m/entry/the-9-patch-builder
The Following 4 Users Say Thank You to AndroidGraphix For This Useful Post: [ Click to Expand ]
 
Elex_kr
Old
(Last edited by Elex_kr; 20th February 2013 at 09:58 AM.)
#9  
Elex_kr's Avatar
Junior Member
Thanks Meter 44
Posts: 15
Join Date: Dec 2011

 
DONATE TO ME
Hello,
I just make a new id in xda to let you know that
I made an alternative 9 patch tool with Java.

And you can download it from my blog.

(sorry, it says that i shouldn't link external ... oh.. i'll attach the '.jar' file.)

Please try it. Thank you.

DOWNLOAD FROM HERE
Attached Thumbnails
Click image for larger version

Name:	2A9O6Y~Zhh.jpg
Views:	883
Size:	42.7 KB
ID:	820302  
The Following 7 Users Say Thank You to Elex_kr For This Useful Post: [ Click to Expand ]
 
AndroidGraphix
Old
(Last edited by AndroidGraphix; 18th December 2011 at 01:04 AM.)
#10  
AndroidGraphix's Avatar
Senior Member - OP
Thanks Meter 374
Posts: 1,229
Join Date: Apr 2011
Location: Paradise Valley, AZ

 
DONATE TO ME
Quote:
Originally Posted by Elex_kr View Post
Hello,
I just make a new id in xda to let you know that
I made an alternative 9 patch tool with Java.

And you can download it from my blog.

(sorry, it says that i shouldn't link external ... oh.. i'll attach the '.jar' file.)

Please try it. Thank you.
Awesome work Elex_kr! Downloading now. This could change the entire Theme Community/rooted community. Good work. I'll report back soon.

Updated:

WOW! This is a must have Themer tool. Very nice job. Thanks for posting your initial link on my Youtube video. Very much appreciated, your donation has been sent!

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes