Customizing JSXgraph fullscreen mode? - fullscreen

Fullscreen mode in JSXgraph always adds big gray margins around the board, giving the impression I don't take full advantage of a big screen. Can one configure fullscreen mode, so as to minimize the use of these margins?

This is a good question / suggestion! Up to version 1.4.6 it is not possible to configure the size of the JSXGraph board in the fullscreen window.
since this property is hard-coded with the value of 0.85.
I just added the new board attribute scale to the source code, available in the fullscreen attribute object:
const board2 = JXG.JSXGraph.initBoard('jxgbox', {
axis:true,
boundingbox:[-5,5,5,-5],
showFullscreen: true,
fullscreen: {
scale: 0.99
}
});
var pol = board.create('polygon', [[0, 1], [3,4], [-1,-4]]);
The default value of the attribute will be 0.85. This feature will be available in the upcoming 1.4.7 version.

Related

Awesome WM - Chatty (Java application) bypass dimension properties from rc.lua

Chatty is a java application to chat in Twitch (streaming platform) from the desktop.
What I'm trying to accomplish is that Chatty always starts with specifics X, Y, width and height properties.
{ rule = { class = "chatty-Chatty" },
properties = {
width = 267,
height = 223,
x = 1575,
y = 774
},
},
The X and Y properties work just fine, wherever I move the window if I closed and open it again it appears in my desired position. However for some reason I fail to acknowledge Chatty doesn't care about the width and height properties, it always opens with the last geometry.
Chatty itself have a config file but there isn't anything related to width and height dimensions.
I'm on Arch, and the only WM I have is Awesome.
PD: One weird thing is that every time I'm changing the window size it also moves, always in a bottom right direction. This is annoying but not a problem, I'm mentioning this just in case it is related to the possible issue.
This is probably because they client resize itself after the rules are executed (which would be a bug in your app or Java). In any case, you can do:
client.disconnect_signal("request::geometry", awful.ewmh.client_geometry_requests)
to turn off the client ability to resize themselves.
In AwesomeWM git-master version, you can use the permission API to deny the "client" -> "geometry" -> "ewmh" permission per client.

NavigationManager's startNavigation() has blank map

I'm trying to use turn by turn navigation using SKNavigationManager's startNavigation(navigationSettings). Interestingly it works flawless in 'Simulation' mode but when I switch to 'Real' mode there is no map on the screen. It's just that the map is not drawn on screen, but the rest like annotations and other stuff are populated and working fine.
I've used SKToolsNavigatoinManager and it works fine, but I don't want to use it as it has a lot of UI interfaces which are not useful for my application.
Any help is appreciated.
Here is the settings and the navigationManager code I'm using
SKNavigationSettings navigationSettings = new SKNavigationSettings();
SKNavigationManager navigationManager = SKNavigationManager.getInstance();
navigationSettings.setNavigationType(SKNavigationSettings.SKNavigationType.REAL);
navigationSettings.setNavigationMode(SKNavigationSettings.SKNavigationMode.PEDESTRIAN);
navigationManager.setMapView(navMapView);
navigationManager.startNavigation(navigationSettings);
If i don't use the navigationManager.setMapView(navMapView); I get a different view.
1. This is how the screen looks like after I start navigation
2. This is how the screen looks like before navigation
The map is drawn to the screen its just centered at the point [0,0] which is in the middle of the Atlantic ocean therefore the screen is blue. To have the camera follow the current location you must do the following 2 steps:
Set follow positions to true on your SKMapView object: navMapView.getMapSettings().setFollowPositions(true);
Create a SKCurrentPositionProvider and set the SKCurrentPositionListener
SKCurrentPositionProvider positionProvider = new SKCurrentPositionProvider(activity);
positionProvider.setCurrentPositionListener(new SKCurrentPositionListener(){
#Override
public void onCurrentPositionUpdate(SKPosition currentPosition) {
SKPositionerManager.getInstance().reportNewGPSPosition(currentPosition);
}
});
positionProvider.requestLocationUpdates(true, true, false);

Haxeflixel with Neko build, Screen size does not fit

I use Haxeflixel, choose build target Neko and Neko 64.
I coded 1280 x 720 resolution but executed screen is not fit.
change resoulution too.
I just reinstall my os x yosemite system. is the reason it?
I can not understand this situation
var gameWidth:Int = 1280; // Width of the game in pixels (might be less / more in actual pixels depending on your zoom).
var gameHeight:Int = 720; // Height of the game in pixels (might be less / more in actual pixels depending on your zoom).
var initialState:Class<FlxState> = PlayState; // The FlxState the game starts with.
var zoom:Float = -1; // If -1, zoom is automatically calculated to fit the window dimensions.
var framerate:Int = 60; // How many frames per second the game should run at.
var skipSplash:Bool = false; // Whether to skip the flixel splash screen that appears in release mode.
var startFullscreen:Bool = false; // Whether to start the game in fullscreen on desktop targets
very default settings...
If I understand your question, the problem is that gameWidth and gameHeight set the game's logical screen size, not the size in pixels of the window that the game runs in.
Try changing the window settings in your project's Project.xml file to set the physical size of the window to match the game coordinates and it might start looking how you expect:
<!--These window settings apply to all targets-->
<window width="1280" height="720" fps="60" background="#000000" hardware="true" vsync="true" />
It's lime 2.4.4 problem.
download http://www.openfl.org/builds/lime/lime-2.4.0-6-g837aa96.zip
and
haxelib local lime-2.4.0-6-g837aa96.zip on terminal
see below..
http://community.openfl.org/t/running-openfl-error-on-mac/1409/14

Windows metro app UI messes in high resolution devices when SwapChainBackgroundPanel is replaced by SwapChainPanel

I am developing winRt metro application. I was using SwapChainBackgroundPanel in UI for showing video content.
I recently replaced it by SwapChainPanel because Microsoft recommends it.
But now the UI is stretched beyond the screen.
If I don't convert dips to pixels while resizing swapchain buffers , The UI looks fine.
I am seeing this problem in Surface pro 3 and other high resolution devices
Beginning with SwapChainPanel, you have to take the properties CompositionScaleX and CompositionScaleY into consideration.
Just before m_swapChain->GetBuffer(), insert the following code:
// Setup inverse scale on the swap chain
DXGI_MATRIX_3X2_F inverseScale = { 0 };
inverseScale._11 = 1.0f / m_swapChainPanel->CompositionScaleX;
inverseScale._22 = 1.0f / m_swapChainPanel->CompositionScaleY;
ComPtr<IDXGISwapChain2> spSwapChain2;
DX::ThrowIfFailed(
m_swapChain.As<IDXGISwapChain2>(&spSwapChain2)
);
DX::ThrowIfFailed(
spSwapChain2->SetMatrixTransform(&inverseScale)
);

How to disable snapview in WINJS?

I am creating an app in which snapview should be disabled.I have tried using:
window.addEventListener("resize", onViewStateChanged);
function onViewStateChanged(eventArgs) {
var viewStates = Windows.UI.ViewManagement.ApplicationViewState;
var newViewState = Windows.UI.ViewManagement.ApplicationView.value;
if (newViewState === 2 || newViewState===3) {
showMenu('snapped');
}
}
function showMenu(event) {
//Detect View State
if (event === 'snapped') {
var msg = new Windows.UI.Popups.MessageDialog(
"Resizing Window");
msg.showAsync();
window.innerWidth=screen.width
}
But this doesn't seem to work.Is there anything that i might have missed to disable the snapview.
Thanks
Because you're talking about snapped view, I assume that you're targeting Windows 8.0 and not Windows 8.1. In the latter, the snapped view state was removed in favor of variable-sized views, and in the app manifest you can indicate a minimum width of 500px (the default) or 320px (the former snapped view). Leaving it to 500px will prevent the narrow snapped view altogether.
If you are yet targeting Windows 8.0, there is unfortunately no means to disable snapped view (which is, by the way, why the change happened for 8.1). Apps that cannot effectively operate in the 320px view just display a message to that effect, suggesting to the user that they resize the view to use the app.

Resources