gui

package
v0.3.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 17, 2025 License: MIT Imports: 39 Imported by: 0

Documentation

Overview

Package gui provides the graphical user interface for the FIRE benchmarking tool.

Package gui provides the graphical user interface for the FIRE benchmarking tool.

Package gui provides the graphical user interface for the FIRE benchmarking tool.

Index

Constants

This section is empty.

Variables

View Source
var (
	ColorCPUUsage    = color.RGBA{0x00, 0x7a, 0xcc, 0xff} // Blue
	ColorMemoryUsage = color.RGBA{0x00, 0xcc, 0x44, 0xff} // Green
	ColorGPUUsage    = color.RGBA{0xff, 0x66, 0x00, 0xff} // Orange
	ColorTemperature = color.RGBA{0xff, 0xcc, 0x00, 0xff} // Yellow
	ColorPower       = color.RGBA{0x00, 0xcc, 0x88, 0xff} // Teal
	ColorVoltage     = color.RGBA{0xcc, 0x00, 0xcc, 0xff} // Purple
	ColorFrequency   = color.RGBA{0x00, 0xcc, 0xcc, 0xff} // Cyan

	// Dynamic status colors
	ColorGood     = color.RGBA{0x00, 0xcc, 0x44, 0xff} // Green - all good
	ColorWarning  = color.RGBA{0xff, 0xcc, 0x00, 0xff} // Yellow - warning
	ColorCaution  = color.RGBA{0xff, 0x66, 0x00, 0xff} // Orange - caution
	ColorCritical = color.RGBA{0xff, 0x00, 0x00, 0xff} // Red - critical/danger

	// UI colors
	ColorSunset = color.RGBA{0xff, 0x7f, 0x50, 0xff} // Coral/sunset - subtle selection
	ColorEmber  = color.RGBA{0xff, 0x6b, 0x6b, 0xff} // Soft ember red
)

Metric colors for bars

View Source
var ColorCardBackground = color.RGBA{0x22, 0x22, 0x22, 0xff} // #222222

ColorCardBackground is the background color for cards in the UI.

Functions

func AddTooltip

func AddTooltip(w fyne.CanvasObject, tooltip string, window fyne.Window) fyne.CanvasObject

AddTooltip wraps a widget with a tooltip

func CardBackgroundColor

func CardBackgroundColor() color.Color

CardBackgroundColor returns the background color for cards

func ChartGridColor

func ChartGridColor() color.Color

ChartGridColor returns the color for chart gridlines

func ChartLineColor

func ChartLineColor() color.Color

ChartLineColor returns the primary color for chart lines

func CheckSingleInstance

func CheckSingleInstance() bool

CheckSingleInstance ensures only one instance of the application is running Returns true if this is the first instance, false if another instance is already running

func ClearLogs

func ClearLogs()

ClearLogs clears or archives old log files

func CreateLockFile

func CreateLockFile() (*os.File, error)

CreateLockFile creates a lock file to prevent multiple instances

func CreateMetricGrid

func CreateMetricGrid(metrics map[string]*MetricDisplay) *fyne.Container

CreateMetricGrid creates a grid of metrics for a summary card

func DebugCheckpoint

func DebugCheckpoint(name string)

DebugCheckpoint logs a checkpoint

func DebugLog

func DebugLog(level, format string, args ...interface{})

DebugLog logs debug messages

func DebugStorageInfo

func DebugStorageInfo()

DebugStorageInfo prints detailed debug information about storage detection

func ErrorColor

func ErrorColor() color.Color

ErrorColor returns the error indicator color

func FormatBIOSDate

func FormatBIOSDate(dateStr string) string

FormatBIOSDate formats a BIOS date string to a more readable format

func FormatBytes

func FormatBytes(bytes uint64) string

FormatBytes formats bytes to human readable string

func FormatGPUMemory

func FormatGPUMemory(used, total uint64) string

FormatGPUMemory formats GPU memory usage as a human-readable string

func FormatGPUPower

func FormatGPUPower(draw, limit float64) string

FormatGPUPower formats GPU power usage

func FormatMemorySize

func FormatMemorySize(bytes uint64) string

FormatMemorySize formats bytes to human readable format

func GetAdminRequiredFeatures

func GetAdminRequiredFeatures() []string

GetAdminRequiredFeatures returns a list of features that require admin privileges

func GetCPUIcon

func GetCPUIcon() fyne.Resource

GetCPUIcon returns the icon resource for CPU-related UI elements.

func GetDriveBusType

func GetDriveBusType(_ string) (string, error)

GetDriveBusType stub for non-Windows platforms

func GetDriveBusTypeEnhanced

func GetDriveBusTypeEnhanced(_ string) (string, error)

GetDriveBusTypeEnhanced uses platform-specific methods to detect bus type (stub for non-Windows)

func GetFanIcon

func GetFanIcon() fyne.Resource

GetFanIcon returns the icon resource for fan/cooling UI elements.

func GetGPUIcon

func GetGPUIcon() fyne.Resource

GetGPUIcon returns the icon resource for GPU-related UI elements.

func GetGaugeIcon

func GetGaugeIcon() fyne.Resource

GetGaugeIcon returns the icon resource for gauge/dashboard UI elements.

func GetLogPath

func GetLogPath(filename string) string

GetLogPath returns the path to a log file

func GetManufacturerName

func GetManufacturerName(id uint16) string

GetManufacturerName converts JEDEC manufacturer ID to name (stub)

func GetMemoryIcon

func GetMemoryIcon() fyne.Resource

GetMemoryIcon returns the icon resource for memory-related UI elements.

func GetNetworkIcon

func GetNetworkIcon() fyne.Resource

GetNetworkIcon returns the icon resource for network-related UI elements.

func GetPowerIcon

func GetPowerIcon() fyne.Resource

GetPowerIcon returns the icon resource for power-related UI elements.

func GetReportIcon

func GetReportIcon() fyne.Resource

GetReportIcon returns the icon resource for report-related UI elements.

func GetSettingsIcon

func GetSettingsIcon() fyne.Resource

GetSettingsIcon returns the icon resource for settings UI elements.

func GetStorageIcon

func GetStorageIcon() fyne.Resource

GetStorageIcon returns the icon resource for storage-related UI elements.

func GetSupportIcon

func GetSupportIcon() fyne.Resource

GetSupportIcon returns the icon resource for support/help UI elements.

func GetSystemIcon

func GetSystemIcon() fyne.Resource

GetSystemIcon returns the icon resource for system-related UI elements.

func GetTestIcon

func GetTestIcon() fyne.Resource

GetTestIcon returns the icon resource for test-related UI elements.

func GetWindowsDriveModelsV2

func GetWindowsDriveModelsV2() map[string]DriveModel

GetWindowsDriveModelsV2 stub for non-Windows platforms

func IsRunningAsAdmin

func IsRunningAsAdmin() bool

IsRunningAsAdmin checks if the current process is running with administrator privileges On non-Windows systems, this returns true as admin checks are Windows-specific

func LoadIconFromFile

func LoadIconFromFile(_ string) fyne.Resource

LoadIconFromFile loads an icon from the file system (deprecated - use SVG)

func LoadIconFromPath

func LoadIconFromPath(fullPath string) fyne.Resource

LoadIconFromPath loads an icon from a full path

func LoadSVGIcon

func LoadSVGIcon(filename string) fyne.Resource

LoadSVGIcon loads an SVG icon from the svg directory

func RemoveLockFile

func RemoveLockFile(lockFile *os.File)

RemoveLockFile removes the lock file

func StartDebugServer

func StartDebugServer(gui *FireGUI, port int)

StartDebugServer starts a debug HTTP server on the specified port

func SuccessColor

func SuccessColor() color.Color

SuccessColor returns the success indicator color

func WarningColor

func WarningColor() color.Color

WarningColor returns the warning indicator color

Types

type AIInsights

type AIInsights struct {
	// contains filtered or unexported fields
}

AIInsights represents the AI insights view

func NewAIInsights

func NewAIInsights() *AIInsights

NewAIInsights creates a new AI insights view

func (*AIInsights) Content

func (a *AIInsights) Content() fyne.CanvasObject

Content returns the AI insights content

type BIOSInfo

type BIOSInfo struct {
	Vendor      string
	Version     string
	ReleaseDate string
}

BIOSInfo contains BIOS information

type CPUInfo

type CPUInfo struct {
	Model         string
	Vendor        string
	Family        string
	PhysicalCores int
	LogicalCores  int
	MaxFreqMHz    float64
}

CPUInfo contains CPU information

type Certificates

type Certificates struct {
	// contains filtered or unexported fields
}

