prasule/lib/views/settings/settings.dart
2023-09-08 11:50:21 +02:00

48 lines
1.5 KiB
Dart

import 'package:flutter/material.dart';
import 'package:prasule/views/settings/tessdata_list.dart';
import 'package:settings_ui/settings_ui.dart';
class SettingsView extends StatefulWidget {
const SettingsView({super.key});
@override
State<SettingsView> createState() => _SettingsViewState();
}
class _SettingsViewState extends State<SettingsView> {
@override
Widget build(BuildContext context) {
return Scaffold(
body: SettingsList(
sections: [
SettingsSection(
tiles: [
SettingsTile.navigation(
title: const Text("View downloaded OCR data"),
description: const Text(
"This data is used by the OCR to recognise text from pictures"),
onPressed: (context) => Navigator.of(context).push(
MaterialPageRoute(
builder: (c) => const TessdataListView())),
)
],
title: const Text("OCR"),
),
SettingsSection(
tiles: [
SettingsTile.navigation(
title: const Text("View downloaded OCR data"),
description: const Text(
"This data is used by the OCR to recognise text from pictures"),
onPressed: (context) => Navigator.of(context).push(
MaterialPageRoute(
builder: (c) => const TessdataListView())),
)
],
title: const Text("OCR"),
),
],
),
);
}
}