"""English translation defaults for docscan GUI."""

ENGLISH_DEFAULTS = {
    "window_title": "Document Scanner GUI",
    "input_config_tab": "Input Configuration",
    "scan_options_tab": "Scan Options",
    "input_directory": "Input Directory:",
    "browse": "Browse...",
    "rules_file": "Rules File:",
    "file_types": "File Types:",
    "use_pdf_ocr": "Use PDF OCR",
    "use_process_pool": "Use Process Pool (CPU-intensive)",
    "threads": "Threads:",
    "batch_size": "Batch Size:",
    "start_scan": "Start Scan",
    "pause": "Pause",
    "resume": "Resume",
    "stop": "Stop",
    "save_results": "Save Results",
    "clear_results": "Clear Results",
    "results": "Results",
    "files_scanned": "Files Scanned:",
    "files_with_matches": "Files with Matches:",
    "progress_log": "Progress Log:",
    "match_details": "Match Details:",
    "selected_match_context": "Selected Match Context:",
    "file": "File",
    "type": "Type",
    "matches": "Matches",
    "time": "Time (s)",
    "select_input_directory": "Select Input Directory",
    "select_rules_file": "Select Rules File",
    "json_files": "JSON Files (*.json)",
    "save_results_dialog": "Save Results",
    "default_results_filename": "scan_results_{datetime}.json",
    "error": "Error",
    "warning": "Warning",
    "success": "Success",
    "invalid_input_directory": "Invalid input directory",
    "no_valid_rules": "No valid rules found",
    "failed_to_load_rules": "Failed to load rules: {error}",
    "no_results_to_save": "No results to save",
    "failed_to_save_results": "Failed to save results: {error}",
    "scan_failed": "Scan failed: {error}",
    "starting_scan": "Starting scan...",
    "scan_complete": "Scan complete!",
    "pausing_scan": "Pausing scan...",
    "stopping_scan": "Stopping scan...",
    "scan_completed": "Scan completed",
    "scan_stopped": "Scan stopped",
    "found_matches_files": "Found matches in {count} files",
    "file_info": "File",
    "type_info": "Type",
    "size": "Size",
    "bytes": "bytes",
    "rule": "Rule",
    "description": "Description",
    "line": "Line {line}: {match}",
    "context": "Context:",
    "default_file_types": "pdf,docx,xlsx,pptx,txt,odt,rtf,epub,csv,xml,html,md,jpg,jpeg,png,gif,bmp,tiff",
    "default_rules_file": "rules.json",
    "results_saved_to": "Results saved to:\n{path}",
    "files_scanned_zero": "Files Scanned: 0",
    "files_with_matches_zero": "Files with Matches: 0",
    "language_settings": "Language Settings",
    "processing_options": "Processing Options",
    "performance_settings": "Performance Settings",
    "language_label": "Language:",
    "ocr_tooltip": "Enable OCR for scanned PDF files to extract text from images",
    "process_pool_tooltip": "Use multiple processes for CPU-intensive operations (may increase memory usage)",
    "threads_tooltip": "Number of worker threads (higher values may improve speed but use more CPU)",
    "batch_size_tooltip": "Number of files to process in each batch (larger batches may improve throughput)",
    "file_types_tooltip": "File types to scan (comma separated)",
    "file_menu": "&File",
    "settings_menu": "&Settings",
    "help_menu": "&Help",
    "preferences": "&Preferences...",
    "exit": "E&xit",
    "about": "&About",
    "about_title": "About Document Scanner",
    "about_text": "Document Scanner GUI\n\nVersion 1.0",
    "language": "Language",
    "open_results": "Open Results...",
    "open_results_file": "Open Scan Results",
    "loaded_results_from": "Loaded results from: {path}",
    "results_loaded_successfully": "Results loaded successfully from:\n{path}",
    "failed_to_load_results": "Failed to load results: {error}",
    # Command-line specific translations
    "document_scanner_description": "Scan documents and extract text, images, and metadata with certain rules.",
    "input_directory_help": "Input directory containing documents to scan",
    "rules_file_help": "Rules file (JSON)",
    "recursive_help": "Scan files recursively",
    "file_types_help": "File types to scan (comma-separated)",
    "use_pdf_ocr_help": "Use PDF OCR for image-based PDFs",
    "use_process_pool_help": "Use process pool instead of thread pool (better for CPU-intensive tasks)",
    "batch_size_help": "Number of files to process in each batch",
    "threads_help": "Number of threads for parallel scanning",
    "progress_help": "Show progress bar",
    "verbose_help": "Verbose output",
    "language_help": "Set language (en for English, zh for Chinese)",
    # Status and logging messages
    "scanning_directory": "Scanning directory: {directory}",
    "found_files_to_scan": "Found {count} files to scan",
    "scan_resumed": "Scan resumed",
    "scan_stopped_before_submitting_tasks": "Scan stopped by user before submitting all tasks",
    "scan_paused": "Scan paused",
    "scan_stopped_while_paused": "Scan stopped while paused",
    "scan_stopped_by_user_canceling_tasks": "Scan stopped by user, cancelling remaining tasks...",
    "task_timeout_scan_may_be_stopping": "Task timeout, scan may be stopping",
    "error_scanning_file": "Error scanning file: {error}",
    "progress_report": "Progress: {processed}/{total} files processed",
    "force_shutting_down_executor": "Force shutting down executor...",
    "scan_stopped_processed_files": "Scan stopped. Processed {processed} files",
    "scan_complete_found_matches": "Scan complete. Found matches in {matches_count} files",
    "found_matches_in_file": "Found matches in: {file_name}",
    "processed_file_info": "Processed {file_name} ({ext}) in {time:.3f}s - {matches_count} matches found",
    "could_not_extract_text_from_file": "Could not extract text from {file_path}: {error}",
    "pymupdf_failed_for_file": "PyMuPDF failed for {file_name}: {error}",
    "pypdf_also_failed_for_file": "pypdf also failed for {file_name}: {error}",
    "no_pdf_library_installed": "No PDF library installed (pymupdf or pypdf)",
    "pymupdf_not_installed": "PyMuPDF not installed",
    "no_pages_found_in_file": "No pages found in {file_path}",
    "no_metadata_found_in_file": "No metadata found in {file_path}",
    "pymupdf_error_trying_fallback": "PyMuPDF error on {file_path}: {error}, trying pypdf fallback",
    "pypdf_not_installed_skipping_extraction": "pypdf not installed, skipping PDF extraction",
    "error_extracting_pdf_with_pypdf": "Error extracting PDF with pypdf: {error}",
    "odfpy_not_installed_skipping_extraction": "odfpy not installed, skipping ODT extraction",
    "error_extracting_odt": "Error extracting ODT: {error}",
    "error_extracting_rtf": "Error extracting RTF: {error}",
    "ebooklib_not_installed_skipping_extraction": "ebooklib not installed, skipping EPUB extraction",
    "error_extracting_epub": "Error extracting EPUB: {error}",
    "error_extracting_csv": "Error extracting CSV: {error}",
    "error_extracting_xml": "Error extracting XML: {error}",
    "error_extracting_html": "Error extracting HTML: {error}",
    "error_extracting_markdown": "Error extracting Markdown: {error}",
    "python_docx_not_installed_skipping_extraction": "python-docx not installed, skipping DOCX extraction",
    "openpyxl_not_installed_skipping_extraction": "openpyxl not installed, skipping XLSX extraction",
    "python_pptx_not_installed_skipping_extraction": "python-pptx not installed, skipping PPTX extraction",
    "pillow_or_tesseract_not_installed_skipping_ocr": "PIL or pytesseract not installed, skipping image OCR",
    "could_not_perform_ocr_on_file": "Could not perform OCR on {file_path}: {error}",
    "input_directory_does_not_exist": "Input directory does not exist: {input_dir}",
    "using_rules_file": "Using rules file: {rules_file}",
    "invalid_json_in_rules_file": "Invalid JSON in rules file: {error}",
    "invalid_rules_format": "Invalid rules format. Expected a list or dict with 'rules' key",
    "no_valid_rules_found": "No valid rules found",
    "total_time_elapsed": "Total time elapsed: {time:.2f}s",
    "invalid_regex_pattern": "Invalid regex pattern '{pattern}': {error}",
    "rules_file_does_not_exist_alt": "Rules file does not exist: {rules_file}",
    "image_files_supported": "Image files supported (requires OCR)",
    "include_image_formats": "Include Image Formats",
    "include_image_formats_tooltip": "Include image formats (jpg, jpeg, png, gif, bmp, tiff) in scan",
    # Results Saved Message
    # Apply Button
    "apply": "Apply",
    # Status Messages
    "ready_status": "Ready",
    "scanning_status": "Scanning...",
    "completed_status": "Completed",
    "status_bar_tooltip": "Current application status",
    # Tooltips
    "browse_directory_tooltip": "Browse for input directory",
    "browse_rules_tooltip": "Browse for rules file",
    "start_scan_tooltip": "Start document scanning",
    "pause_resume_tooltip": "Pause or resume scanning",
    "stop_tooltip": "Stop scanning",
    "save_results_tooltip": "Save scan results to file",
    "clear_results_tooltip": "Clear current results",
    "open_results_tooltip": "Open previously saved results",
    # Success message
    "language_switch_success": "Language switched to {lang}, all interface elements updated in real-time!",
    "add_type_button": "+ Add Type",
    "remove_type_button": "- Remove Type",
    "all_types_group": "📂 All Types",
    "document_files_group": "📄 Document Files",
    "spreadsheet_files_group": "📊 Spreadsheet Files",
    "image_files_group": "🖼️ Image Files",
    "web_files_group": "🌐 Web Files",
    "archive_files_group": "📦 Archive Files",
}
