# miraelsink/caesar_cipher architecture

> Architecture diagram of the GitHub repository miraelsink/caesar_cipher, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-10). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/miraelsink/caesar_cipher
- Repository: https://github.com/miraelsink/caesar_cipher

## Overview

Caesar Crypto is a pair of standalone Tkinter desktop applications: users enter text and an integer shift, activate the encrypt or decrypt button, and see the transformed text in the result field. Each application owns its interface, character-shift logic, and button callback; the cipher operates on printable ASCII characters and leaves other characters unchanged. The two scripts are separate entry points, not stages in a shared pipeline. The README also documents executable builds, which are delivery tooling rather than runtime product components. Edges reflect only relationships visible in the excerpts.

Main entry points: [`crypto.py`](https://github.com/miraelsink/caesar_cipher/blob/master/crypto.py) (Encrypt callback), [`decrypto.py`](https://github.com/miraelsink/caesar_cipher/blob/master/decrypto.py) (Decrypt callback)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_apps["Cipher apps"]
  node_encrypt_app["Encrypt app<br/>[crypto.py]"]
  node_decrypt_app["Decrypt app<br/>[decrypto.py]"]
end

subgraph group_interface["Desktop interface"]
  node_encrypt_ui["Encrypt UI<br/>[crypto.py]"]
  node_encrypt_fields["Text and key fields<br/>[crypto.py]"]
  node_encrypt_button["Encrypt button<br/>[crypto.py]"]
  node_encrypt_result["Encrypted result<br/>[crypto.py]"]
  node_decrypt_ui["Decrypt UI<br/>[decrypto.py]"]
  node_decrypt_fields["Text and key fields<br/>[decrypto.py]"]
  node_decrypt_button["Decrypt button<br/>[decrypto.py]"]
  node_decrypt_result["Decrypted result<br/>[decrypto.py]"]
end

subgraph group_cipher["Cipher processing"]
  node_encrypt_callback["Encrypt callback<br/>[crypto.py]"]
  node_encrypt_shift["Forward shift<br/>[crypto.py]"]
  node_decrypt_callback["Decrypt callback<br/>[decrypto.py]"]
  node_decrypt_shift["Reverse shift<br/>[decrypto.py]"]
end

node_user(("User"))

node_user -->|"enters text and key"| node_encrypt_fields
node_user -->|"activates"| node_encrypt_button
node_encrypt_app -->|"creates"| node_encrypt_ui
node_encrypt_button -->|"invokes"| node_encrypt_callback
node_encrypt_callback -->|"reads"| node_encrypt_fields
node_encrypt_callback -->|"applies per character"| node_encrypt_shift
node_encrypt_callback -->|"writes"| node_encrypt_result
node_user -->|"enters text and key"| node_decrypt_fields
node_user -->|"activates"| node_decrypt_button
node_decrypt_app -->|"creates"| node_decrypt_ui
node_decrypt_button -->|"invokes"| node_decrypt_callback
node_decrypt_callback -->|"reads"| node_decrypt_fields
node_decrypt_callback -->|"applies per character"| node_decrypt_shift
node_decrypt_callback -->|"writes"| node_decrypt_result

click node_encrypt_app "https://github.com/miraelsink/caesar_cipher/blob/master/crypto.py"
click node_encrypt_ui "https://github.com/miraelsink/caesar_cipher/blob/master/crypto.py"
click node_encrypt_fields "https://github.com/miraelsink/caesar_cipher/blob/master/crypto.py"
click node_encrypt_button "https://github.com/miraelsink/caesar_cipher/blob/master/crypto.py"
click node_encrypt_callback "https://github.com/miraelsink/caesar_cipher/blob/master/crypto.py"
click node_encrypt_shift "https://github.com/miraelsink/caesar_cipher/blob/master/crypto.py"
click node_encrypt_result "https://github.com/miraelsink/caesar_cipher/blob/master/crypto.py"
click node_decrypt_app "https://github.com/miraelsink/caesar_cipher/blob/master/decrypto.py"
click node_decrypt_ui "https://github.com/miraelsink/caesar_cipher/blob/master/decrypto.py"
click node_decrypt_fields "https://github.com/miraelsink/caesar_cipher/blob/master/decrypto.py"
click node_decrypt_button "https://github.com/miraelsink/caesar_cipher/blob/master/decrypto.py"
click node_decrypt_callback "https://github.com/miraelsink/caesar_cipher/blob/master/decrypto.py"
click node_decrypt_shift "https://github.com/miraelsink/caesar_cipher/blob/master/decrypto.py"
click node_decrypt_result "https://github.com/miraelsink/caesar_cipher/blob/master/decrypto.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_encrypt_app,node_decrypt_app,node_user toneBlue
class node_encrypt_ui,node_encrypt_fields,node_encrypt_button,node_encrypt_result,node_decrypt_ui,node_decrypt_fields,node_decrypt_button,node_decrypt_result toneAmber
class node_encrypt_callback,node_encrypt_shift,node_decrypt_callback,node_decrypt_shift toneMint
```

## Components

### Cipher apps

- [Encrypt app](https://github.com/miraelsink/caesar_cipher/blob/master/crypto.py): `crypto.py`
- [Decrypt app](https://github.com/miraelsink/caesar_cipher/blob/master/decrypto.py): `decrypto.py`

### Desktop interface

- [Encrypt UI](https://github.com/miraelsink/caesar_cipher/blob/master/crypto.py): `crypto.py`
- [Text and key fields](https://github.com/miraelsink/caesar_cipher/blob/master/crypto.py): `crypto.py`
- [Encrypt button](https://github.com/miraelsink/caesar_cipher/blob/master/crypto.py): `crypto.py`
- [Encrypted result](https://github.com/miraelsink/caesar_cipher/blob/master/crypto.py): `crypto.py`
- [Decrypt UI](https://github.com/miraelsink/caesar_cipher/blob/master/decrypto.py): `decrypto.py`
- [Text and key fields](https://github.com/miraelsink/caesar_cipher/blob/master/decrypto.py): `decrypto.py`
- [Decrypt button](https://github.com/miraelsink/caesar_cipher/blob/master/decrypto.py): `decrypto.py`
- [Decrypted result](https://github.com/miraelsink/caesar_cipher/blob/master/decrypto.py): `decrypto.py`

### Cipher processing

- [Encrypt callback](https://github.com/miraelsink/caesar_cipher/blob/master/crypto.py): `crypto.py`
- [Forward shift](https://github.com/miraelsink/caesar_cipher/blob/master/crypto.py): `crypto.py`
- [Decrypt callback](https://github.com/miraelsink/caesar_cipher/blob/master/decrypto.py): `decrypto.py`
- [Reverse shift](https://github.com/miraelsink/caesar_cipher/blob/master/decrypto.py): `decrypto.py`

### Other components

- **User**

## Connections

- User → Text and key fields: enters text and key (evidence: `crypto.py`)
- User → Encrypt button: activates (evidence: `crypto.py`)
- Encrypt app → Encrypt UI: creates (evidence: `crypto.py`)
- Encrypt button → Encrypt callback: invokes (evidence: `crypto.py`)
- Encrypt callback → Text and key fields: reads (evidence: `crypto.py`)
- Encrypt callback → Forward shift: applies per character (evidence: `crypto.py`)
- Encrypt callback → Encrypted result: writes (evidence: `crypto.py`)
- User → Text and key fields: enters text and key (evidence: `decrypto.py`)
- User → Decrypt button: activates (evidence: `decrypto.py`)
- Decrypt app → Decrypt UI: creates (evidence: `decrypto.py`)
- Decrypt button → Decrypt callback: invokes (evidence: `decrypto.py`)
- Decrypt callback → Text and key fields: reads (evidence: `decrypto.py`)
- Decrypt callback → Reverse shift: applies per character (evidence: `decrypto.py`)
- Decrypt callback → Decrypted result: writes (evidence: `decrypto.py`)