Certificates represents the certificate management view

func NewCertificates

func NewCertificates(dbPath string) *Certificates

NewCertificates creates a new certificates view

func (*Certificates) Content

func (c *Certificates) Content() fyne.CanvasObject

Content returns the certificates content

func (*Certificates) SetWindow

func (c *Certificates) SetWindow(w fyne.Window)

SetWindow sets the parent window

type ChipsetInfo

type ChipsetInfo struct {
	Vendor string
	Model  string
}

ChipsetInfo contains chipset information

func GetChipsetInfo

func GetChipsetInfo() ChipsetInfo

GetChipsetInfo gets chipset information

type Compare

type Compare struct {
	// contains filtered or unexported fields
}

Compare represents the run comparison view

func NewCompare

func NewCompare(dbPath string) *Compare

NewCompare creates a new compare view

func (*Compare) Content

func (c *Compare) Content() fyne.CanvasObject

Content returns the compare content

func (*Compare) Refresh

func (c *Compare) Refresh()

Refresh refreshes the compare view

type Component

type Component struct {
	Type    string // CPU, Memory, GPU, Storage, Motherboard
	Name    string
	Icon    string
	Details map[string]string  // Static details (model, serial, etc.)
	Metrics map[string]float64 // Dynamic metrics (temp, usage, etc.) - moved to details dialog
	Index   int                // Component index for lookups
}

Component represents a hardware component

type Dashboard

type Dashboard struct {
	// contains filtered or unexported fields
}

Dashboard represents the F.I.R.E. System Monitor dashboard

func CreateDashboard added in v0.3.0

func CreateDashboard(cache *StaticCache) *Dashboard

CreateDashboard creates a F.I.R.E. System Monitor dashboard Pass cache as nil to have the dashboard load its own data

func (*Dashboard) Content

func (d *Dashboard) Content() fyne.CanvasObject

Content returns the dashboard content

func (*Dashboard) RefreshComponentList

func (d *Dashboard) RefreshComponentList()

RefreshComponentList safely refreshes the component list from any goroutine

func (*Dashboard) SetWindow

func (d *Dashboard) SetWindow(w fyne.Window)

SetWindow sets the window reference for dialog display

func (*Dashboard) ShowComponentDetails

func (d *Dashboard) ShowComponentDetails(comp *Component)

ShowComponentDetails shows a dialog with detailed dynamic metrics for a component

func (*Dashboard) ShowMemoryDetails

func (d *Dashboard) ShowMemoryDetails(_ *MemoryModule)

ShowMemoryDetails shows the memory details page for a specific module

func (*Dashboard) ShowStorageDetails

func (d *Dashboard) ShowStorageDetails(storage *StorageInfo)

ShowStorageDetails displays detailed storage information including full SMART data

func (*Dashboard) Start

func (d *Dashboard) Start()

Start begins monitoring

func (*Dashboard) Stop

func (d *Dashboard) Stop()

Stop stops monitoring

func (*Dashboard) SummaryStrip

func (d *Dashboard) SummaryStrip() fyne.CanvasObject

SummaryStrip returns the summary strip

func (*Dashboard) UpdateMetrics

func (d *Dashboard) UpdateMetrics()

UpdateMetrics updates all metrics (public method)

type DebugServer

type DebugServer struct {
	// contains filtered or unexported fields
}

DebugServer provides a backdoor HTTP server for debugging

var GlobalDebugServer *DebugServer

GlobalDebugServer is the global debug server instance

func NewDebugServer

func NewDebugServer(port int) *DebugServer

NewDebugServer creates a new debug server

func (*DebugServer) RegisterCallback

func (ds *DebugServer) RegisterCallback(name string, fn func())

RegisterCallback registers a callback function

func (*DebugServer) SetGUI

func (ds *DebugServer) SetGUI(gui *FireGUI)

SetGUI sets the GUI instance

func (*DebugServer) Start

func (ds *DebugServer) Start()

Start starts the debug server

type DriveModel

type DriveModel struct {
	Model     string
	Vendor    string
	Serial    string
	Firmware  string
	Interface string // SATA, NVMe, USB, etc.
	MediaType string // SSD, HDD
}

DriveModel holds drive identification info

type EnhancedLineChart

type EnhancedLineChart struct {
	widget.BaseWidget
	// contains filtered or unexported fields
}

EnhancedLineChart is an improved line chart with gridlines, data points, and min/max tracking

