CodeAssist Versions Save

Experimental IDE for building Android applicatons on Android.

ALPHA-0.2.4.1

2 years ago
  • Fixed crash when compiling with AAPT2.
  • Fixed editor highlighting in XML not working due to wrong diagnostic positions
  • Fixed google-services.json is not parsed properly
  • Fix crash when editing a kotlin file.
  • Fixed Actions are not ordered properly based on insertion.
  • Fixed resources located in app/src/main/resources are not getting added to APK and AAB properly.
  • Fixed back button not clickable in libary manager.

ALPHA-0.2.4

2 years ago

Hot Fix for 0.2.3

  • Fixed code completion does not work on top level classes and imports.
  • Fixed built applications that are using firebase crashing due to wrong keys in secrets.xml
  • Fixed android app bundles not building.
  • Fixed queries tag not recognized error.
  • Updated AAPT2 binaries.

ALPHA-0.2.3

2 years ago

What's new

XML Code Completions

Android Manifest

  • Complete android manifest tag attributes and values.
  • Long press the manifest tag to automatically add permissions (#151)

Android Layouts

  • Completion of attributes based on the current view and its parent. Example if a view has a a parent of ConstraintLayout then it the code completions will have attributes for ConstraintLayout aswell.
  • External libraries defined in a app/libs or in the Library Manager is now included in code completion.

Layout Editor

  • The layout editor attributes dialog will now have drop down code completions based on the current attribute.

Dynamic Vector Drawable Preview

  • Vector drawables found in res/drawable will now be visible on the layout editor.

Realtime Error Highlighting for XML

  • Writing code in xml will now have real time error highlighting based on the diagnostics given by AAPT2. Although it is limited to the whole line as AAPT2 does not provide information about the column at which the error is located in.

Actions API

  • A new API to easily add menus to CodeAssist, see Actions API for more information on how to add custom actions.

FIle Editor API

  • An API to easily add a file editor on CodeAssist based on the current file. A documentation is being written for it.
  • When there are multiple FileEditors for a specific file, there will be a dialog asking for the user which editor to use.

Select All Semantically (Java)

  • Using the java parse tree, CodeAssist now supports selecting the code based on the tree. To invoke it, long press on a java code and press the Select All action. (example, pressing the action on a method will select the whole method, pressing it on a class will select the whole class declaration)

Java Completions

  • Better completion cancellation. Before, if the user is typing quickly all the completions will stack up and will wait for each other to complete, wasting resources. Now completions will be canceled before each completion request is invoked.
  • When typing in a parameterized tree (inside a the <> in Map<String, String>) only class names will be shown as methods are not applicable there.
  • Better fuzzy search, prefix does not need to exactly match for it to show on the completion list.
  • Better error highlighting.
  • Improved generic type inference of method return types.

Excluding dependencies

  • The common issue most users of CodeAssist face is the duplicate class issue with R8/D8. To help prevent this, a new feature has been added which lets users exclude dependencies from a library. There is no UI for it yet but it can be achieved by editing the libaries.json file. Example of using the feature:
{
  "groupId": "com.my.dependency",
  "artifactId": "dependency",
  "versionName": "1.4.0",
  "excludes": [
    {
      "groupId": "com.excluded.dependency",
      "artifactId": "excluded"
    }
  ]
}

WIth the above example, the app will ignore all the dependencies of com.my.dependency that matches the dependencies that are listed in excludes.

Better Duplicate Class Error Report

  • To help with excluding dependencies, the app will now also display from which class/jar/dependency the duplicate files are found.

Adding libraries from build.gradle

  • You can now get the libaries defined in the build.gradle file from the library manager.

Misc

  • Added highlight support for JSON.

Known Issues

  • Building with Android App Bundles (AAB) does not currently work. This is due to the change from using AAPT2 binaries to invoking it through JNI. A fix is in progress.

ALPHA-0.2.2

2 years ago

Layout Editor Improvements

  • Views will now be inflated with styles (the one specified in the manifest), Views using attributes such as ?attr/colorPrimary will now get the color from the styles.
  • Added TextInputLayout and TextInputEditText support (using styles with it may not produce expected results yet, drag and drop may not work as expected as TextInputLayout has an intermediate FrameLayout inside)
  • color, dimen, inset, selector tags are now parsed in resources.
  • Android xml attributes are now stored in app's assets folder and will also be included in parsing for layout preview.
  • Xml files of libraries that you have will now be included in parsing for layout preview.
  • You can now write common view class names without their fully qualified class names (Button instead of android.widget.Button)
  • Added material parser factory, common view class names will now be replaced with their material view equivalent. (turned on by default, Button will be replaced to com.google.android.material.button.MaterialButton
  • If an attribute has been set to empty, it will automatically be removed.
  • When an attribute has been removed, the view that the attribute is associated with will now be recreated to remove the attributes.
  • Required width and height attributes are now automatically added when using the drag and drop editor.

Code Completion and Code Highlighting

  • Asynchronous highlighting, java and kotlin error highlighters are now run in background and will be canceled accordingly as the user types.
  • The app now supports real-time error highlighting for Kotlin. (Turn it on in settings, make sure that code completion for kotlin is off as its still unstable with code completions turned on.)
  • Generic types are now displayed properly in code completion list.
  • Fixed deadlocks causing code completions and error highlighting to completely stop functioning before.

Better External Keyboard Support (Keyboard shortcuts)

  • alt + space Force the completion window to open at the cursor position
  • alt + enter Show context actions or quick fixes based don the current cursor position.
  • shift + enter Add a new line regardless of column position.

Context Actions and Quick Fixes

  • View javadoc action, quickly view the documentation of the selected code. (Currently there are a few comments because including the sources in the app will significantly increase its size)
  • Diagnostic information action, if the current selected code has an underline in it, this action will show information about what the error or warning is.

Logs

  • Logs of built APKs should now be shown consistently (Unless the app crashed before onCreate is called.)
  • Errors of the current file you're editing are now shown in real-time, just swipe up from the bottom and navigate to the Debug tab.

ALPHA-0.2.1

2 years ago

Improved Layout Editor (#115 )

  • Added more new widgets
  • You can now select multiple attributes to add to the view
  • The available attributes section will now show all the available attributes including its parent layout attributes.
  • Proper handling of unknown views, while the editor can't preview the attributes it does not know, it will still try to make them editable.

Improved quick fix API

  • After long pressing on a java token, the context actions will now show up immediately.
  • Add throws quick fix will now only show on appropriate methods.
  • quick fix API will no longer try to import with generic types (previously it imports java.util.List<String>)
  • Introduce local variable now works on anonymous classes.

Misc

  • Folders are now shown first before files in the tree view.
  • Which duplicated files are now shown on the logs after building.
  • Bug fixes, #114, #116

ALPHA-0.2.0

2 years ago

New features

Quick fixes / Context Actions

  • Introduce local variable, quickly declare the return type of the method that you are long pressing on. The completion engine will ensure that the introduced variable name is unique. (Currently supported expressions are method calls and new class declarations).
  • Add throws fix, automatically add throws ExceptionName to the method containing the call.
  • Surround with try catch, surround the current expression with a try catch block catching the exception thrown.
  • Add catch clause, if there is an existing try catch block surrounding the expression, this will add a new catch block catching the exception.

To invoke quick fixes / context actions, long press on the underlined errors or the code that you want to perform an action on.

Smarter suggestions for generic types

  • The completion engine will now show proper types of objects with generic types. e.g.
List<String> list = new ArrayList<>();
list.<cursor position>

The completion engine will show

add(String string);

instead of

add(E e);

Library Manager

Adding dependencies through the build.gradle file is NO LONGER SUPPORTED. CodeAssist will no longer try to parse them. To add new libraries there is now a library manager. To access it tap the folder icon on the top right of the home screen and then press the library manager text. To add a dependency, tap the Floating Action Button and type the proper groupId, artifactId and versionName of your library. Excluding dependencies from a particular library will be supported soon.

Viewing dependencies

To view the dependencies of a library that you have added, long press the item and tap View all dependencies. Fetching POMs may take a while on slow internet connections.

Faster Dependency Resolution

The app now includes a list of commonly downloaded POMs of libraries. This will significantly reduce dependency resolutions times as individually downloading POMs takes the longest time in dependency resolution.

Editing layout attributes

Although there is no proper UI yet for layout editor, you can now edit the attributes of the layout by pressing the view that you want to edit on. There is no validation yet. There is also a plus (+) button below the attributes for you to choose to add from the available attributes based on the current view type and its parent. e.g. If the view type is TextView, you will have a list of its attributes and also the attributes of View. If it's parent is a ConstraintLayout, it will also have the app:layout_constraintLeft_toLeftOf and other attributes of a ConstraintLayout child.

Jar Corruption Check

Previously if a jar has been corrupted after the user's connection has been lost it will crash the app. Now there's several checks in place to detect jar corruption. First is in dependency resolution, if a jar file is corrupt it will be deleted and re-downloaded again. Second check is before compilation, if a jar file is corrupt it wont get deleted but will simply be ignored from the classpath.

AAR Native Libraries and Assets

If you are using a library that has assets and native libraries, CodeAssist will now properly add them to the APK.

ALPHA-0.1.9

2 years ago

This is the same as the release on the Google Play. Note that you need to uninstall the google play version when transferring to the APKs from GitHub be sure to back up your projects first.

This APK can be only be intalled on Android 8.0 devices and up.

  • Fixed memory leaks in the editor, analyzers and code completions. #86
  • Added an About Us page in the settings.
  • New dynamic launcher icon
  • Added an option to disable apk installation prompt.
  • Fix crash when creating and deleting the same file #81
  • Improve completions (Selecting an item will now include or exclude parentheses based on the current line)

ALPHA-0.1.8

2 years ago
  • Fixed completion resetting on some occasions #74
  • Added install button after compilation #73
  • Fixed some dependencies not getting downloaded if it uses maven version ranges. #65, #68
  • Fixed crash when pressing format on a groovy file
  • Throws type will now be completed as well
  • Fixed crash when the file manager is empty and the user tries to refresh.
  • Improve highlighting of java methods.
  • Added a menu to change the project path on android 10 and below.

ALPHA-0.1.7

2 years ago

This contains fixes for the new dependency resolution. The dependencies should now be updated properly.

  • Syntax error highlighter for XML
  • Added block lines for XML tags.
  • Added error highlighting for kotlin still experimental, do not report crashes
  • Fixed crash on pressing enter with empty completion items
  • Fixed crash on closing AppLogFragment

ALPHA-0.1.6

2 years ago
  • New dependency resolver implementation (faster and more reliable, backed up by unit tests), you may need to re-download your project dependencies again.
  • Only projects with supported structures are showed in the main menu. (Projects with the app module).
  • Fixed #57
  • Inflation errors are now properly handled on layout preview
  • Added androidx.appcompat.widget.Toolbar into layout preview widgets
  • fixed some attributes in layout preview turns into Unknown
  • Fixed crash upon clicking the TextView inside an UnknownViewGroup
  • Fixed parsing dynamic android drawables
  • Fixed on parsing ripple drawables