Giter VIP home page Giter VIP logo

Comments (5)

GoogleCodeExporter avatar GoogleCodeExporter commented on July 18, 2024
Thanks for the suggestion Tibor, this is a good idea.  Some discussion about a
possible final change to PrettyTable 0.6 is currently under way in the
prettytable-devel mailing list.  Once this last issue is sorted out, 0.6 will be
released and I'll start work on 0.7, which will include new features.  I'll 
make sure
to have a go at implementing your feature for 0.7.

Original comment by [email protected] on 13 Jun 2009 at 12:04

  • Added labels: Type-Enhancement
  • Removed labels: Type-Defect

from prettytable.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 18, 2024
This functionality exists in trunk.  As far as I can tell, it works well.  I 
don't remember when it appeared there or who wrote it, but thank you to whoever 
did.  The syntax is:

table.max_width["fieldname"] = 42

Original comment by [email protected] on 1 May 2012 at 2:32

  • Changed state: Fixed

from prettytable.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 18, 2024
[deleted comment]

from prettytable.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 18, 2024
from prettytable import from_csv
fp = gzip.open(rawEventsFile, 'rb')
pt = from_csv(fp)
fp.close()
table = pt.get_string(fields=["_time", "host", "index", "linecount", "source", 
"sourcetype", "server", "tag::sourcetype"])
pt.max_width["_time"] = 14

Nothing happens

Any ideas ? 

Thanks

Szymon

Original comment by [email protected] on 17 Jul 2013 at 10:58

from prettytable.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 18, 2024
Are you caling get_string again after changing max_width?  "table" is just a 
string in your code above.  You can't change it by making changes to "pt".

Original comment by [email protected] on 17 Jul 2013 at 6:38

from prettytable.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.