# The CrossFly big picture

> The mental model before the code — Java+OpenGL, paint thread, everything is a Component, no imposed architecture.

Source: https://crossfly.dev/docs/learn/big-picture — CrossFly documentation. Full docs as one file: https://crossfly.dev/llms-full.txt

# 1. The CrossFly big picture

> **What you'll learn:** the mental model that makes every upcoming choice in the course make
> sense. **Prerequisites:** having run the [Hello World](/docs/get-started/quickstart).

Throughout this course we build **a single app** — a to-do list with persistence — that grows
with each page, from a static screen to a tested, responsive app ready to package.

## The ideas that hold everything together
- **Java + OpenGL.** CrossFly is a Java app that draws via the GPU (OpenGL/WebGL). The look is
  **identical** across every platform — there are no native widgets.
- **Single paint thread.** All the UI and rendering happen on a single thread. Heavy work goes to a
  background thread and comes back with `Component.onUI(...)`.
- **Render on demand.** The screen only redraws when you call `repaint()` — it saves battery.
- **Everything is a `Component`.** There's no "widget vs container" hierarchy: any `Component` becomes a container
  when it receives a `Layout`.
- **No imposed architecture.** There's no reactive binding and no dependency injection — you **mutate**
  objects and update the UI by hand.

## The map of the pieces
| Piece | Role |
|---|---|
| `Main` | the bootstrap (libGDX's `ApplicationListener`) |
| `Window` | a screen (a full-screen `Component` on the navigation stack) |
| `Component` | the unit of UI — everything derives from it |
| `Layout` | measures and positions a container's children |
| `Styles`/`Skin`/`ColorScheme` | the look (shape + colors per theme) |

## Recap
CrossFly is **imperative and object-oriented**: create objects once, keep references, mutate,
`repaint()`. Threading is explicit; the look is your GPU drawing, the same everywhere.

## Next steps
→ [Windows and navigation](/docs/learn/windows-and-navigation)

## See also
- Concepts: [The layered architecture](/docs/concepts/architecture) · [Everything is a Component](/docs/concepts/everything-is-a-component)
