Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compose #48

Open
wants to merge 64 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
64 commits
Select commit Hold shift + click to select a range
7aaa8ff
basic pan and zoom is working
markusressel Mar 8, 2022
dd709c4
update dependencies
markusressel Apr 4, 2022
db07339
update dependencies
markusressel Oct 3, 2022
8cd9414
update dependencies
markusressel Oct 3, 2022
d5a0dee
update dependencies
markusressel Oct 3, 2022
cb43f42
refactored ZoomLayout
markusressel Oct 3, 2022
9b157c0
ZoomLayout preview
markusressel Oct 3, 2022
9397b93
simpler code
markusressel Oct 3, 2022
91b9840
upgraded KodeHighlighter dependency
markusressel Oct 8, 2022
4f779da
fix jdk dependency
markusressel Oct 8, 2022
2b4a425
color fixes
markusressel Oct 9, 2022
adbfb3c
added LineNumbers
markusressel Oct 9, 2022
cca81ce
exported .editorconfig
markusressel Oct 9, 2022
eb3bb76
added KodeEditorColors for easier color specification of different pa…
markusressel Oct 9, 2022
ee81b02
refactoring to expose zoom and offset of ZoomLayout
markusressel Oct 9, 2022
089121f
update versions
markusressel Dec 16, 2022
bbc00de
update versions
markusressel Dec 16, 2022
bf6f500
added jitpack config
markusressel Dec 16, 2022
356d642
remove debug dependency to fix release build
markusressel Dec 16, 2022
f8dc47d
added readOnly parameter
markusressel Dec 21, 2022
bc45491
added readOnly parameter
markusressel Dec 21, 2022
d43af22
fix clipping, fix line numbers
markusressel Jan 4, 2023
4c09f6d
Merge remote-tracking branch 'origin/compose' into compose
markusressel Jan 4, 2023
b550ee3
improved padding
markusressel Jan 4, 2023
4b00a4d
reset default zoom
markusressel Jan 4, 2023
c8d8c1f
fix "readOnly" default state, fix background not beeing applied to th…
markusressel Jan 8, 2023
36783b9
fix default colors, fix padding when zooming
markusressel Jan 8, 2023
a89b0b0
better layout, allow zoom <= 1 again
markusressel Jan 8, 2023
a88dd37
removed unnecessary comments
markusressel Jan 8, 2023
3b4cafd
demo app improvements
markusressel Jan 8, 2023
5776739
demo app improvements
markusressel Jan 8, 2023
463ce37
theme fixes
markusressel Jan 9, 2023
f19a774
fix size issues, added shorter text sample
markusressel Jan 10, 2023
52cc4c9
upgrades
markusressel May 13, 2023
072258e
upgrades
markusressel May 14, 2023
5e210e9
migrate build scripts to convention plugins
markusressel May 18, 2023
946b83a
change namespace of demo app, remove group definition of library
markusressel May 18, 2023
6d80de9
update targetSdk
markusressel May 18, 2023
92173aa
fix package
markusressel May 18, 2023
f12768c
add missing publishing plugin
markusressel May 18, 2023
b4de0ec
remove dokkaJar task
markusressel May 18, 2023
6aa5ff1
Merge branch 'master' into compose
markusressel May 19, 2023
abeb87d
remove unused config
markusressel May 19, 2023
87dda90
version migrations
markusressel May 19, 2023
1fbb22c
fix imports
markusressel May 19, 2023
92f2149
remove sourcesJar task
markusressel May 19, 2023
58fba34
update README.md
markusressel May 19, 2023
da575a1
added fetch-depth to checkout to fix telegram notification script
markusressel May 19, 2023
c9aa4b7
try to fix PR notifications
markusressel May 19, 2023
4656859
fix demo app package
markusressel May 19, 2023
3ddcafd
lint fix
markusressel May 19, 2023
7c23a3f
update dependencies
markusressel Dec 16, 2023
5284510
update ksp
markusressel Dec 16, 2023
b205738
use gradle 8.2
markusressel Dec 18, 2023
505fa59
fix published groupId and artifactId
markusressel Dec 18, 2023
d3502b0
fix line numbers not updating
markusressel Jan 1, 2024
735acab
update dependencies
markusressel Mar 15, 2024
8ed3b33
update dependencies
markusressel Mar 15, 2024
41ba750
update dependencies
markusressel Mar 15, 2024
a47763b
refactor
markusressel Mar 16, 2024
d0eacb4
update dependencies, add Makefile
markusressel Jul 14, 2024
75a23d9
remove unused code, fix build
markusressel Jul 14, 2024
6154755
better Makefile
markusressel Jul 14, 2024
6b17123
cleanup
markusressel Jul 14, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .ci/notify.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ fi
if [[ -n "${GITHUB_HEAD_REF}" ]]; then
# this is a PR

