Closed theumangbaraiya closed 3 years ago
In Chrome I think you can only do this with windows you have created. See this SO answer - https://stackoverflow.com/a/10610931
Any solution using Chrome is likely to be quite hacky because forcing a particular view size is considered user-hostile.
Thanks, @ChrisKnott for the help but it is not working
@RapchikUmang31 This is a workaround that I've made. It's quite hacky but gets the job done.
window.addEventListener("resize", function(){
window.resizeTo({xValue}, {yValue});
});
Add that to all your pages and it should work fine
Try this way working for me!! Adding the following code in main.html
<script>
$(document).ready(function (){
window.resizeTo(600, 600);
});
</script>
I added it to my html page(I have only one). It's not working
Currently, I am working on a Python project where I have to make a desktop application using the python EEL library and I have done half of the project.
Recently I found out that I need to freeze my window size. So is there any option or trick so I can freeze my window size or in javascript to stop the user from resizing my window?
What argument could be added to these options?
Any type of help is appreciated.