Documentation

Topics
  1. Installation how to - The download page contains an installation how to. We recomend it to be read first to make sure everything is set correctly.
  2. Tutorial - Short tutorial on this page will introduce you to touchqode editor.
  3. FAQ - Other questions you may ask are answered in the faq section.
  4. Known issues

FAQ

Questions

Which languages do you support?

How to keep your source code synchronized with touchqode?

How to set up my synchronization step by step?

You suggest downloading new version of file every time you edit it. Isn't that a waste of bandwidth?

Which permissions do you require?

I try to run / compile my code, but the application says "Could not find SL4A interpreter"!

How to copy and paste more efficiently?

Keyboard is missing at, pipe, hash keys (@, |, #)?

How to quickly switch between recent files?

Keyboard does not show up!

How to navigate in file?

How to search efficiently?

I have three buttons "a", "b", "c" on the screen. What happened?

Will touchqode fit my way of thinking?

I am left handed or I do not like buttons on left side. What to do?

I have been working on my file for half an hour and now it is gone. How do I recover lost file?

I have a bug in my source and want to fix it on my way home - what is the best approach?

Are you affiliated with dropbox?

I really like touchqode. How can I contribute?

Your software is full of bugs!

Which languages do you support?

The most extensive support is implemented for Java. Other languages, supported up to some level, are C++, C#, Python, Ruby, HTML, JavaScript, PHP and simple XML.
Language for highlighting is chosen by file extension. Recognized extensions are: .java, .c, .cpp, .h, .hpp, .cs, .py, .rb, .html, .htm, .jsp, .js, .xml, .php, .php3, .as (JavaScript).

Touchqode can compile and run some of your code using SL4A, more here.

How to keep your source code synchronized with touchqode?

Disclaimer: this section might sound a bit complicated. The reason is we are in the early stage of development and are focusing on the components that adds most value to the code editor itself. For time being the synchronization is handled well by dropbox (even though setup is not entirely simple). We plan to simplify synchronization in future releases. If you just want to see step-by-step tutorial see next question.

You get biggest advantage from using touchqode when you can continue to work on the same version of sources as you have on your desktop. To do this you can use any synchronization service since touchqode associates itself as editor of text files on android.

However we are personally using dropbox service to keep our source files always available from the internet and we are quite happy with it.

On the desktop you have to set up a dropbox shared folder. However you probably want to have control over which files get synchronized back to the project folder. Because of that do NOT share the working project folders with dropbox. Instead we suggest to use rsync or equivalent to echo changes from project folder to dropbox folder. Rsync comes bundled with Linux and MacOSX; on windows we use cwRsync which can be found here After receiving changes from mobile phone use windiff to check the new changes before copying them to the project folder. This helps to keep peace of mind that dropbox will not accidentially overwrite some of your work. On linux diff should do the same job. On Mac OS X you could use FileMerge (it should come with Xcode).

Synchronization overview:

Synchronization overview

For a detailed setup instructions see next question.

If you want to work on your latest version from mobile phone you need to have dropbox android app installed.

To ensure that you work on fresh files always first run the dropbox app. In the app navigate to the file you want to edit and tap on it – dropbox downloads it and offers you choice of text editors. Choose touchqode and you are ready to view and edit the file. Every time you save file it gets uploaded by dropbox to server. However once you have synchronized all necessary files you can use touchqode quick switching to move between files.

How to set up my synchronization step by step?

I will describe windows setup. Linux/Mac should analogous

On your desktop:

  1. Register with dropbox, install its desktop application.
  2. Download and install cwRsync (http://www.itefix.no/i2/node/10650)
  3. Create a batch file that syncs your project files to dropbox. We have provided samples for you:
  4. (optional)Create a desktop shortcut for running rsync batch file.
  5. Download windiff (http://www.grigsoft.com/download-windiff.htm)
  6. Create a batch file that diffs your dropbox and desktop project folders.
    Sample file: windiff_sample.bat
  7. (optional)Create a desktop shortcut for running windiff batch file.
  8. Now you can synchronize and diff files between your project and dropbox folder by one click from your desktop.

On your mobile phone:

  1. Install touchqode (see installation instructions)
  2. Install Dropbox app.
  3. To access files from your desktop open Dropbox app:
    • Navigate to file you want to edit and tap it (you might need to choose "View as text")
    • File will be automatically downloaded
    • Choose touchqode as your editor
    • When you save file from touchqode it will be automatically uploaded back to Dropbox.

You suggest downloading new version of file every time you edit it. Isn't that a waste of bandwidth?

Somewhat yes. However most source files are probably not much larger than 50-100kb which is smaller than amount of data you download for single web page. Plus they are easy to compress so they shouldn't impact your bills significantly.

Which permissions do you require?

Touchqode needs following permissions:

How to copy and paste more efficiently?

  1. press hardware <Menu> button
  2. tap on Copy/Paste
  3. tap on the start of block you want to copy
  4. press <Start sel.>
  5. tap on the end of block you want to copy
  6. press <End sel.>
  7. now the selection is fixed and you can long press to copy/cut without worrying of deselecting the block
  8. when copied to clipboard press <Start sel.> or <Edit> button
  9. tap where you want to paste and long press to paste

Keyboard is missing at, pipe, hash keys (@, |, #)?

Press ALT+Tab to switch to symbol keyboard and you can find them there.

How to quickly switch between recent files?

Press <Recent files> button and choose one of the 15 recently opened files.

Keyboard does not show up!

Press <Edit> button and it should show up.

Touchqode works in two basic modes – view and edit. In view mode you move around your file and search. In edit mode you actually edit your file. The keyboard is not shown automatically (this is intentional) – it shows only when you press <Edit> button i.e. you enter edit mode.

How to navigate in file?

You have a few options:

How to search efficiently?

Press <Search> button or search hardware button on your phone – the search pane will be shown. As you type the incremental search will go to next found occurrence. If you want to see next occurrence press <Next> button. For all occurrences press <All> button. If you want to start another search press <Clear> button.

All occurrences are shown in the thin black column on the right. You can use it to navigate easily across multiple found results – just tap on the small purple rectangle corresponding to it.

I have three buttons: "a", "b", "c" on the screen. What happened?

You have probably pressed ALT+Space or Tab and you were shown autocomplete pane with suggestions based on your position.

In order to minimize number of suggested words we present you only with their longest common prefixes. E.g. for possible suggested words "public", "private" and "protected" we show only "public" and "pr". When you click on "pr" you will get suggestions "protected" and "private".

In your particular case you probably pressed ALT+Tab on blank line so touchqode offered you all possible keywords sorted by their longest common prefixes - which happen to be "a", "b" and "c". To see other suggestions you can scroll the list of buttons.

Will touchqode fit my way of thinking?

Touchqode was created from personal need and we are using it on regular basis if only to browse through the code we have been working on the way home.

It was conceived as somewhat a cross between vim with its normal, insert and visual modes and eclipse with great code navigation and autocomplete tools.

For some situations where you can use touchqode see “Why coding on smartphone?” section on home page

I am left handed or I do not like buttons on left side. What to do?

<Toggle buttons> button is in the menu. It toggles between three states of the buttons - left, right and invisible.

I have been working on my file for half an hour and now it is gone. How do I recover lost file?

It should not be gone for good - touchqode has autosave feature - every two minutes it saves current file to path /sdcard/touchqode/autosave.tmp so check there.

I have a bug in my source and want to fix it on my way home - what is the best approach?

Use mobile source code editor - touchqode! For instructions how to set up everything see tutorial.

Are you affiliated with dropbox?

No, we are not connected to them in any way. But we like their service and are using it ourselves.

I really like touchqode. How can I contribute?

We are happy you like it! Spread the word, let people know, blog about it, send us bug reports and feedback. If you want to contribute money - touchqode is currently free but we welcome donations using paypal. And in case you are really good programmer and would like to work with us let us know.

Buy us a beer or two:

Your software is full of bugs!

We are sorry. Since touchqode is in alpha version we know there are issues. We are hunting for and fixing each single bug we can track down but we are always eager to fix bugs we get to know from our users. Please file a bug report in contact section.

I try to run / compile my code, but the application says "Could not find SL4A interpreter"!

We use the Scripting Layer for Android (SL4A) to run programs. Currently the supported languages include Python, Rhino JavaScript, JRubby and PHP. You can find more information at http://code.google.com/p/android-scripting/.

Following instructions might help in using this functionality. First, you will need to install the SL4A installed from SL4A homepage to your Android. In the middle of this page there is a big QR code. Download this apk (sl4a_r3.apk) and install it. You can do this right from your phone, or via USB from your computer (Mind the sizes downloads!). This way you get the basic environment, but you do not have any language installed yet. In the right section of this page on top ("Featured" / "Downloads"), there are several links to .apk files. Choose the languages of your choice, install them. You can find more languages (PHP, JRuby..) in "External links" section on the right. After that you are ready to run your first script on Android.

Watch out for the size of the downloaded files!! They can be more than 10MB per language and during the installation, the apk can download even more MBs! We recommend that you do this installation via a free wifi!!

After you have your favourite languages in SL4A in your phone, run the code by clicking Menu/Save & Run.

 
Live Chat Software by Olark