func NewEnhancedLineChart

func NewEnhancedLineChart(title string, capacity int, maxValue float64) *EnhancedLineChart

NewEnhancedLineChart creates a new enhanced line chart

func (*EnhancedLineChart) AddValue

func (c *EnhancedLineChart) AddValue(value float64)

AddValue adds a value to the chart

func (*EnhancedLineChart) CreateRenderer

func (c *EnhancedLineChart) CreateRenderer() fyne.WidgetRenderer

CreateRenderer creates the chart renderer

func (*EnhancedLineChart) GetMinMax

func (c *EnhancedLineChart) GetMinMax() (minVal, maxVal float64)

GetMinMax returns the minimum and maximum values seen

func (*EnhancedLineChart) MinSize

func (c *EnhancedLineChart) MinSize() fyne.Size

MinSize returns the minimum size

func (*EnhancedLineChart) SetShowDataPoints

func (c *EnhancedLineChart) SetShowDataPoints(show bool)

SetShowDataPoints enables/disables data point markers

func (*EnhancedLineChart) SetShowGrid

func (c *EnhancedLineChart) SetShowGrid(show bool)

SetShowGrid enables/disables grid lines

type FanInfo

type FanInfo struct {
	Name  string
	Speed int    // RPM
	Type  string // CPU, GPU, Case
}

FanInfo contains information about a system fan

func GetFanInfo

func GetFanInfo() ([]FanInfo, error)

GetFanInfo returns information about system fans

type FireDarkTheme

type FireDarkTheme struct{}

FireDarkTheme implements a dark theme for F.I.R.E. System Monitor

func (FireDarkTheme) Color

func (m FireDarkTheme) Color(name fyne.ThemeColorName, variant fyne.ThemeVariant) color.Color

Color returns the color for the given theme color name.

func (FireDarkTheme) Font

func (m FireDarkTheme) Font(style fyne.TextStyle) fyne.Resource

Font returns the font resource for the given text style.

func (FireDarkTheme) Icon

Icon returns the icon resource for the given theme icon name.

func (FireDarkTheme) Size

func (m FireDarkTheme) Size(name fyne.ThemeSizeName) float32

Size returns the size for the given theme size name.

type FireGUI

type FireGUI struct {
	// contains filtered or unexported fields
}

FireGUI represents the main GUI application

func CreateFireGUI added in v0.3.0

func CreateFireGUI(app fyne.App, cache *StaticCache) *FireGUI

CreateFireGUI creates a F.I.R.E. GUI instance Pass cache as nil to have the GUI load its own data

func (*FireGUI) Content added in v0.3.0

func (g *FireGUI) Content() fyne.CanvasObject

Content returns the main content of the GUI

func (*FireGUI) GetDashboard

func (g *FireGUI) GetDashboard() *Dashboard

GetDashboard returns the dashboard instance

func (*FireGUI) Navigation added in v0.3.0

func (g *FireGUI) Navigation() *NavigationSidebar

Navigation returns the navigation sidebar

func (*FireGUI) ShowAndRun

func (g *FireGUI) ShowAndRun()

ShowAndRun displays the window and runs the application

type FireProgressBar added in v0.3.0

type FireProgressBar struct {
	widget.ProgressBar
}

FireProgressBar is a custom progress bar with gradient from blue to fire red

func CreateLoadingOverlay added in v0.3.0

func CreateLoadingOverlay() (fyne.CanvasObject, *widget.RichText, *FireProgressBar)

CreateLoadingOverlay creates a loading screen overlay

func NewFireProgressBar added in v0.3.0

func NewFireProgressBar() *FireProgressBar

NewFireProgressBar creates a progress bar with fire gradient

func (*FireProgressBar) CreateRenderer added in v0.3.0

func (p *FireProgressBar) CreateRenderer() fyne.WidgetRenderer

CreateRenderer creates a custom renderer for the fire progress bar

type FireTheme

type FireTheme struct{}

FireTheme is a custom dark theme for F.I.R.E. with fire-inspired colors

func (FireTheme) Color

Color returns the color for the specified theme color name

func (FireTheme) Font

func (t FireTheme) Font(style fyne.TextStyle) fyne.Resource

Font returns the font resource for the specified text style

func (FireTheme) Icon

func (t FireTheme) Icon(name fyne.ThemeIconName) fyne.Resource

