Skip to content

Commit

Permalink
Major restructuring of the documentation (#1885)
Browse files Browse the repository at this point in the history
  • Loading branch information
soywiz authored Sep 28, 2023
1 parent 0ce05ec commit 80c7b30
Show file tree
Hide file tree
Showing 27 changed files with 106 additions and 366 deletions.
30 changes: 0 additions & 30 deletions docs/_includes/using_with_gradle.md

This file was deleted.

15 changes: 9 additions & 6 deletions docs/_layouts/default.html
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,13 @@
<script src="/js/mermaid/mermaid.min.js"></script>
{% endif %}

{% if page.redirect_to %}
<meta http-equiv="Refresh" content="0; url='{{ page.redirect_to }}'" />
<script>
document.location.href = `{{ page.redirect_to }}`;
</script>
{% endif %}

<!-- 2 -->
</head>

Expand All @@ -44,12 +51,8 @@
<div class="container-fluid">
<div class="navbar-header">
<a class="navbar-brand" href="/" style="padding:10px;">
<!--
<img alt="Korlibs" src="/i/logos/korlibs.svg" width="32" height="32" style="display: inline;" />
Korlibs
-->
<img alt="Korlibs" src="/i/logos/korge.svg" width="32" height="32" style="display: inline;" />
Korlibs
<img alt="KorGE" src="/i/logos/korge.svg" width="32" height="32" style="display: inline;" />
KorGE

</a>
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1" aria-expanded="false">
Expand Down
4 changes: 2 additions & 2 deletions docs/contributing/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,13 @@ cd korge
./gradlew publishToMavenLocal
```

This publishes all the libraries with the version `2.0.0.999` in the `~/.m2` folder.
This publishes all the libraries with the version `999.0.0.999` in the `~/.m2` folder.

To make compilation faster, you can add `org.gradle.parallel=true` to your `~/.gradle/gradle.properties` file (crete it if it doesn't exist).

### Using `korge-next` in a KorGE project

To use korge-next in a KorGE project, just build and publish it locally and replace your version with `2.0.0.999`.
To use korge-next in a KorGE project, just build and publish it locally and replace your version with `999.0.0.999`.

## Documentation

Expand Down
20 changes: 17 additions & 3 deletions docs/faq/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ Yes. All these libraries are dual licensed under MIT and Apache 2.0 or CC0 Publi
## Where can I find the libraries?
{:#repos}

* You can find the source code of my libraries on <https://github.com/korlibs> and <https://github.com/soywiz>.
* I publish all my library binaries at maven central too: <https://search.maven.org/search?q=g:com.soywiz.korlibs.*>.
* The libraries are also synchronized to maven central automatically.
* Source Code for version 4: <https://github.com/korlibs/korlibs4>
* Source Code for version 5+: <https://github.com/korlibs/korge>
* All the libraries are published to maven central too: <https://search.maven.org/search?q=g:com.soywiz.korlibs.*>.

## I get an error: unable to find library -lGL on Linux

Expand Down Expand Up @@ -218,6 +218,20 @@ Can you listen it here:
<source src="/i/sound/korge.mp3" />
</audio>

## Where are the old Korlibs4 libraries?

Starting with KorGE 5.0, for convenience and focus, the old Korlibs are now
integrated into the `korge`, `korge-core` and `korge-foundation` artifacts.
The code is still there, except for some package renames.

You can find the old code and structure there:

* Docs: <https://korlibs4.soywiz.com/>
* Code: <https://github.com/korlibs/korlibs4>

The community can contribute via PR to the repo and maintain the libraries
supporting new targets, new Kotlin versions, fixing bugs, documenting etc.

## Where's the privacy page

[Here it is](/privacy)
71 changes: 1 addition & 70 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,74 +4,5 @@ title: Korlibs
fa-icon: fa-home
permalink: /
useMermaid: true
redirect_to: /korge/
---

<img src="/i/logos/korlibs.svg" width="64" height="64" style="float:left;margin-right:16px;"/>

**Korlibs** is a set of Kotlin Common modern libraries to do full stack development aiming Kotlin 1.3.

It stands for **K**otlin c**OR**outines **LIB**raries. Though not all its library components have asynchronous parts.

It is suitable for building [backend servers or cli tools that run on JVM or Node.JS](/korio) and [desktop, web and mobile games](/korge), including [**emulators**](https://github.com/kpspemu/kpspemu), and [GUI applications](/korui).

It's philosophy is: simple, small, powerful, cohesive, enjoyable, portable, multiplatform and asynchronous.

Some of these libraries are tightly tied to provide an awesome experience.

<pre class="mermaid">
flowchart TD
kbignum["fa:fa-infinity kbignum"]
klock["fa:fa-clock klock"]
krypto["fa:fa-lock krypto"]
klogger["fa:fa-newspaper klogger"]
korte["fa:fa-align-justify korte"]
kds["fa:fa-table kds"]
korinject["fa:fa-network-wired korinject"]
kmem["fa:fa-memory kmem"]
korio["fa:fa-save korio"]
korau["fa:fa-music korau"]
korim["fa:fa-image korim"]
korma["fa:fa-calculator korma"]
korge["fa:fa-gamepad korge"]

kotlinx.coroutines --> korcoroutines

korcoroutines --> korio
klock --> korio
kds --> korio
kmem --> korio
krypto --> korio
klogger --> korio

kds --> korma
jna --> kmem

%% ktruth --> korim
korma --> korim
korio --> korim

korim --> korgw

korgw --> korge
korau --> korge
korinject --> korge
korte --> korge

korma --> korau
korio --> korau

click kbignum href "/kbignum/"
click kds href "/kds/"
click klock href "/klock/"
click kmem href "/kmem/"
click krypto href "/krypto/"
click klogger href "/klogger/"
click korma href "/korma/"
click korio href "/korio/"
click korau href "/korau/"
click korim href "/korim/"
click korinject href "/korinject/"
click korte href "/korte/"
click korge href "/korge/"

</pre>
4 changes: 1 addition & 3 deletions docs/kbignum/index.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
layout: default
title: KBigNum
title: Big Numbers
fa-icon: fa-sort-numeric-up
priority: 200
---
Expand Down Expand Up @@ -181,5 +181,3 @@ We can construct closed ranges the range `..` operator:
```kotlin
(10.4.bn in (10.5.bn .. 16.5.bn)) == false
```

{% include using_with_gradle.md name="kbignum" %}
4 changes: 1 addition & 3 deletions docs/kds/index.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
layout: default
title: KDS
title: Data Structures
permalink: /kds/
fa-icon: fa-tree
children: /kds/
Expand Down Expand Up @@ -94,5 +94,3 @@ assertEquals(listOf(1, 2, 3), mapWhile({ iterator.hasNext() }) { iterator.next()

// And much more!
```

{% include using_with_gradle.md name="kds" %}
4 changes: 1 addition & 3 deletions docs/klock/index.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
layout: default
title: Klock
title: Time
fa-icon: fa-clock
priority: 10
children: /klock/
Expand All @@ -23,5 +23,3 @@ and to provide an API that is powerful, fun and easy to use.
## Pages

{% include toc.html context="/klock/" description=true %}

{% include using_with_gradle.md name="klock" %}
4 changes: 1 addition & 3 deletions docs/klogger/index.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
layout: default
title: "Klogger"
title: "Logger"
fa-icon: fa-bell
priority: 60
---
Expand All @@ -15,8 +15,6 @@ This library provides a simple interface to do logging into suitable outputs lik

{% include toc_include.md %}

{% include using_with_gradle.md name="klogger" %}

## Console

Klogger provides a common way for logging into JavaScript console with fallback to stdout and stderr.
Expand Down
3 changes: 1 addition & 2 deletions docs/kmem/index.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
layout: default
title: Kmem
title: Memory
fa-icon: fa-microchip
priority: 59
---
Expand All @@ -14,7 +14,6 @@ Kmem is bit, array and fast memory utilities library for multiplatform Kotlin 1.
{% include stars.html project="korge" central="com.soywiz.korlibs.kmem/kmem" %}

{% include toc_include.md max_level="3" %}
{% include using_with_gradle.md name="kmem" %}

## arraycopy and arrayfill

Expand Down
4 changes: 1 addition & 3 deletions docs/korau/index.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
layout: default
title: "KorAU"
title: "Audio"
fa-icon: fa-headphones
priority: 70
---
Expand All @@ -15,8 +15,6 @@ It supports playing sounds, creating dynamic audio streams and decoding audio fi

{% include toc_include.md %}

{% include using_with_gradle.md name="korau" %}

## AudioFormat

```kotlin
Expand Down
92 changes: 0 additions & 92 deletions docs/korge/deployment/desktop/index.md

This file was deleted.

2 changes: 1 addition & 1 deletion docs/korge/reference/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ title: Reference
title_prefix: KorGE
fa-icon: fa-book
children: /korge/reference/
priority: 3
priority: 4
always_open: true
---

Expand Down
12 changes: 12 additions & 0 deletions docs/korge/tutorials/2048/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
---
layout: default
title: 2048
title_prefix: KorGE Tutorial
priority: 100
---

* [Writing 2048 game. Step 0 - Introduction](https://blog.korge.org/korge-tutorial-writing-2048-game-step-0/)
* [Writing 2048 game. Step 1 - Views](https://blog.korge.org/korge-tutorial-writing-2048-game-step-1/)
* [Writing 2048 game. Step 2 - State and interaction](https://blog.korge.org/korge-tutorial-writing-2048-game-step-2-controls/)
* [Writing 2048 game. Step 3 - Animation](https://blog.korge.org/korge-tutorial-writing-2048-game-step-3-animation/)
* [Writing 2048 game. Step 4 - Data saving](https://blog.korge.org/korge-tutorial-writing-2048-game-step-4-data-saving/)
Loading

0 comments on commit 80c7b30

Please sign in to comment.