APS Excellence in Physics Education Award
November 2019

Education Prize Logo
Science SPORE Prize
November 2011

NSF Logo
The Open Source Physics Project is supported by NSF DUE-0442581.

Example of zooming JS? post and replies

Return to the Example of zooming JS? thread
Login to post to this thread

Example of zooming in JS?
Poul Alma
1 Posts

Can someone show a demo (or describe) how to enable zooming by mouse / touch in JS?

I looked through the code and can see this can work in Java, but how is this done in JS?

Any help appreciated.

Thanks for a great simulation library!

Post edited December 8, 2018 at 8:50 AM EST.


Replies to Example of zooming in JS?

Re: Example of zooming in JS? -
lookang Avatar
lookang
222 Posts

You need to enable the htmlview Page - plottingPanel - EnabledZooming set it to true.

Attached is an example.

:)

By the way, there are a lot of examples made here https://iwant2study.org/ospsg/index.php/interactive-resources

enjoy!

 

Attached File: ejss_src_lookangtemplateblank.zip


OSP@SG blog
OSP@SG Digital Library


OSP Projects:
Open Source Physics - EJS Modeling
Tracker
Physlet Physics
Physlet Quantum Physics
STP Book