Icon returns the icon resource for the specified icon name

func (FireTheme) Size

func (t FireTheme) Size(name fyne.ThemeSizeName) float32

Size returns the size value for the specified size name

type GPUInfo

type GPUInfo struct {
	Vendor      string  // NVIDIA, AMD, Intel
	Name        string  // Model name
	Index       int     // GPU index
	Temperature float64 // Celsius
	MemoryUsed  uint64  // Bytes
	MemoryTotal uint64  // Bytes
	Utilization float64 // Percentage 0-100
	PowerDraw   float64 // Watts
	PowerLimit  float64 // Watts
	FanSpeed    float64 // Percentage 0-100
}

GPUInfo holds GPU information

func GetGPUInfo

func GetGPUInfo() ([]GPUInfo, error)

GetGPUInfo returns information about all available GPUs

type History

type History struct {
	// contains filtered or unexported fields
}

History represents the test history view

func NewHistory

func NewHistory(dbPath string) *History

NewHistory creates a new history view

func (*History) Content

func (h *History) Content() fyne.CanvasObject

Content returns the history content

func (*History) Refresh

func (h *History) Refresh()

Refresh refreshes the history

type HostInfo

type HostInfo struct {
	Hostname             string
	Platform             string
	PlatformFamily       string
	PlatformVersion      string
	KernelVersion        string
	OS                   string
	Architecture         string
	VirtualizationSystem string
	VirtualizationRole   string
	IsWSL                bool
}

HostInfo contains host/OS information

type MemoryDetailsPage

type MemoryDetailsPage struct {
	// contains filtered or unexported fields
}

MemoryDetailsPage shows detailed memory information including SPD data

func NewMemoryDetailsPage

func NewMemoryDetailsPage(window fyne.Window) *MemoryDetailsPage

NewMemoryDetailsPage creates a new memory details page

func (*MemoryDetailsPage) CreateContent

func (p *MemoryDetailsPage) CreateContent() fyne.CanvasObject

CreateContent creates the memory details page content

type MemoryInfo

type MemoryInfo struct {
	TotalGB     float64
	AvailableGB float64
	UsedGB      float64
	UsedPercent float64
	HostTotalGB float64 // For WSL, this is Windows host memory
}

MemoryInfo contains memory information

type MemoryModule

type MemoryModule struct {
	// Basic identification
	Row       int    // Row number (1, 2, ...)
	Slot      string // e.g. "P0 CHANNEL A/DIMM 1"
	BankLabel string // e.g. "P0 CHANNEL A"
	Number    string // Same as Row as string
	Name      string // Full descriptive name

	// Memory specifications
	Size       uint64  // Size in bytes
	SizeGB     float64 // Size in GB
	Speed      uint32  // Configured speed in MHz
	Type       string  // e.g. "DDR5 SDRAM"
	FormFactor string  // e.g. "DIMM"

	// Frequency and timing
	BaseFrequency float64 // Base frequency in MHz (half of data rate)
	DataRate      int     // Data rate in MT/s (e.g. 6000)
	PCRating      int     // PC rating (e.g. 48000 for PC5-48000)

	// Manufacturer information
	Manufacturer     string // Module vendor (e.g. "G.Skill")
	ChipManufacturer string // Die vendor (e.g. "SK Hynix")
	PartNumber       string // Part number
	SerialNumber     string // Serial number (hex)

	// Raw data for future use
	SMBIOSType int // Raw SMBIOS memory type code
}

MemoryModule represents a single RAM module with CPU-Z style details

func GetMemoryModules

func GetMemoryModules() ([]MemoryModule, error)

GetMemoryModules returns individual memory modules

func ReadMemoryModulesWithSPD

func ReadMemoryModulesWithSPD() ([]MemoryModule, error)

ReadMemoryModulesWithSPD enhances memory module information with SPD data (stub)

type MetricBar

type MetricBar struct {
	widget.BaseWidget
	// contains filtered or unexported fields
}

MetricBar displays a metric with both bar and text

func NewMetricBar

func NewMetricBar(label string, barColor color.Color, showBar bool) *MetricBar

NewMetricBar creates a new metric bar display

func (*MetricBar) CreateRenderer

func (m *MetricBar) CreateRenderer() fyne.WidgetRenderer

CreateRenderer creates the widget renderer

func (*MetricBar) MouseIn

func (m *MetricBar) MouseIn(event *desktop.MouseEvent)

MouseIn is called when the mouse enters the widget

func (*MetricBar) MouseMoved

func (m *MetricBar) MouseMoved(_ *desktop.MouseEvent)

MouseMoved is called when the mouse moves within the widget

func (*MetricBar) MouseOut

func (m *MetricBar) MouseOut()

MouseOut is called when the mouse leaves the widget

func (*MetricBar) SetHistory

func (m *MetricBar) SetHistory(minVal, maxVal, avg float64)

SetHistory updates the historical data for tooltips

func (*MetricBar) SetMax

func (m *MetricBar) SetMax(maxValue float64)

SetMax sets the maximum value for the bar

func (*MetricBar) SetValue

func (m *MetricBar) SetValue(value float64, unit string, altValue float64, altUnit string)

SetValue updates the metric value

type MetricData

type MetricData struct {
	// CPU specific metrics
	CPUDieTemp      float64 // CPU Die (average) temperature
	CPUVoltage      float64 // Core 0 VID
	CPUPackagePower float64 // CPU Package Power
	CPUUsage        float64 // Total CPU Usage
	CPUClock        float64 // Core 0 T0 Effective Clock

	// Historical data for tooltips
	CPUDieTempMin float64
	CPUDieTempMax float64
	CPUDieTempAvg float64

	CPUPowerMin float64
	CPUPowerMax float64
	CPUPowerAvg float64

	CPUUsageMin float64
	CPUUsageMax float64
	CPUUsageAvg float64

	CPUClockMin float64
	CPUClockMax float64
	CPUClockAvg float64

	// Memory metrics
	MemUsage   float64
	MemUsedGB  float64
	MemAvailGB float64
	MemTemp    float64

	// GPU metrics
	GPUUsage    float64
	GPUTemp     float64
	GPUPower    float64
	GPUMemUsage float64
	GPUClock    float64
	GPUVoltage  float64
}

MetricData holds the collected metric data

type MetricDisplay

type MetricDisplay struct {
	widget.BaseWidget
	// contains filtered or unexported fields
}

MetricDisplay shows a metric with its value in both standard and metric units

func NewMetricDisplay

func NewMetricDisplay(label string, labelColor, valueColor color.Color) *MetricDisplay

NewMetricDisplay creates a new metric display

func (*MetricDisplay) CreateRenderer

func (m *MetricDisplay) CreateRenderer() fyne.WidgetRenderer

CreateRenderer creates the widget renderer

func (*MetricDisplay) SetValue

func (m *MetricDisplay) SetValue(value float64, unit string, altValue float64, altUnit string)

SetValue updates the metric value with optional alternative unit

type MetricHistory

type MetricHistory struct {
	// contains filtered or unexported fields
}

MetricHistory tracks historical values for a metric

func NewMetricHistory

func NewMetricHistory() *MetricHistory

NewMetricHistory creates a new metric history tracker.

func (*MetricHistory) Add

func (m *MetricHistory) Add(value float64)

Add adds a new value to the metric history.

func (*MetricHistory) GetStats

func (m *MetricHistory) GetStats() (minVal, maxVal, avgVal float64)

GetStats returns the minimum, maximum, and average values from the history.

type MotherboardFeatures

type MotherboardFeatures struct {
	MemorySlots int
	MaxMemory   uint64
	PCIeSlots   int
	M2Slots     int
	SATAPorts   int
	USBPorts    map[string]int // Type -> Count
	FormFactor  string
}

MotherboardFeatures contains motherboard feature information

func GetMotherboardFeatures

func GetMotherboardFeatures() MotherboardFeatures

GetMotherboardFeatures gets detailed motherboard features

type MotherboardInfo

type MotherboardInfo struct {
	Manufacturer string
	Model        string
	Version      string
	SerialNumber string
	BIOS         BIOSInfo
	Features     MotherboardFeatures
	ChipsetInfo  ChipsetInfo
}

MotherboardInfo contains motherboard information

func GetMotherboardInfo

func GetMotherboardInfo() (*MotherboardInfo, error)

GetMotherboardInfo retrieves motherboard information

type NavigationButton struct {
	widget.BaseWidget
	// contains filtered or unexported fields
}

NavigationButton represents a button in the vertical navigation

func NewNavigationButton

func NewNavigationButton(label string, icon fyne.Resource, onTapped func()) *NavigationButton

NewNavigationButton creates a new navigation button

