This plugin allows Flutter desktop apps to Retrieve information about screen size, displays, cursor position, etc.

Overview

screen_retriever

pub version

This plugin allows Flutter desktop apps to Retrieve information about screen size, displays, cursor position, etc.

Discord


Platform Support

Linux macOS Windows
✔️ ✔️ ✔️

Quick Start

Installation

Add this to your package's pubspec.yaml file:

dependencies:
  screen_retriever: ^0.0.2

Or

dependencies:
  screen_retriever:
    git:
      url: https://github.com/leanflutter/screen_retriever.git
      ref: main

Usage

Display? _primaryDisplay;
List<Display> _displayList = [];

void _init() async {
  _primaryDisplay = await screenRetriever.getPrimaryDisplay();
  _displayList = await screenRetriever.getAllDisplays();
  setState(() {});
}

Please see the example app of this plugin for a full example.

Who's using it?

  • Biyi (比译) - A convenient translation and dictionary app written in dart / Flutter.

Discussion

Welcome to join the discussion group to share your suggestions and ideas with me.

API

ScreenRetriever

Method Description Linux macOS Windows
getCursorScreenPoint Returns Offset - The current absolute position of the mouse pointer. ✔️ ✔️ ✔️
getPrimaryDisplay Returns Display - The primary display. ✔️ ✔️ ✔️
getAllDisplays Returns List<Display> - An array of displays that are currently available. ✔️ ✔️ ✔️

License

MIT License

Copyright (c) 2021 LiJianying <[email protected]>

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
You might also like...

Flutter user list calendar - A flutter app that displays registered users on a calendar/list and allows to search for users using the full name

Flutter User Calendar A flutter app that displays registered users on a calendar

Jan 20, 2022

A responsive scaffold widget that adjusts to your device size, for your flutter mobile and web apps.

A responsive scaffold widget that adjusts to your device size, for your flutter mobile and web apps.

scaffold_responsive A responsive scaffold widget that adjusts to your device size, for your flutter mobile and web apps. Check out the Live demo here

Sep 27, 2022

Dart package to retrieve Transmission data from remote instance

transmission Dart package to talk to a Transmission torrent instance, for a flutter package including UI widget please check transmission Getting Star

Nov 6, 2022

The Mashmart mobile app is designed as an example of how to retrieve data from the JSON API

The Mashmart mobile app is designed as an example of how to retrieve data from the JSON API

Mashmart Mobile App (Demo Version) ✨ About The Mashmart mobile app is designed a

Nov 17, 2022

This is a HubSpot clone Application built with DhiWise. It uses HubSpot APIs to store and retrieve data.

This is a HubSpot clone Application built with DhiWise. It uses HubSpot APIs to store and retrieve data.

HubSpot A Flutter Application, Built with ❤️ from DhiWise This is a HubSpot clone Application built with Flutter. It uses HubSpot APIs to store and re

Nov 27, 2022

Build different UIs for Android, iOS, Web, Desktop, Wear, TV etc without the if/else checks in your widgets.

Build different UIs for Android, iOS, Web, Desktop, Wear, TV etc without the if/else checks in your widgets.

platform_widget_mixin Plugin to decouple widgets based on various platform properties. Features Build different UIs for Android, iOS, Web, Desktop, We

Nov 17, 2022

A Flutter step_tracker plugin is collect information from user and display progress through a sequence of steps. this plugin also have privilege for fully customization from user side. like flipkart, amazon, myntra, meesho.

A Flutter step_tracker plugin is collect information from user and display progress through a sequence of steps. this plugin also have privilege for fully customization from user side. like flipkart, amazon, myntra, meesho.

step_tracker plugin A Flutter step_tracker plugin is collect information from user and display progress through a sequence of steps. this plugin also

Oct 21, 2022

A Flutter plugin for changing the Home Screen, Lock Screen (or both) Wallpaper on Android devices.

A Flutter plugin for changing the Home Screen, Lock Screen (or both) Wallpaper on Android devices.

wallpaper_manager A Flutter plugin for changing the Home Screen, Lock Screen (or both) Wallpaper(s) on Android devices. Usage Installation In the pubs

Nov 28, 2022

An app made using the Flutter framework that allows users to track information for over 1500 cryptocurrencies

Platypus Crypto Platypus Crypto is an ad-free cross-platform robust solution for tracking cryptocurrency assets. Our intuitive interface includes real

Jan 4, 2023
Comments
  • how to resolved Permission denied in linux

    how to resolved Permission denied in linux

    ❯ flutter run -d linux
    Launching lib/main.dart on Linux in debug mode...
    CMake Error at cmake_install.cmake:66 (file):
      file INSTALL cannot copy file
      "/home/naveen/Desktop/dev/faltu/test_screen_retriever/build/linux/x64/debug/intermediates_do_not_run/test_screen_retriever"
      to "/usr/local/test_screen_retriever": Permission denied.
    
    
    Building Linux application...                                           
    Exception: Build process failed
    
    opened by naveenadi 1
  • fix: crash when on wayland with no primary monitor

    fix: crash when on wayland with no primary monitor

    This PR add a fallback to prevent from crash by handling the condition that there is no primary monitor (gdk_display_get_primary_monitor return nullptr).

    opened by Kingtous 0
  • Question - Does screen_retriever provide keyboard cursor position on Linux?

    Question - Does screen_retriever provide keyboard cursor position on Linux?

    Does screen_retriever provide keyboard cursor position on Linux?

    I am working on a floating emoji keyword in flutter. I would like to show the emoji keyboard when the user presses win + .. I was wondering if I can use screen_retriever to get the (x, y) coordinates of the keyboard cursor on the screen.

    opened by dinbtechit 0
Releases(v0.1.4)
Owner
LeanFlutter
To make the flutter even simpler
LeanFlutter
SoundVolumeView that displays general information and the current volume level for all active sound components in your system, and allows you to instantly mute and unmute them

SoundVolumeView that displays general information and the current volume level for all active sound components in your system, and allows you to instantly mute and unmute them

Domingo 4 Mar 4, 2022
A widget based on Flutter's new Interactive Viewer that makes picture pinch zoom, and return to its initial size and position when released.

pinch_zoom A widget based on Flutter's new Interactive Viewer that makes picture pinch zoom, and return to its initial size and position when released

Teun Kortekaas 36 Dec 30, 2022
Flutter screen adaptation, font adaptation, get screen information

flutter_screenutil A flutter plugin for adapting screen and font size.Let your UI display a reasonable layout on different screen sizes! Note: This pl

OpenFlutter 3.4k Jan 6, 2023
Brands info app - Simple app that displays information about brands

brands_info_app Simple app that displays information about brands UI

Bunyod 0 Jan 6, 2022
A Flutter plugin to retrieve the Firebase App Instance ID

firebase_instance_id A Flutter plugin to retrieve the Firebase App Instance ID# device_unlock How does it work App Instance Id is an unique identifier

Cíngulo 1 Jan 21, 2022
The prime objective of this app is to store the real time information of the user using firebase cloud firestore and also can delete, remove and update the customer information

crud_firestore A new Flutter project. Getting Started This project is a starting point for a Flutter application. A few resources to get you started i

Muhammad Zakariya 0 Mar 15, 2022
Doctor Consultation App in Flutter containing splash screen on boarding screen Routing state management Dash board Bottom navigation Decorated Drawer and Doctors Screen in the last.

Online doctor Consultation App UI in Flutter Doctor Consultation App UI in Flutter Visit Website Features State Management Navigation Bar Responsive D

Habib ullah 14 Jan 1, 2023
Android test task master - Create PIN code screen, authentication by PIN code screen and menu screen

Here is described test tasks for a android dev. Need to implement three screens:

null 3 Oct 4, 2022
An Adaptive Navigation Bar in flutter. Navbar changes according to the screen size.

Adaptive NavBar (adaptive_navbar) Table of contents General info Setup Conclusion Useful Resources Meet the developer General info adaptive_navbar is

Mouli Bheemaneti 3 Oct 17, 2022