chm.css
HTML Help用CSSファイル
コントロールキー+マウスホイールで拡大・縮小ズームします
コントロールキー+マウスホイールで拡大・縮小ズームします
BODY,P {font-size=12px!important;} BODY { behavior:expression( (function(el){ /* Zooming [Ctrl] + [MouseWheel] in chm File*/ el.document.attachEvent('onmousewheel', function(event){ if (event.ctrlKey) { var _doc=document; var zoom = _doc.body.currentStyle.zoom; if(zoom == 'normal')zoom=100; var changevalue = (event.wheelDelta<0)? 10 : -10; var newvalue = parseInt(zoom) + changevalue; if (newvalue<10) newvalue = 10; var _sheet = (_doc.styleSheets[0]) ? _doc.styleSheets[_doc.styleSheets.length-1] : _doc.createStyleSheet(); _sheet.addRule('body', 'zoom: ' + newvalue +'%!important;'); event.returnValue = false; event.cancelBubble = true; } } ); el.runtimeStyle.behavior = 'none'; })(this)); }