How to delete lines in Greenfoot?

I drew lines by using the method drawLine(),now I want to delete the lines,how can I do? I can't find any methods in Greenfoot API.PLEASE HELP! import greenfoot.*; // (World, Actor,...

in java awt or swing, how can I arrange for keyboard input to go wherever the mouse is?

Working on a help system, I'd like each component to offer some help when the the mouse is over it and the "?" key is pressed. Sort of like tooltips, except with much more extensive help -...

Java: Mouse position in game

I am using the MouseInfo class to get the mouse position like this way: public static void main (String[] args){ Point mousePosition = MouseInfo.getPointerInfo().getLocation(); } It works...

C# Find continuous values in List quickly

I am working on a project that plotting the mouse tracking. The MouseInfo class is defined like: public class MouseInfo { public readonly long TimeStamp; public readonly int PosX; ...

C2131 Error for static_assert () in C++

Recently I was trying to create a class that can have only one instantiated object. On searching Wikipedia I found that using the singleton pattern would help out. I didn't like the idea of it...

Error in cv2.KalmanFilter.predict

I am trying to implement a mouse track program using opencv-python. I'm using a kalman filter in cv2.Kalman to predict the point of the mouse, but the function cv2.KalmanFilter.predict() throw an...

Robot.mouseMove does not work at all in Mac OS X

I created java file in IntelliJ IDE, with that code import java.awt.AWTException; import java.awt.MouseInfo; import java.awt.Robot; public class JavaRobotExample { public static void...

moving a virtual mouse with touch in UWP causes flashing cursor

I'm attempting to emulate the behavior of Windows 10's Virtual Touchpad, ie when a user touches a control inside the app and moves their finger around, the system cursor will mirror their...

How to add vue @click event in tooltip title content?

I will need to add @click event handler to the tooltip content. so the user can click on the tooltip to get more details. simply writing @click will not work. Vue full Calendar code here I use the...

I can't install Open CV

I am trying to install Open CV for this tutorial... https://www.youtube.com/watch?v=Hqf__FlRlzg&list=WL&index=4&t=2494s I have installed it and when I type pip list in the terminal it shows that I...

from nltk.chat.util import Chat, reflections ModuleNotFoundError: No module named 'nltk'

I have installed nltk library in my laptop but when I try to import it in my pycharm project, it says ModuleNotFoundError: No module named 'nltk' . What should I do? This is my console response...

Python 2.7.17 - PyAutoGUI says Pillow is not installed, but it is installed

I'm currently making an app that takes a screenshot and compares some stuff on it. It is currently, after a long while, I managed to get a different error than I was getting before, further ahead...

PyCharm can't install Pyautogui

I have been using IDLE up til recently after reading Al Sweigart's book but have moved to using PyCharm as was recommended by a colleague. I cannot install PyAutoGUI with a 3.8 interpreter. I have...

Heroku - can't see application

Edit: Problem solved. i've created a basic app, using python and flask. i've deployed the app to heroku and heroku didn't raise any exceptions or errrors. But when i open my app i getting...

How do I not get OSError: [Errno -9993] Illegal combination of I/O devices when using pyaudio

I believe it's this module that's crashing my program and throwing this error: OSError: [Errno -9993] Illegal combination of I/O devices. I wrapped the call to this module in a try except...

Wont let me download pip, says there's a permission problem and I need to update pip

Audreys-computer:~ audreyoneill$ python3 -m pip install pyautogui Collecting pyautogui Collecting pyobjc-core; platform_system == "Darwin" (from pyautogui) Using cached...

PyAutoGui throwing KeyError: 'DISPLAY' error

I want to automate a windows task and from searching the web PyAutoGui seems to be the right tool for it. Im working on a virtual env , using python 3.6.9, and a ubuntu WSL. after installing it...

Why is pyauto gui and Pycharm not working for me?

import pyautogui pyautogui.PAUSE = 1 pyautogui.FAILSAFE = True pyautogui.click(274, 783) I'm running Pycharm on a Mac. I have tried installing pyautogui from the interpreter AND with the...

Is pyautogui work in the ubuntu 18.04 server version with no display accessed via ssh?

When I am import pyautogui it gives me: Traceback (most recent call last): File "app.py", line 2, in <module> from register import reg File...

How to run pyautogui on mac?

I simply tried to run a code by importing pyautogui module, using the position function. However, every time, I got the following error: Traceback (most recent call last): File...

python pywhatkit module take much time to install and not install in linux

I am using vs code in linux(raspberry pi 4), when i am trying to install pywhatkit python module using pip, pip3 install pywhatkit, it download some data of pywhatkit, after some time it freeze at...

Pyinstaller no suitable image found

I have PyInstaller version 4.0 installed on my system. I am attempting to build a python script using python 3.7.3. This python script imports other python scripts which have their own import...

Trying to deploy a script to Heroku and I get this error

I'm trying to deploy a python script to Heroku, when I enter this line git push heroku master. It gives me this error ERROR: No .egg-info directory found in /tmp/pip-pip-egg-info-y_748suf and Push...

Pyinstaller - python script converted to .exe doesn't execute the program in the way expected

I wish to convert my .py script (which works perfectly when executed) into .exe using Pyinstaller, however when the conversion is done and I launch the newly made .exe file, the cmd pops up with...

Why can't I use Pyautogui in Ubuntu 20.04 LTS?

I've been trying to use Pyautogui at Ubuntu, but I simply can't make it work, while I have no trouble doing it at Windows. It doesn't matter what dependency I install, everytime I try to use...

Pyautogui error on windows "KeyError: 'DISPLAY'"

I have already used pyautogui on a Mac os system before without any trouble, but now I'm trying on a windows 10 machine running this code: import pyautogui print(pyautogui.position()) And I get...

issue attempt to run pyautogui file ends with KEYERROR = 'DISPLAY'

I wanted to run a python file project and its pyautogui spam bot, but when I installed pyautogui and tried to run the file it gives me this: Error: Traceback (most recent call last): File...

Error message when trying to run PyAudio in Visual Studio Code (Flatpak)

Linux Mint 20.1 I was about to run a python program in Visual Studio Code (Flatpak), but then I got the following error message: NOTE: You must install tkinter on Linux to use MouseInfo. Run the...

NameError: ObjC Class 'b'NSEvent'' couldn't be found. - PyAutoGui

I installed pyautogui recently, using pip3 install pyautogui. This worked and I received no error on installation. But when importing the module as shown below. import pyautogui I was kindly...

Is there a way to use pywhatkit on ubuntu?

I've installed the pywhatkit module on WSL ubuntu but when I try import it in a script or in the interactive interpreter, it doesn't work. I've tried running the script without WSL on command...