JQPlot(查看剧情图片)在Firefox中打破 [英] JQPlot ( view plot image ) breaks in Firefox

查看:188
本文介绍了JQPlot(查看剧情图片)在Firefox中打破的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

出于某种原因,jqplot无法在firefox中呈现图像。



它只是在图像脚本的第182行崩溃,我看不到任何可能的问题。 p>

当我在chrome中运行完全相同的函数时,效果非常好。



以前从未遇到过这个问题。 >

我最近切换到OSX,认为它可能与这个操作系统上的firefox有关。



如果有人知道一个解决方案,请让我知道。



我会发布一个更新,如果我弄明白自己。解决方案

这个问题很可能是用writeWrappedText()函数中的这段代码来实现的:

pre $ var i = 0; i w + = words [i];
if(context.measureText(w).width> tagwidth){
breaks.push(i);
w ='';
i--;


$ / code $ / pre

评论我 - 为我解决了这个问题。

For some reason jqplot can't render images in firefox.

It just crashes on line 182 of the image script with no plausible problem I can see.

When I run the exact same function in chrome it works perfectly.

Never had this problem before.

I recently switched to OSX, think it might have something to do with firefox on this os.

If anyone knows of a solution please let me know.

I will post an update if I figure it out myself.

解决方案

The issue is likely with this piece of code in writeWrappedText() function:

for (var i=0; i<wl; i++) {
    w += words[i];
    if (context.measureText(w).width > tagwidth) {
        breaks.push(i);
        w = '';
        i--;
    }  
}

Commenting out i-- solves the issue for me.

这篇关于JQPlot(查看剧情图片)在Firefox中打破的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