Giter Site home page Giter Site logo

windowsystem's Introduction

WindowSystem

PURPOSE:

  • This plugin has two purpose.
    • It creates an external windows in "runtime" with UMG support.
    • It enabled file drag drop to main window and external windows.

USAGE:

  • Place "BP_Template_WinMan" to world (it is in Plugins/WindowSystem Content/BPs)
  • Use "Get All Actors of Class -> Get Index 0 -> Create a variable for that (BP_Template_WinMan Object Referance)
  • We need this in only Event Begin Play and there will be only one actor with that class. So, Get All Actors of Class won't impact your project's performance.
  • We will use created variable as referance.
  • Add "Create New Window" node from BP_Template_WinMan Object Referance.
  • To enable file drag drop for main window, set true to "Allow Main Window" boolean on BP_Template_WinMan (Default is true and it exposed as instanced variable.)
  • To enable file drag drop for created windows, use Set File Drag Drop Support after window creation.
  • Drop operation will trigger an event as OnFileDrop. This event will give you file path, drop location on screen and dropped window's name. ***So, you need to implement your import mechanics with these informations.

FEATURES:

  • Created windows and main game window can support runtime file drag drop.
  • User can drop multiple files at once. It gives an array.
  • User can get drop location on screen. You can use it to calculate world location for importing and spawning 3D assets to specific location.
  • It records all generated windows in a "MAP_Windows" map variable. (Key = Window Tag / Value = Window Object). If you have access BP_Template_WinMan Object Referance, you can get your window object referance with only its tag.)
  • User can take screenshot of visible window or whole widget.
  • Implemented close function has ReleaseSlateResource function. So, you don't need to manually remove UMG before closing window.
  • If target platform is Windows 11, created windows will have rounded corners.

WINDOW VARIABLES:

  • Is Top Most
  • Has Close (We recommend to set this false. Because if user close a runtime generated window, all contents and its referances will be gone. So, use it for if window's widget is manually created and does not important for mechanics.
  • Force Volatile
  • Preserve Aspect Ratio (When user change size of that window, should window preserve it's aspect ratio or not)
  • Minimized (Should window initially minimized or not)
  • Supports Maximize
  • Supports Minimize
  • Set Mirror Window (True if the window is a mirror window for HMD content)
  • In Window Tag (You should absolutely set this with a meaningful and unique tag without space. Because we use this to record and get windows)
  • In Window Title (Title will be visible on window's titlebar if you give a title. This is different than tag. It can be a sentence and more readable.)
  • In Tooltip (When user hovered that window, there will be additional information as tooltip.)
  • Window Size
  • Minimum Size (Minimum acceptable size for that window.)
  • Window Position
  • In Border (Border size between frame and its UMG content)
  • In Opacity (Initial opacity value of that window)

ADDITIONAL FUNCTIONS (Static Functions. Should be called without Window Manager):

  • Take Screenshot of Widget

  • Take Screenshot of Window

  • Get Main Window Title

  • Get Window Tag

  • Get Window Title

  • Get Window Position (return screen position as FVector2D)

  • Get Window State (returns enums Minimized / Restored / Maximized)

  • Get Window Widget (return UUSerWidget)

  • Set Window Title

  • Set Window State (Minimmized / Restored / Maximized)

  • Set Window Shape (Give new position and or size with an animation)

  • Set Window Opacity

  • Is Window Top Most

  • Is Window Hovered

  • Bring Window Front

ADDITIONAL FUNCTIONS (Virtual Function. Should be called with Window Manager Referance):

  • Set All Windows Opacities
  • Detect Hovered Window
  • Set File Drag Drop Support
  • Create New Window
  • Close Window
  • Close All Windows

ON PURPOSED LIMITATION:

  • Created windows won't appear on taskbar. Because even if we disable "close" button in titlebar, Windows Operating System does not disable it in taskbar and user can accidentally close it. So, we hide all window. If your project is fullscreen and a created window goes back, you need to use an UMG button and "Bring Window Front" function to bring it back. If your project is windowed, other windows will just goes one layer back. So you can bring it back with just hover.

***PLATFORM:

  • This plugin created only for Windows operating system and Unreal Engine 5. Other platforms such as Linux, Mac OS and Unreal Engine 4 won't be supported.

windowsystem's People

Contributors

ffreality avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.