Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

color_show and ImageGrid don't render properly in Spyder or Ipython QTconsole #33

Open
lwasser opened this issue Dec 31, 2014 · 7 comments

Comments

@lwasser
Copy link

lwasser commented Dec 31, 2014

Hi All,
this is an interesting bug. When i attempt to render a grid using ImageGrid, i get space where the grid should render in the console BUT no grid. Or i get a series of lines - one line for each cell with the appropriate assigned colors, however no actual cells. this issue is a bit baffling because it works perfectly in notebook. doesn't it all just use the ipython renderer?

for example, this code doesn't render:
from ipythonblocks import ImageGrid
grid = ImageGrid(5, 3)
grid.show()

This code renders lines:
row = ImageGrid(8, 1)
row[0, 0] = (0, 0, 0) # no color => black
row[1, 0] = (255, 255, 255) # all colors => white
row[2, 0] = (255, 0, 0) # all red
row[3, 0] = (0, 255, 0) # all green
row[4, 0] = (0, 0, 255) # all blue
row[5, 0] = (255, 255, 0) # red and green
row[6, 0] = (255, 0, 255) # red and blue
row[7, 0] = (0, 255, 255) # green and blue
row.show()

Everything works perfectly in notebook so i understand if this is a notebook focused package!
thank you
Leah

@jiffyclub
Copy link
Owner

ipythonblocks is definitely browser oriented--the tables are rendered as HTML tables and include CSS styles.The Notebook is the only "supported" platform for ipythonblocks. But if anyone familiar with Spyder or the QT console would like the comment, the info would be welcome.

@gvwilson
Copy link

gvwilson commented Jan 2, 2015

Is there a "save as PNG" option?

@jiffyclub
Copy link
Owner

If you install from GitHub, yes. See the save_image function. I apparently forgot to make a release with that included.

@gvwilson
Copy link

gvwilson commented Jan 2, 2015

Do you have time to make a release that include save_image? Or can we
ask @r-gaia-cs to do it?
Thanks,
Greg

@jiffyclub
Copy link
Owner

Should be able to make one today.

@jiffyclub
Copy link
Owner

@gvwilson New release of version 1.7.0 is up. https://pypi.python.org/pypi/ipythonblocks

@gvwilson
Copy link

gvwilson commented Jan 2, 2015

Thanks!
G

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants