From a2980eddff918d65d0262c2622e8d91296ea3a46 Mon Sep 17 00:00:00 2001
From: Janne Koschinski <janne@kuschku.de>
Date: Thu, 9 Jan 2020 19:34:45 +0100
Subject: [PATCH] Cleanup a bit

---
 docs/assets/application.css                   |   4 +++
 .../images/autocomplete_new_button.png        | Bin
 .../images/autocomplete_new_doubletap.png     | Bin
 .../images/autocomplete_new_prefix.png        | Bin
 docs/{assets => }/images/autocomplete_old.png | Bin
 docs/{assets => }/images/message_init.png     | Bin
 docs/{assets => }/images/message_setup.png    | Bin
 docs/index.md                                 |   8 +++--
 docs/protocol/layers/message.md               |   4 +--
 docs/usage/faq.md                             |  31 ++++++++++++++++++
 docs/usage/upgrade_guide.md                   |   8 ++---
 mkdocs.yml                                    |   1 +
 12 files changed, 48 insertions(+), 8 deletions(-)
 rename docs/{assets => }/images/autocomplete_new_button.png (100%)
 rename docs/{assets => }/images/autocomplete_new_doubletap.png (100%)
 rename docs/{assets => }/images/autocomplete_new_prefix.png (100%)
 rename docs/{assets => }/images/autocomplete_old.png (100%)
 rename docs/{assets => }/images/message_init.png (100%)
 rename docs/{assets => }/images/message_setup.png (100%)
 create mode 100644 docs/usage/faq.md

diff --git a/docs/assets/application.css b/docs/assets/application.css
index fa71a65..62a59bf 100644
--- a/docs/assets/application.css
+++ b/docs/assets/application.css
@@ -5,3 +5,7 @@
   font-weight: bold;
   font-family: "Roboto Mono", "Courier New", Courier, monospace;
 }
+
+img[src*="#half-width"] {
+  max-width: 50%;
+}
\ No newline at end of file
diff --git a/docs/assets/images/autocomplete_new_button.png b/docs/images/autocomplete_new_button.png
similarity index 100%
rename from docs/assets/images/autocomplete_new_button.png
rename to docs/images/autocomplete_new_button.png
diff --git a/docs/assets/images/autocomplete_new_doubletap.png b/docs/images/autocomplete_new_doubletap.png
similarity index 100%
rename from docs/assets/images/autocomplete_new_doubletap.png
rename to docs/images/autocomplete_new_doubletap.png
diff --git a/docs/assets/images/autocomplete_new_prefix.png b/docs/images/autocomplete_new_prefix.png
similarity index 100%
rename from docs/assets/images/autocomplete_new_prefix.png
rename to docs/images/autocomplete_new_prefix.png
diff --git a/docs/assets/images/autocomplete_old.png b/docs/images/autocomplete_old.png
similarity index 100%
rename from docs/assets/images/autocomplete_old.png
rename to docs/images/autocomplete_old.png
diff --git a/docs/assets/images/message_init.png b/docs/images/message_init.png
similarity index 100%
rename from docs/assets/images/message_init.png
rename to docs/images/message_init.png
diff --git a/docs/assets/images/message_setup.png b/docs/images/message_setup.png
similarity index 100%
rename from docs/assets/images/message_setup.png
rename to docs/images/message_setup.png
diff --git a/docs/index.md b/docs/index.md
index 59f3cd3..95597c7 100644
--- a/docs/index.md
+++ b/docs/index.md
@@ -2,5 +2,9 @@
 
 Welcome to the Quasseldroid documentation!
 
-!!! danger
-    The documentation is still being worked on.
\ No newline at end of file
+!!! warning
+    This documentation is still being worked on. Most of it is already ready,
+    but a lot is still missing.
+
+This documentation is split into two parts — the [Usage](usage/faq.md) and
+[Developer](protocol/overview.md) sections.
\ No newline at end of file
diff --git a/docs/protocol/layers/message.md b/docs/protocol/layers/message.md
index 61e0c26..cfc9dde 100644
--- a/docs/protocol/layers/message.md
+++ b/docs/protocol/layers/message.md
@@ -13,7 +13,7 @@ It starts off in `HANDSHAKE` state.
 In this state, messages are encoded/decoded according to the
 [Handshake Messages](../serialization/handshake_messages.md) specification.
 
-[![Init Diagram](../../assets/images/message_init.png)](../../assets/images/message_init.png)
+[![Init Diagram](../../images/message_init.png)](../../images/message_init.png)
 
 Client and core exchange messages according to the diagram described above, when
 a ClientLoginAck and SessionInit have been received, the state advances into
@@ -21,7 +21,7 @@ a ClientLoginAck and SessionInit have been received, the state advances into
 
 ### Core Setup
 
-[![Core Setup Diagram](../../assets/images/message_setup.png)](../../assets/images/message_setup.png)
+[![Core Setup Diagram](../../images/message_setup.png)](../../images/message_setup.png)
 
 When the client receives a CoreInitAck message, with "Configured" set to "False", it will display to the user a list, allowing them to choose a StorageBackend from the ones present in CoreInitAck’s "StorageBackends" attribute.
 
diff --git a/docs/usage/faq.md b/docs/usage/faq.md
new file mode 100644
index 0000000..3361e55
--- /dev/null
+++ b/docs/usage/faq.md
@@ -0,0 +1,31 @@
+# FAQ
+
+## What is a quassel core? Why do I need one to use Quasseldroid?
+
+A quassel core is a server which connects to IRC servers, and ensures you are
+always online — storing logs of the messages in the channel, etc.
+
+Quasseldroid connects to the core instead of connecting directly to the IRC
+server, so if you turn your phone off, or your phone’s internet connection
+drops, your unread messages are still saved, and Quasseldroid can show them
+whenever your phone turns on again.
+
+Without the quassel core, you’d miss any messages on IRC that were sent while
+you weren’t using Quasseldroid.
+
+## Where is autocomplete?
+
+Quasseldroid supports many options for nick autocompletion:
+
+1. **Prefix Autocomplete**  
+  ![New Autocomplete Example With Prefix](../images/autocomplete_new_prefix.png#half-width)  
+  When typing an @ or # with the name of a nick or channel afterwards, Quasseldroid automatically recommends
+  You can also configure this to always autocomplete even without prefix
+
+2. **Double-Tap to Autocomplete**  
+  ![New Autocomplete Example With Doubletap](../images/autocomplete_new_doubletap.png#half-width)  
+  When typing a name, you can double-tap the input box to autocomplete the name
+
+3. **Autocomplete Button**  
+  ![New Autocomplete Example With Button](../images/autocomplete_new_button.png#half-width)  
+  Of course, the good old autocomplete button can be re-enabled again, too.
diff --git a/docs/usage/upgrade_guide.md b/docs/usage/upgrade_guide.md
index e2a89c0..99e8a5f 100644
--- a/docs/usage/upgrade_guide.md
+++ b/docs/usage/upgrade_guide.md
@@ -6,21 +6,21 @@ This guide is intended to help users upgrading from older versions with the rece
 
 In the old versions, autocomplete was only possible through the use of the autocomplete button in the input line.
 
-<img src="../../assets/images/autocomplete_old.png" alt="Old Autocomplete Example" style="max-width: 50%">
+![Old Autocomplete Example](../images/autocomplete_old.png#half-width)
 
 Nowadays, there are many possible solutions for autocomplete:
 
 1. **Prefix Autocomplete**  
-  <img src="../../assets/images/autocomplete_new_prefix.png" alt="New Autocomplete Example With Prefix" style="max-width: 50%">  
+  ![New Autocomplete Example With Prefix](../images/autocomplete_new_prefix.png#half-width)  
   When typing an @ or # with the name of a nick or channel afterwards, Quasseldroid automatically recommends
   You can also configure this to always autocomplete even without prefix
 
 2. **Double-Tap to Autocomplete**  
-  <img src="../../assets/images/autocomplete_new_doubletap.png" alt="New Autocomplete Example With Doubletap" style="max-width: 50%">  
+  ![New Autocomplete Example With Doubletap](../images/autocomplete_new_doubletap.png#half-width)  
   When typing a name, you can double-tap the input box to autocomplete the name
 
 3. **Autocomplete Button**  
-  <img src="../../assets/images/autocomplete_new_button.png" alt="New Autocomplete Example With Button" style="max-width: 50%">  
+  ![New Autocomplete Example With Button](../images/autocomplete_new_button.png#half-width)  
   Of course, the good old autocomplete button can be re-enabled again, too.
 
 ## Avatars
diff --git a/mkdocs.yml b/mkdocs.yml
index ba664bc..f603e7a 100644
--- a/mkdocs.yml
+++ b/mkdocs.yml
@@ -10,6 +10,7 @@ copyright: 'Copyright &copy; 2020 Janne Koschinski'
 nav:
   - "Overview": index.md
   - "Usage":
+    - "FAQ": usage/faq.md
     - "Upgrade Guide": usage/upgrade_guide.md
   - "Protocol":
     - "Overview": protocol/overview.md
-- 
GitLab