COMMITS_INVOLVED=$(git log --oneline ^"${GITHUB_BASE_REF}" HEAD)
COMMITS_INVOLVED=$(git log --oneline ^"origin/${GITHUB_BASE_REF}" HEAD)
PR_LINK_TEXT=$(cat <<EOF
[Pull Request](${GITHUB_URL}/pull/${TRAVIS_PULL_REQUEST})
EOF
Expand Down
925 changes: 925 additions & 0 deletions .editorconfig

Large diffs are not rendered by default.

20 changes: 0 additions & 20 deletions .github/config.yml

This file was deleted.

12 changes: 8 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,19 +12,19 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
with:
java-version: 11
java-version: 17
distribution: temurin
cache: 'gradle'
- name: Perform base checks
run: ./gradlew app:assembleDebug library:sourcesJar library:dokkaJar --stacktrace
run: ./gradlew app:assembleDebug --stacktrace
ANDROID_UNIT_TESTS:
name: Unit Tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
with:
java-version: 11
java-version: 17
distribution: temurin
cache: 'gradle'
- name: Execute unit tests
Expand All @@ -34,11 +34,15 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
# required for telegram notifications on PRs
fetch-depth: 0
- uses: actions/setup-java@v3
with:
java-version: 11
java-version: 17
distribution: temurin
cache: 'gradle'

- name: Setup custom keystore file
run: |
mkdir -p $HOME/.android
Expand Down
1 change: 1 addition & 0 deletions .jitpack.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
jdk: openjdk17
27 changes: 27 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
.PHONY: build

clean:
./gradlew clean

build:
./gradlew assembleDebug
apk: build

buildRelease:
./gradlew assembleRelease

install: build
adb install ./app/build/outputs/apk/**/*.apk

installRelease: buildRelease
adb install ./app/build/outputs/apk/**/*.apk

run: install open

runRelease: installRelease openRelease

open:
adb shell am start -n "de.markusressel.kodeeditor.debug/de.markusressel.kodeeditor.demo.ComposeMainActivity" -a android.intent.action.MAIN -c android.intent.category.LAUNCHER

openRelease:
adb shell am start -n "de.markusressel.kodeeditor/de.markusressel.kodeeditor.demo.ComposeMainActivity" -a android.intent.action.MAIN -c android.intent.category.LAUNCHER
8 changes: 1 addition & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,10 @@
# KodeEditor
# KodeEditor [![codebeat badge](https://codebeat.co/badges/f7fa8602-1d15-457e-904d-cb585e984952)](https://codebeat.co/projects/github-com-markusressel-kodeeditor-master)
A simple code editor with syntax highlighting and pinch to zoom

![Editing](https://thumbs.gfycat.com/TalkativeGrandIchthyosaurs-size_restricted.gif)
![Scroll and zoom](https://thumbs.gfycat.com/BouncyLividBlackbear-size_restricted.gif)
![Minimap](https://thumbs.gfycat.com/VigorousDimFrog-size_restricted.gif)

# Build Status

| Master |
|--------|
| [![codebeat badge](https://codebeat.co/badges/f7fa8602-1d15-457e-904d-cb585e984952)](https://codebeat.co/projects/github-com-markusressel-kodeeditor-master) |

# Features
* [x] Pinch-To-Zoom
* [x] Line numbers
Expand Down
66 changes: 0 additions & 66 deletions app/build.gradle

This file was deleted.

46 changes: 46 additions & 0 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
plugins {
id("kodeeditor.android.application")
id("kodeeditor.android.application.compose")
id("kodeeditor.android.application.flavors")
}

android {
namespace = "de.markusressel.kodeeditor.demo"

defaultConfig {
applicationId = "de.markusressel.kodeeditor"
versionCode = 1
versionName = "4.0.1"

setProperty("archivesBaseName", "KodeEditor_v${versionName}_(${versionCode})")
}
}

dependencies {
implementation(project(":library"))

// Syntax Highlighting
implementation(libs.kodehighlighter.markdown)

implementation(libs.kotlin.stdlib.jdk8)

implementation(libs.androidx.appcompat)
implementation(libs.material)
implementation(libs.androidx.compose.ui)
implementation(libs.androidx.compose.material)
implementation(libs.androidx.lifecycle.runtime.ktx)
implementation(libs.androidx.activity.compose)

implementation(libs.fuel)
implementation(libs.fuel.android)

implementation(libs.kotlinx.coroutines.core)
implementation(libs.kotlinx.coroutines.android)

debugImplementation(libs.androidx.compose.ui.tooling)
implementation(libs.androidx.compose.ui.tooling.preview)

testImplementation(libs.junit4)
androidTestImplementation(libs.androidx.test.ext.junit)
androidTestImplementation(libs.androidx.test.espresso.core)
}
21 changes: 0 additions & 21 deletions app/proguard-rules.pro

This file was deleted.

12 changes: 8 additions & 4 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="de.markusressel.kodeeditor">
<manifest xmlns:android="http://schemas.android.com/apk/res/android">

<uses-permission android:name="android.permission.INTERNET" />

Expand All @@ -13,14 +12,19 @@
android:theme="@style/AppTheme"
android:windowSoftInputMode="adjustResize">
<activity
android:name=".MainActivity"
android:exported="true">
android:name=".ComposeMainActivity"
android:exported="true"
android:theme="@style/AppTheme">
<intent-filter>
<action android:name="android.intent.action.MAIN" />

<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>

<activity
android:name=".MainActivity"
android:exported="false" />
</application>

</manifest>
Loading