CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Perl Programming Help: Intermediate:
What GUI to use?

 



PapaGeek
User

Mar 7, 2014, 5:22 AM

Post #1 of 7 (3286 views)
What GUI to use? Can't Post

 
Iím working on a program that I will describe at the end of this post. I will make the source available to anyone interested when it is complete.

I started working with the Win32::GUI Perl package, but have run into a few roadblocks and the online documentation is rather lacking so I want to switch GUIs and Iím asking the group what one they recommend. Other than the standard text and input fields with the update, execute, cancel and done buttons, I need three other controls:

A reasonable calendar so I can ask the user what date he wants the output charts generated for . . . I can see what happened over the last 6 months, what did the charts look like 6 months ago?

A progress bar widget that I can update click by click as I look up data on the internet. Each symbol I look up can take up to 10 seconds, and if Iím creating multiple charts at once, there can be a fairly large number of symbols.

A rich text of HTML display widget so I can display the resulting charts to the user without them going to the local Intranet site I create.

Most of the backend programming is done, I just have the front end to finish. I got the calendar working for Win32::GUI, but canít seem to get the progress bar or rich text box to function. So, Iím looking for another Perl supported GUI, like maybe Tk, to create my front end. So, here is the full description of the program I am working on:

Mutual Fund Screener

The goal of the screener is to display the following table for each 401K, IRA, and brokerage account that you own.


Code
3m 6m 1Y 3Y 5Y Rank Symbol    Category   12/31/13   3 m  6 m  1Yr  3Yr  5Yr 
2 2 1 1 2 8 PPCIX Small Growth 15% 19% 48% 25% 25%
3 3 2 2 1 11 FSCRX Small Blend $10,000 13% 17% 44% 23% 30%
1 1 3 3 4 12 PSSIX Small Blend $10,000 15% 19% 43% 20% 22%
6 5 5 9 6 31 OAKIX Large Blend $10,000 11% 13% 37% 16% 22%
12 7 4 4 7 34 POGRX Large Growth $10,000 9% 13% 39% 18% 22%
8 6 7 6 8 35 NSEIX Mid-Cap Value 11% 13% 32% 17% 21%
5 9 9 5 9 37 FUSVX Large Blend 11% 12% 30% 18% 18%
10 8 8 8 3 37 NMCIX Mid-Cap Growth $10,000 10% 12% 31% 16% 23%
9 10 6 7 5 37 MPSIX Mid-Cap Blend 10% 11% 32% 17% 22%
4 4 10 12 12 42 ICEIX Foreign Large Blend 13% 15% 26% 9% 16%
7 11 13 13 10 54 HLMIX Foreign Large Growth 11% 8% 16% 9% 17%
13 13 11 10 11 58 BEGIX Large Value 8% 7% 23% 15% 16%
11 12 12 11 13 59 RLBGX Moderate Allocation 9% 8% 21% 14% 15%
14 14 14 14 14 70 MACIX Conservative Allocation 5% 4% 9% 8% 11%
16 19 15 16 16 82 SDGIX World Bond 1% -1% 0% 4% 8%
15 18 19 15 15 82 PTTRX Intermediate-Term Bond 3% -1% -1% 4% 8%
18 15 16 18 18 85 VSGDX Short Government 1% 0% 0% 1% 3%
19 16 17 19 20 91 AKGXX Money Market-Taxable 0% 0% 0% 0% 0%
17 20 20 17 17 91 VIPSX Inflation-Protected Bond 1% -4% -8% 3% 7%
20 17 18 20 19 94 FRTXX Money Market-Taxable 0% 0% 0% 0% 0%
$50,000


The table shows all of the market symbols you are allowed to invest in for each account you own. The symbols are ranked in an order that you define based on the percentage returns of each investment over various time periods. It also shows how much you have invested in each market and the investment class category of each market. You can then use this information to move money from one investment to another periodically as you desire.

The process uses an ODBC backend database to hold the lists of your accounts, symbols you follow, how much is invested where, etc. It screen scrapes yahoo finance historical quote data to determine the various rates of return for each time frame. The interface to the database and the web data is currently done via a series of win32 menus (but I canít get everything to work!). The output of the process can be viewed within the menu scheme (not working) and is also created on disk as a series of Intranet pages.


FishMonger
Veteran / Moderator

Mar 8, 2014, 7:22 AM

Post #2 of 7 (3235 views)
Re: [PapaGeek] What GUI to use? [In reply to] Can't Post

Tk is the only GUI framework I've used and that was 5 to 8 years ago, so I can't say how much better/easier it is or isn't when compared to the other frameworks. But it's worth a try.

Part of the decision between the GUI choices will depend on whether you need or want it to be platform independent. Obviously, since you started out with Win32::GUI, you probably don't care if it's platform independent. However, if you choose to make the app available to others, platform independency could be very desirable.

Besides Tk and based on recommendations from others, either Wx or Gtk2 would be good platform independent choices.


BillKSmith
Veteran

Mar 8, 2014, 3:10 PM

Post #3 of 7 (3228 views)
Re: [FishMonger] What GUI to use? [In reply to] Can't Post

Like FishMonger, I have only used Perl/Tk and was impressed by it. Note however that ActiveState no longer includes it in perl or ppm because they consider it unsupported. It probably is not a good choice for a new project.
Good Luck,
Bill


Laurent_R
Veteran / Moderator

Mar 8, 2014, 3:11 PM

Post #4 of 7 (3226 views)
Re: [FishMonger] What GUI to use? [In reply to] Can't Post

Same for me, TK is the only GUI I have used, and it was even longer ago (13 to 15 years ago). I can't say anything about the others, but TK was great (even though the look and feel might be slightly outdated by today's standards, but do you really care about transparencies and other modern (and quite useless in my view) features?)


FishMonger
Veteran / Moderator

Mar 8, 2014, 6:16 PM

Post #5 of 7 (3215 views)
Re: [BillKSmith] What GUI to use? [In reply to] Can't Post


In Reply To
Like FishMonger, I have only used Perl/Tk and was impressed by it. Note however that ActiveState no longer includes it in perl or ppm because they consider it unsupported. It probably is not a good choice for a new project.


I'm not sure I agree with that last portion of your comment. It's true that Tk had a period of time where it wasn't being supported after Nick Ing-Simmons (the original author) died, but I just checked cpan and see lots of the modules (at least the docs) were updated in Jan 2014. Most of those were updated by Slaven Rezic. It's possible but highly doubtful that he only updated the documentation and did nothing with the actual code.


PapaGeek
User

Mar 9, 2014, 1:24 PM

Post #6 of 7 (3033 views)
Re: [FishMonger] What GUI to use? [In reply to] Can't Post

Thanks to all for your replies, I am making the switch to Tk. Has most of the features I need and I just started a new thread for the one, hopefully simple, things I need; the ability to have one menu call another, then return.


BillKSmith
Veteran

Mar 9, 2014, 4:34 PM

Post #7 of 7 (2997 views)
Re: [PapaGeek] What GUI to use? [In reply to] Can't Post

I found the O'Reilly book "Mastering Perl/Tk" to be extremely helpful.
Good Luck,
Bill

 
 


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives