FORUMS
Remove All Ads from XDA

[MOD] Add top number row to Swype

508 posts
Thanks Meter: 280
 
By ozkaya, Senior Member on 6th October 2013, 07:43 AM
Post Reply Subscribe to Thread Email Thread
Hello guys,

Since I use a Samsung device, I'm used to the extra number row on top of the keyboard so I modded Swype to have that extra row. However since Swype is to be purchased and not distributed, I'll only tell here how to do it for your legally purchased copy. And this is a bit complicated and for advanced users and you need to be rooted. You also need Root Explorer. Here we go:

1- First buy/download Swype from Google Play.
2- Go to /mnt/asec/com.nuance.swype.dtc-1 folder, copy pkg.apk to your sdcard, rename it to com.nuance.swype.dtc-1.apk.(keep a backup of this file at all times)
3- Go to /mnt/asec/com.nuance.swype.dtc-1/lib folder copy the files (libnmsp_speex.so and libswypecore.so) to your sdcard.
4- Using apktool (I used version 1.52) decompile com.nuance.swype.dtc-1.apk.,
5- Go to decompiled folder\res\xml folder. kbd file pertaining to your language is to be edited, I edit kbd_qwerty.xml for English using Notepad++.
6- Check the attached kbd_qwerty.xml in portrait folder and notice the extra row section I added to the top. You can in fact add secondary characters to numbers or customize the keyboard completely, rearrange letters, add symbols etc.
7- Once done, save the file and go to decompiled folder\res\xml-land folder and edit the landscape for the layout, kbd_qwerty.xml file, notice the attached file in landscape folder.
8- Once done, save the file and go to decompiled folder\res\values folder and edit the dimens.xml file. Here I raise the height of the keyboard and height of the key to 270dip and 54dip respectively, check the top rows of the attached dimens.xml. Also increase the keyboard height for landscape (if you want) by changing the dimens.xml under res\values-land folder.
9- Once done, recompile the folder with apktool, go to decompiled folder\dist folder and copy the apk here to a different folder and rename it to temp.apk.zip
10- Open temp.apk.zip with 7z/winrar and copy the resources.arsc and kbd_qwerty.xml files from res\xml and res\xml-land folders to your PC(obviously keep the 2 files in seperate folders not to overwrite)
11- Then, rename the original apk from step 2 to com.nuance.swype.dtc-1.apk.zip , open with winrar and first delete resources.arsc file, then drag the resources.arsc file from step 10 to the archive, it will be added. Staying in winrar, go to res\xml folder and replace the file with kbd_qwerty.xml from step 10 (the portrait version). Do the same with res\xml-land folder and the landcape file.
12- Once finished rename the file back to com.nuance.swype.dtc-1.apk, don't sign it, don't delete META-INF folder, leave it as it is.
13- Now, on your phone, uninstall Swype. Reinstall it from the apk file on Step 2. Go to /data/app-lib/com.nuance.swype.dtc-1 folder and move the 2 files (libnmsp_speex.so and libswypecore.so) to system/lib folder. You have to mount the System R/W from Root Explorer on this step. Fix the permissions so these 2 files have the same permissions with other files there. If you can't find these files just use the ones from Step 3.
14- Once done, copy com.nuance.swype.dtc-1.apk from Step 12 to /system/app and fix the permissions so that it has the same permissions as other files there.
15- Then delete the com.nuance.swype.dtc-1.apk from /data/app/ folder. Restart your phone.

This should be it if you followed it exactly, tracing and Dragon voice dictation also works. While you're doing all this work (takes 10 minutes by the way), you might also consider changing how Swype looks (theming) and changing many other things like swype thickness, colors etc. Please note that this is for advanced and rooted users and please don't ask me to give you the modded apk, you have to do it on your legally bought version. You might consider doing backups just in case anything goes wrong. Have fun.
And a quick tip: if you swype from swype icon to symbol key(123), arrow keyboard opens up.

You can also add arrow keys by copying arrow keys from kbd_edit.xml, check the 2nd screenshot.

Please hit the thanks button if you think this is useful.
Attached Thumbnails
Click image for larger version

Name:	001.jpg
Views:	8869
Size:	29.5 KB
ID:	2305509   Click image for larger version

Name:	002.png
Views:	5764
Size:	112.8 KB
ID:	2963631  
Attached Files
File Type: zip template.zip - [Click for QR Code] (3.0 KB, 1132 views)
Last edited by ozkaya; 8th October 2014 at 07:17 AM.
The Following 34 Users Say Thank You to ozkaya For This Useful Post: [ View ] Gift ozkaya Ad-Free
 
 
6th October 2013, 12:39 PM |#2  
AnTerNoZ's Avatar
Senior Member
Flag Siegen
Thanks Meter: 552
 
Donate to Me
More
Nice how to. But may u should tell that the latest Android versions store purchased apps in data/app-asec as asec version, this need special procedure to get a apk from the asec format.
30th October 2013, 08:11 PM |#3  
darwinwin's Avatar
Senior Member
Beirut
Thanks Meter: 71
 
More
Can you please update this tutorial to 4.3 ? I couldn't find the files in the mentioned paths. . I'm on stock rooted 4.3 on gt9500

Sent from my GT-I9500 using XDA Premium 4 mobile app
7th November 2013, 03:31 PM |#4  
ozkaya's Avatar
OP Senior Member
Thanks Meter: 280
 
More
Quote:
Originally Posted by lesalloum

Can you please update this tutorial to 4.3 ? I couldn't find the files in the mentioned paths. . I'm on stock rooted 4.3 on gt9500

Sent from my GT-I9500 using XDA Premium 4 mobile app

It works same for me on 4.3 stock rooted i9500, maybe you could do a file search to find the necessary folder. Here is another screenshot with the updated Swype(1.6.2.22328), where I made number buttons smaller like original Samsung Keyboard and hide the suggestions bar to save space.
Attached Thumbnails
Click image for larger version

Name:	002.png
Views:	2229
Size:	141.3 KB
ID:	2377463  
The Following 2 Users Say Thank You to ozkaya For This Useful Post: [ View ] Gift ozkaya Ad-Free
16th November 2013, 08:10 PM |#5  
Senior Member
Flag NJ
Thanks Meter: 337
 
More
Quote:
Originally Posted by ozkaya

Hello guys...
9- Once done, recompile the folder with apktool, go to decompiled folder\dist folder and copy the apk here to a different folder and rename it to temp.apk.zip
....

using the current play store version (1.6.3.22544), i decompiled com.nuance.swype.dtc-1.apk (/mnt/asec/com.nuance.swype.dtc-1/pkg.apk) using APKTool 1.52. i made no changes and attempted to recompile without success.

the first error displayed by apktool is:
"C:\Users\Phil\apktool\com.nuance.swype.dtc-1\res\values\arrays.xml:545: error: Found tag dimen-array where item is expected"

i do use APKTool successfully to mod other apps so i am familiar with the process.

QUESTION: what frameworks file are you using when making your mods? are you using a TW ROM frameworks? that's the only other variable i can think of...


EDIT: well, i just tried using TW framework too without success
Last edited by PhilDX; 17th November 2013 at 06:01 PM.
17th November 2013, 04:48 AM |#6  
ozkaya's Avatar
OP Senior Member
Thanks Meter: 280
 
More
Quote:
Originally Posted by PhilDX

using the current play store version (1.6.3.22544), i decompiled com.nuance.swype.dtc-1.apk (/mnt/asec/com.nuance.swype.dtc-1/pkg.apk) using APKTool 1.52. i made no changes and attempted to recompile without success.

the first error displayed by apktool is:
"C:\Users\Phil\apktool\com.nuance.swype.dtc-1\res\values\arrays.xml:545: error: Found tag dimen-array where item is expected"

i do use APKTool successfully to mod other apps so i am familiar with the process.

QUESTION: what frameworks file are you using when making your mods? are you using a TW ROM frameworks? that's the only other variable i can think of...


EXIT: well, i just tried using TW framework too without success

Latest version of Swype has incompatible tags with Apktool. What you do is go to all the lines that give error and change them to <string-array>. Then it compiles.
Last edited by ozkaya; 17th November 2013 at 08:13 AM.
The Following 3 Users Say Thank You to ozkaya For This Useful Post: [ View ] Gift ozkaya Ad-Free
17th November 2013, 05:01 AM |#7  
Senior Member
Flag NJ
Thanks Meter: 337
 
More
Quote:
Originally Posted by ozkaya

Latest version of Skype has incompatible tags with Apktool. What you do is go to all the lines that give error and change them to <string-array>. Then it compiles.

i'll give this a shot tomorrow, thanks a lot!
17th November 2013, 08:00 PM |#8  
Senior Member
Flag NJ
Thanks Meter: 337
 
More
Quote:
Originally Posted by ozkaya

Latest version of Swype has incompatible tags with Apktool. What you do is go to all the lines that give error and change them to <string-array>. Then it compiles.

it works!!!

thanks man, appreciate the help and info!
18th November 2013, 03:51 AM |#9  
thumm138's Avatar
Member
Thanks Meter: 6
 
More
I've been going nuts trying to edit swype for a week now and still can't seem to get it to work. All I want to do is change the suggested word color and maybe a few other minor color related things. I assumed just changing the color codes in /res/values/styles.xml that seemed to pertain to the holo theme would work but I can't ever get the app to install. Not even sure where to begin to ask for help on this one but if anyone has any advice I'd greatly appreciate it.
20th November 2013, 01:16 AM |#10  
TeknoGodz's Avatar
Senior Member
Flag Tampa
Thanks Meter: 49
 
More
Ok I've tried this a hundred times following all the steps completely and it just wont work.

Once I go to install the final apk it always tries to install then sais App Not Installed.
20th November 2013, 08:13 AM |#11  
ozkaya's Avatar
OP Senior Member
Thanks Meter: 280
 
More
Quote:
Originally Posted by TeknoGodz

Ok I've tried this a hundred times following all the steps completely and it just wont work.

Once I go to install the final apk it always tries to install then sais App Not Installed.

You don't install the final apk, in fact you can't since the certificate is no longer valid. You copy the final apk in place as in Step 14.

Read More
Post Reply Subscribe to Thread

Tags
dedicated number row, extra number row, number row, swype

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes