# arindammanidas/personal_desk architecture

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

- Interactive diagram: https://gitdiagram.com/arindammanidas/personal_desk
- Repository: https://github.com/arindammanidas/personal_desk

## Overview

##### Project type and purpose
- From the README (“Personal Desk: A simple windows application for day to day tasks. Wrote this as a college project”) and the file tree (extension .xaml/.vb, a .sln and .vbproj), we see this is a standalone WPF (.NET) desktop application written in VB.NET. It is monolithic, contains multiple windows (Calendar, Journal, Drawing, Notes, Phone, RSS config, Lock, Expense, About), and uses local file-based storage (RTF, XML, TXT, ink files).

##### File structure
- Top-level assemblies:
- PersonalDesk.sln / .vbproj – Visual Studio solution & project.
- App.xaml / App.xaml.vb – WPF application entry point.
- UI:
- MainWindow.xaml(.vb) – dashboard/launcher.
- Individual windows (CalendarWindow, DrawingWindow, JournalWindow, NotesWindow, PhoneWindow, RssConfigWindow, LockWindow, ExpenseWindow presumably) each with .xaml/.vb.
- Data/Storage:
- bin/Debug folder contains runtime artifacts plus sample data files: PDeskNotes.txt, PDeskRSS.txt, PDeskExpense.xml, PDeskDraw.ink, various date-stamped RTF journals.
- Supporting assets:
- Fonts folder, Simple Styles.xaml (resources & styles), PDeskHelp.pdf, User Manual.pdf.
- Build & deployment:
- ClickOnce publishing artifacts under bin/Debug/app.publish.

##### README for additional insights
- Minimal description; no explicit architecture notes. We infer standard WPF code-behind approach with file-based persistence.

a. Main components
1. UI Layer – WPF Windows & XAML resources
2. Application Layer – App.xaml startup & navigation logic
3. Business Logic Layer – code‐behind event handlers & any shared services
4. Data Access Layer – file I/O module reading/writing TXT/RTF/XML/ink files
5. Local Storage – Windows file system (data folder under user profile or app data)
6. .NET Framework – WPF runtime, Expression.Drawing library (see Microsoft.Expression.Drawing.xml)
b. Relationships & interactions
- User interacts with each Window (UI Layer)
- Windows invoke Business Logic to process commands (e.g., save a note, load calendar entries)
- Business Logic calls Data Access to read/write local files
- Data Access reads/writes to local storage (bin/Debug under development, real path under AppData in production)
- App.xaml orchestrates startup, dependency injection (if any), and window navigation
c. Architectural patterns/design principles
- Layered architecture (UI → Application → Business Logic → Data Access → Storage)
- Separation of concerns: XAML for UI, VB code-behind for behavior, files for persistence
- Resource dictionary (Simple Styles.xaml) for consistent theming
- ClickOnce deployment for updates
d. Key technologies & libraries
- WPF (.NET Framework 4.0)
- Visual Basic .NET
- Microsoft.Expression.Drawing for ink/drawing support
- File-based persistence (TXT, RTF, XML, .ink)

##### Detailed capture of essential elements
- Major window as a sub-component under UI Layer
- Resource dictionary (Simple Styles.xaml) linked into UI Layer
- ClickOnce publishing artifacts under a “Deployment” annotation, but keep it outside the runtime boundary
- Microsoft.Expression.Drawing as an external library dependency

## Diagram (Mermaid)

```mermaid
flowchart TB
    %% Actors
    User["User"]:::actor

    %% UI Layer
    subgraph "UI Layer" 
        direction TB
        MainDashboard["Main Dashboard Window"]:::ui
        CalendarModule["Calendar Module"]:::ui
        JournalModule["Journal Module"]:::ui
        DrawingModule["Drawing Module"]:::ui
        NotesModule["Notes Module"]:::ui
        PhoneModule["Phone Module"]:::ui
        RSSModule["RSS Configuration Module"]:::ui
        LockModule["Lock/Security Module"]:::ui
        AboutModule["About Window"]:::ui
        ResourceDict["Resource Dictionary (Simple Styles.xaml)"]:::ui
        Fonts["Fonts Folder"]:::ui
    end

    %% Application Layer
    AppLayer["Application Layer\n(WPF Startup & Navigation)"]:::app

    %% Business Logic Layer
    BizLogic["Business Logic Layer\n(Code‐behind Event Handlers & Services)"]:::logic

    %% Data Access Layer
    DataAccess["Data Access Layer\n(File I/O Operations)"]:::data

    %% Storage
    Storage["Local File System\n(Data Files: TXT, RTF, XML, .ink)"]:::storage

    %% Framework Layer
    Framework[".NET WPF Runtime"]:::framework
    ExprDrawing["Microsoft.Expression.Drawing\n(External Library)"]:::framework

    %% Deployment
    Deployment["Deployment (ClickOnce Artifacts)"]:::deploy

    %% Relationships
    User -->|"Interacts with"| MainDashboard
    MainDashboard --> BizLogic
    CalendarModule --> BizLogic
    JournalModule --> BizLogic
    DrawingModule --> BizLogic
    NotesModule --> BizLogic
    PhoneModule --> BizLogic
    RSSModule --> BizLogic
    LockModule --> BizLogic
    AboutModule --> BizLogic
    ResourceDict --> MainDashboard
    Fonts --> MainDashboard

    AppLayer --> MainDashboard
    AppLayer --> CalendarModule
    AppLayer --> JournalModule
    AppLayer --> DrawingModule
    AppLayer --> NotesModule
    AppLayer --> PhoneModule
    AppLayer --> RSSModule
    AppLayer --> LockModule
    AppLayer --> AboutModule

    BizLogic --> DataAccess
    DataAccess --> Storage
    BizLogic --> Framework
    MainDashboard --> Framework
    CalendarModule --> Framework
    JournalModule --> Framework
    DrawingModule --> ExprDrawing
    DrawingModule --> Framework

    Deployment -.-> AppLayer

    %% Click Events
    click MainDashboard "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/MainWindow.xaml"
    click MainDashboard "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/MainWindow.xaml.vb"
    click CalendarModule "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/CalendarWindow.xaml"
    click CalendarModule "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/CalendarWindow.xaml.vb"
    click JournalModule "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/JournalWindow.xaml"
    click JournalModule "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/JournalWindow.xaml.vb"
    click DrawingModule "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/DrawingWindow.xaml"
    click DrawingModule "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/DrawingWindow.xaml.vb"
    click NotesModule "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/NotesWindow.xaml"
    click NotesModule "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/NotesWindow.xaml.vb"
    click PhoneModule "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/PhoneWindow.xaml"
    click PhoneModule "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/PhoneWindow.xaml.vb"
    click RSSModule "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/RssConfigWindow.xaml"
    click RSSModule "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/RssConfigWindow.xaml.vb"
    click LockModule "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/LOCK.xaml"
    click LockModule "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/LOCK.xaml.vb"
    click LockModule "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/LockWindow.xaml"
    click LockModule "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/LockWindow.xaml.vb"
    click AboutModule "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/aboutWindow.xaml"
    click AboutModule "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/aboutWindow.xaml.vb"
    click AppLayer "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/App.xaml"
    click AppLayer "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/App.xaml.vb"
    click BizLogic "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/My Project/AssemblyInfo.vb"
    click BizLogic "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/PersonalDesk.vbproj"
    click ResourceDict "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/Simple Styles.xaml"
    click Fonts "https://github.com/arindammanidas/personal_desk/tree/master/PersonalDesk/Fonts/"
    click Storage "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/bin/Debug/PDeskNotes.txt"
    click Storage "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/bin/Debug/PDeskRSS.txt"
    click Storage "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/bin/Debug/PDeskExpense.xml"
    click Storage "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/bin/Debug/PDeskDraw.ink"
    click Storage "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/bin/Debug/Friday, May 27, 2011.rtf"
    click ExprDrawing "https://github.com/arindammanidas/personal_desk/blob/master/PersonalDesk/bin/Debug/Microsoft.Expression.Drawing.xml"
    click Deployment "https://github.com/arindammanidas/personal_desk/tree/master/PersonalDesk/bin/Debug/app.publish/"

    %% Styles
    classDef actor fill:#ffffff,stroke:#333,stroke-width:1px
    classDef ui fill:#cce5ff,stroke:#1f78b4,stroke-width:1px
    classDef app fill:#d4edda,stroke:#28a745,stroke-width:1px
    classDef logic fill:#d1ecf1,stroke:#17a2b8,stroke-width:1px
    classDef data fill:#ffe5b4,stroke:#f0ad4e,stroke-width:1px
    classDef storage fill:#e2e3e5,stroke:#6c757d,stroke-width:1px
    classDef framework fill:#f5e1ff,stroke:#6f42c1,stroke-width:1px
    classDef deploy fill:#fff3cd,stroke:#856404,stroke-width:1px
```