func (n *NavigationButton) CreateRenderer() fyne.WidgetRenderer

CreateRenderer creates the renderer for the navigation button

func (n *NavigationButton) MouseIn(*desktop.MouseEvent)

MouseIn handles mouse enter events

func (n *NavigationButton) MouseMoved(*desktop.MouseEvent)

MouseMoved handles mouse move events

func (n *NavigationButton) MouseOut()

MouseOut handles mouse leave events

func (n *NavigationButton) SetCollapsed(collapsed bool)

SetCollapsed updates the collapsed state

func (n *NavigationButton) SetSelected(selected bool)

SetSelected updates the selected state

func (n *NavigationButton) Tapped(*fyne.PointEvent)

Tapped handles tap events

type NavigationSidebar struct {
	// contains filtered or unexported fields
}

NavigationSidebar creates the vertical navigation sidebar

func NewNavigationSidebar

func NewNavigationSidebar() *NavigationSidebar

NewNavigationSidebar creates a new navigation sidebar

func (n *NavigationSidebar) CreateLayout() fyne.CanvasObject

CreateLayout creates the main layout with sidebar and content

func (n *NavigationSidebar) SetHistory(content fyne.CanvasObject)

SetHistory sets the history page

func (n *NavigationSidebar) SetReports(content fyne.CanvasObject)

SetReports sets the reports page

func (n *NavigationSidebar) SetSettings(content fyne.CanvasObject)

SetSettings sets the settings page

func (n *NavigationSidebar) SetSystemInfo(content fyne.CanvasObject)

SetSystemInfo sets the system info page

func (n *NavigationSidebar) SetTests(content fyne.CanvasObject)

SetTests sets the tests page

func (n *NavigationSidebar) ShowPage(index int)

ShowPage shows the specified page

func (n *NavigationSidebar) ToggleCollapse()

ToggleCollapse toggles the collapsed state of the sidebar

type SMARTData

type SMARTData struct {
	Temperature    float64 // Celsius
	HealthStatus   string  // Good, Warning, Critical
	PowerOnHours   uint64
	PowerCycles    uint64
	TotalWrittenGB float64
	TotalReadGB    float64
	WearLevel      float64 // Percentage for SSDs
	Available      bool    // Whether SMART data is available
}

SMARTData contains SMART attributes for a storage device

type SPDData

type SPDData struct {
	Slot              int
	Revision          byte
	MemoryType        string
	MemoryTypeCode    byte
	PartNumber        string
	SerialNumber      uint32
	ManufacturerID    uint16
	JEDECManufacturer string
	ManufacturingDate string
	ModuleSize        uint64
	CapacityGB        float64
	Speed             uint32
	DataRateMTs       int
	PCRate            int
	BaseFreqMHz       float64
	Voltage           float32
	Ranks             int
	DataWidth         int
	BankGroups        byte
	BanksPerGroup     byte
	CASLatency        int
	RAStoCASDElay     int
	RASPrecharge      int

	CommandRate string
	Timings     struct {
		CL   int
		RCD  int
		RP   int
		RAS  int
		RC   int
		RFC  int
		RRDS int
		RRDL int
		FAW  int
	}
	HasXMP       bool
	HasEXPO      bool
	ProfileCount int
	RawSPD       []byte
	// contains filtered or unexported fields
}

SPDData contains parsed SPD information (stub for non-Windows)

type SPDReader

type SPDReader struct{}

SPDReader provides SPD reading capabilities (stub for non-Windows)

func NewSPDReader

func NewSPDReader() *SPDReader

NewSPDReader creates a new SPD reader instance (stub)

func (*SPDReader) Close

func (r *SPDReader) Close()

Close closes the SPD reader (stub)

func (*SPDReader) Initialize

func (r *SPDReader) Initialize() error

Initialize initializes the SPD reader (stub)

func (*SPDReader) ReadAllSPD

func (r *SPDReader) ReadAllSPD() ([]SPDData, error)

ReadAllSPD reads SPD data from all memory modules (stub)

type StartupTask added in v0.3.0

type StartupTask struct {
	Name string
	Fn   func() error
}

StartupTask represents a task to run during startup

type StaticCache added in v0.3.0

type StaticCache struct {
	Motherboard    *MotherboardInfo
	MemoryModules  []MemoryModule
	GPUs           []GPUInfo
	StorageDevices []StorageInfo
	Fans           []FanInfo
	SysInfo        *SystemInfo
}

StaticCache holds preloaded component data

func LoadComponentsAsync added in v0.3.0

func LoadComponentsAsync(updates chan<- Update) *StaticCache

LoadComponentsAsync loads all components in background and sends progress updates

type StorageInfo

type StorageInfo struct {
	Device      string
	Mountpoint  string
	Filesystem  string
	Type        string // HDD, SSD, NVME, USB
	Size        uint64
	Used        uint64
	Free        uint64
	UsedPercent float64

	// Drive identification
	Model      string
	Serial     string
	Vendor     string
	Controller string
	Firmware   string
	Interface  string // SATA, NVMe, USB, etc.

	// SMART data
	SMART *SMARTData
}

StorageInfo contains information about a storage device

func GetStorageInfo

func GetStorageInfo() ([]StorageInfo, error)

GetStorageInfo returns information about all storage devices

type SummaryCard

type SummaryCard struct {
	// contains filtered or unexported fields
}

SummaryCard represents a summary metric card

type SystemInfo

type SystemInfo struct {
	Host   HostInfo
	CPU    CPUInfo
	Memory MemoryInfo
	GPU    []GPUInfo
}

SystemInfo contains detailed system information

func GetSystemInfo

func GetSystemInfo() (*SystemInfo, error)

GetSystemInfo gathers comprehensive system information

type TestOption

type TestOption struct {
	Name        string
	Description string
	Icon        fyne.Resource
	Category    string
	OnStart     func()
}

TestOption represents a test option

type TestWizard

type TestWizard struct {
	// contains filtered or unexported fields
}

TestWizard represents the test configuration wizard

func NewTestWizard

func NewTestWizard(dbPath string) *TestWizard

NewTestWizard creates a new test wizard

func (*TestWizard) Content

func (w *TestWizard) Content() fyne.CanvasObject

Content returns the wizard content

type TestsPage

type TestsPage struct {
	// contains filtered or unexported fields
}

TestsPage represents the tests selection page

func NewTestsPage

func NewTestsPage() *TestsPage

NewTestsPage creates a new tests page

func (*TestsPage) Content

func (t *TestsPage) Content() fyne.CanvasObject

Content returns the tests page content

type TooltipWidget

type TooltipWidget struct {
	widget.BaseWidget
	// contains filtered or unexported fields
}

TooltipWidget wraps a widget with tooltip functionality

func NewTooltipWidget

func NewTooltipWidget(child fyne.CanvasObject, tooltip string, window fyne.Window) *TooltipWidget

NewTooltipWidget creates a widget with a tooltip

func (*TooltipWidget) CreateRenderer

func (t *TooltipWidget) CreateRenderer() fyne.WidgetRenderer

CreateRenderer creates the renderer for the tooltip widget

func (*TooltipWidget) MouseIn

func (t *TooltipWidget) MouseIn(*desktop.MouseEvent)

MouseIn shows the tooltip

func (*TooltipWidget) MouseMoved

func (t *TooltipWidget) MouseMoved(*desktop.MouseEvent)

MouseMoved is required by the interface

func (*TooltipWidget) MouseOut

func (t *TooltipWidget) MouseOut()

MouseOut hides the tooltip

type USBDevice

type USBDevice struct {
	Name      string
	Vendor    string
	Product   string
	VendorID  string
	ProductID string
}

USBDevice represents a USB device

func GetUSBDevices

func GetUSBDevices() ([]USBDevice, error)

GetUSBDevices returns information about USB devices

type Update added in v0.3.0

type Update struct {
	Step  int
	Total int
	Text  string
}

Update represents a progress update message

type WindowsDriveMapping

type WindowsDriveMapping struct {
	DiskNumber      int    `json:"DiskNumber"`
	Model           string `json:"Model"`
	SerialNumber    string `json:"SerialNumber"`
	FirmwareVersion string `json:"FirmwareVersion"`
	MediaType       string `json:"MediaType"`
	BusType         string `json:"BusType"`
	DriveLetter     string `json:"DriveLetter"`
	VolumeName      string `json:"VolumeName"`
}

WindowsDriveMapping represents the mapping between physical disks and logical drives

func GetWindowsDriveMappings

func GetWindowsDriveMappings() ([]WindowsDriveMapping, error)

GetWindowsDriveMappings stub for non-Windows platforms

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL