LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 11-30-2008, 12:27 PM   #1
frog-o
LQ Newbie
 
Registered: Nov 2008
Posts: 13

Rep: Reputation: 0
Making a standardize library? (thoughts)


Who/What?

I would like to create create a standardize api that would work on all platform.

In short it would be an extension to the already
existing "c++ stander library ,c stander library, etc" so i can handle advance functionally like GUI controls, string manipulation,multi-threading etc.

*I would like it to be similar to wxwidgets in nature which i would like to base it off.
*I would like it to be a wrapper around other library.
*I would like it to be build from user input(It can't become a stander if nobody use it)


My goals would be different than wxwidgets thou here are my goals some of (witch some of wxwidgets has)

* easily portable
* built with namespace support(wxwidgets dose not do this because of non compliant ISO compilers.)
* dose not depend on qt or gtk (but can use it)
* don't put in extra code to run non compliant ISO stander compilers.
* small(this is why i don't want to support compliant ISO stander compilers)
* built in many section (many small .so for Linux, or dll for windows) to keep it organized

* ISO C compliant
* flexible (User designed)


Why

I think buy standardizing an api it will solve the 3 main problems I have with every libarys i ever use even thou not completely at least at first.

It will mean

1.)Less time reinventing the wheel.

Have you Every look at how much functionality qt and gtk share. They both deal alot with the gui. If they shared the same Api the be no need to have two differ programs like gedit and kwrite there could just be one writing program.

2.)less License worry while keeping code protected

If all programs use a stander api you can find the implementation of the library that suit you license need. While the maintainer of implementation code keep he code under what ever licenses he wants to.

3.) Less dependency

Think about this qt and gtk perty much offer the same functionality and this bring us back to 1 again. If people use a common api that can handle the functionality of both gtk and qt we would not need a program for qt and one for gtk.

where and when

I don't know if I'll every do this it depend on the amount of support I git off the web and my ability to organize which is not all that great.
If i ever did some thing i would like to place it on sourceforge.net.

The big questions?

I'm I the only one who want a standardize api ?

Is there enough demand to make this dream of mine come true?

What do people want in an api?
 
Old 11-30-2008, 12:37 PM   #2
ErV
Senior Member
 
Registered: Mar 2007
Location: Russia
Distribution: Slackware 12.2
Posts: 1,202
Blog Entries: 3

Rep: Reputation: 62
Quote:
Originally Posted by frog-o View Post
I would like to create create a standardize api that would work on all platform.
I don't think it will be possible. You can easily support several platforms, group of platforms, but not *all* platforms.

Quote:
Originally Posted by frog-o View Post
so i can handle advance functionally like GUI controls, string manipulation,multi-threading etc.
This was already done at least three times. Qt 4 is a nice example of such api. So why do you want to reinvent the wheel?
 
Old 11-30-2008, 01:44 PM   #3
ta0kira
Senior Member
 
Registered: Sep 2004
Distribution: FreeBSD 9.1, Kubuntu 12.10
Posts: 3,078

Rep: Reputation: Disabled
Boost is already in that business, so you have a lot of competition! My suggestion is to look at their site and see how to go about getting your projects added. I can tell you right now that that involves standardizing your API, releasing it under their license, then polling for interested parties to nominate (sponsor?) it for consideration. You won't get closer to de facto standard than Boost, except I don't think they have GUI things (not an area that should be standardized across OSes.)
ta0kira

PS C++ already is standardized; standardized so that it doesn't have to require compiler designers to keep up with volatile areas such as threading and GUIs, and so that the standard itself doesn't have to come up with a compromised API suitable for all types of each, which would make all ineffective (and would generally neutralize the more subtle benefits of specific systems.)

Last edited by ta0kira; 11-30-2008 at 01:49 PM.
 
Old 11-30-2008, 04:31 PM   #4
frog-o
LQ Newbie
 
Registered: Nov 2008
Posts: 13

Original Poster
Rep: Reputation: 0
There are some confuse-tion going on here please let me explain:

ErV wrote
Quote:
Originally Posted by ErV View Post
I don't think it will be possible. You can easily support several platforms, group of platforms, but not *all* platforms.


This was already done at least three times. Qt 4 is a nice example of such api. So why do you want to reinvent the wheel?

First when i say "all" it is a goal which is something I realize is far out there and never can reach but, something to strive for.

Second if you use quick time you dome to use qt what if i want to use the gtk without changeing code?

This is why i said

Quote:
* dose not depend on qt or gtk (but can use it)
in my goals

If i have the gtk i what to use my library without qt installed.
If i have the qt i what to use my library without gtk installed.

I just want to create a wraper around qt,fltk,etc so it maps it to a stander api.(This would be like add qt warper to wxwidget , or to put in other words a port of wxwidgets wich use qt insted of gtk, wich has be mestion many times on wxwiget form and mailing list wich no one has addressed yet)


ta0kira wrote


Quote:
Boost is already in that business, so you have a lot of competition! My suggestion is to look at their site and see how to go about getting your projects added. I can tell you right now that that involves standardizing your API, releasing it under their license, then polling for interested parties to nominate (sponsor?) it for consideration.
you are right on there i probaly could use a lot of boost in my api
.
Quote:
You won't get closer to de facto standard than Boost, except I don't think they have GUI things (not an area that should be standardized across OSes.)
Why don't you think is should be standardize?


Quote:
PS C++ already is standardized;
I know that that why when of my goals of my api where to only use a stander iso compiler. Not all compiler follow the c++ standers.

Quote:
standardized so that it doesn't have to require compiler designers to keep up with volatile areas such as threading and GUIs, and so that the standard itself doesn't have to come up with a compromised API suitable for all types of each, which would make all ineffective (and would generally neutralize the more subtle benefits of specific systems.)
This might have ansewer my question above but i have no clue what you are try to say.

If your are say it would give an unnatural look. Look at wxwidgets That the desing i try base my implement on. I will not have that problem.




sorry about the above confuse-tion I have a hard time ex-sprec-ing my thoughts for 3 reason.

1) people don't understand what i try to get at(I try my best thou and i sorry I can't do better. I think in a whole new level ,even thou some think i don't think at all).

2) Do two the lack of free time people have to read form they try to skim read and miss alot of info

How can I get my point across when every one skim read?
Can anyone give me pointers?

3) I'm a horrible speller
 
Old 12-02-2008, 04:55 PM   #5
ta0kira
Senior Member
 
Registered: Sep 2004
Distribution: FreeBSD 9.1, Kubuntu 12.10
Posts: 3,078

Rep: Reputation: Disabled
Well, there is a certain implicit priority with public posting. The most important piece of info is the title, and if it doesn't contain a representative summary of the post's contents then people will go into it with an incorrect assumption. Second most-important are the topic sentences of your paragraphs and bullets. One should know what you're talking about in vague detail just by reading the first sentences of your paragraphs, with the latter paragraphs generally being less important, though normally one should get a good idea of what your post is about from the first and last paragraphs. One will get more detail by reading more sentences per-paragraph. While it isn't always "polite" to read things this way, it's generally how people read a long article or post if they have a lot to do or a lot else to read. If the strategically-read sentences spark an interest and reflect a new idea then people tend to re-read more closely to get a better idea of what you're talking about, otherwise they generally assume it's just a recombination of ideas they've pondered to death already.

Anyway, I do think it's interesting to standardize in the way you're talking about, but it's difficult to standardize GUIs and threads because different operating systems deal with that sort of thing in extremely different ways. Java already attempts to do this, but in a way that wouldn't work well with C++. Basically what you're trying to do is make the JRE C++-friendly, and maybe go so far as to make a specification out of it for others to creatively implement. Maybe you should just find a way to make Java work well with C++ in an OS-portable way! If you could do that then I might actually willingly use Java.
ta0kira
 
Old 12-03-2008, 11:57 AM   #6
frog-o
LQ Newbie
 
Registered: Nov 2008
Posts: 13

Original Poster
Rep: Reputation: 0
First Thank you ta0kira you been kind. Just to let you know i have read How To Ask a Question

http://www.linuxquestions.org/linux/...Ask_a_Question

I take yours and this post in great detail and appreciate you putting in the time.


I was hope to bring-up a heated response on this form of what people like in an standardize api as well as if they wanted such a thing. My dream was to have kde and gnome use the same utility use this type of api.

The reason I would what to do this is I think it would prevents blot,reduce dependency etc which i put in my bullets. To me it looks like i done what was asked to heat such a discussion but it flopped.

Just to give you a run down on my thoughts of how i meat what you post.

Quote:
Originally Posted by ta0kira View Post
Well, there is a certain implicit priority with public posting. The most important piece of info is the title, and if it doesn't contain a representative summary of the post's contents then people will go into it with an incorrect assumption.
I give much thought to my title, I think the one I give is good if you have a better please, let me know. I was think about try to post on other form as well such as wxwidgets (if i did not already do so i would have to check). I was think about try to post something on the Portland project, kde developer , gnome developer, mailing list etc.

Quote:
Second most-important are the topic sentences of your paragraphs and bullets. One should know what you're talking about in vague detail just by reading the first sentences of your paragraphs, with the latter paragraphs generally being less important, though normally one should get a good idea of what your post is about from the first and last paragraphs. One will get more detail by reading more sentences per-paragraph. While it isn't always "polite" to read things this way, it's generally how people read a long article or post if they have a lot to do or a lot else to read. If the strategically-read sentences spark an interest and reflect a new idea then people tend to re-read more closely to get a better idea of what you're talking about, otherwise they generally assume it's just a recombination of ideas they've pondered to death already.
Well I knew the above and tried to do that. My first sentence under My category

Who/What?

was

Quote:
I would like to create create a standardize api that would work on all platform.
which was the best way I thought of describing what i what to do in vague details.

How would you word it?

Quote:
Anyway, I do think it's interesting to standardize in the way you're talking about, but it's difficult to standardize GUIs and threads because different operating systems deal with that sort of thing in extremely different ways. Java already attempts to do this, but in a way that wouldn't work well with C++.
I think wxwidgets does this two which dose work well with c++ and keep a native look an feel( which is why I wanted to base my api off of it).
It keeps the code to make the program stander while keeping the code that implement the program specific to the os it run on.

I would say In my opinion wxwidgets dose what i want except for

1.) I don't think it flexible enough to listen to the demands of all users

Which i want to do. I want it design to be based of the demand of the user who would be interested in this idea(of a standardize api).
i was hoping to get design idea in this thread. I think it flopped.
Just to give you an example wxwidget dose not support namespace because they want to be compatible with all compilers,some compilers don't work with it. I think good free ISO compilers are easier to find know days if I'm not mistaken I think borland,gcc and even Microsoft new c++ compiler all support the ISO c++ stander. Microsoft be late in the game. Well i think they support the ISO stander ,I could be mistaken. I find it hard to tell.

I have yet been able to find any books or web site explaining c++ and the stander in plain text as well as full details. The best source of info was on www.cplusplus.com

2.) I don't think is easy to port

In short i think it design can be improved so it can be easy ported to other gui beside gtk an X wich it has port for.

To give you an example of what i try to say.

I tried to make a port of wxwidgets to qt a little myself and quick became aggravated buy all the ifdef that did not work, I don't think it is a good idea to implement it this way. I think it is better to derive a basic class with virtual function with default implementation of a function that are missing when ever possible instead of useing ifdef to cut them out and remove the derived class when done.


Quote:
Basically what you're trying to do is make the JRE C++-friendly, and maybe go so far as to make a specification out of it for others to creatively implement. Maybe you should just find a way to make Java work well with C++ in an OS-portable way! If you could do that then I might actually willingly use Java.
ta0kira

I do not know a-lot about Java. I know of the basic of JRE and Java bite-code but not much more but, basically yes that what i try to do. I try to have a native feel thou to the gui there using and go father than c++ and expand to other languages like wxwidgets did.
I don't think people will be willing to settle for java because of a native api.

Note:
I looking for way to revive this dead thread. I think that this idea is very good and is very important to me, but I have a hard time explaining it and getting people attention. I think other would like it two, if I could get there attention. If They don't like it I could let my idea go since there no way of implementing it. Even thou i think this type of thing would be said, because to me I don't see how any one could not want this unless people would rather fight than try to be creative and solve there differences. I think that such an api would bring much order to in my opinion a messy OS. A lot of people reinvent the same program because of a lack of a standardize api even thou licenses are part of the problem. If thing get implement my way i think it will solves most of people problems. I think if we work together we can make an api flexible enough to meat the needs of almost all user.

I just can't help but wondering what do i do now?
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: Will LSB 4 Standardize Linux? LXer Syndicated Linux News 0 08-01-2008 05:30 AM
LXer: Should Linux Standardize on a Single Distro? LXer Syndicated Linux News 1 05-05-2008 11:03 AM
Making a static library from a given shared library vro Programming 1 07-27-2007 04:07 PM
making a library andystanfordjason Programming 2 02-04-2007 04:30 PM
ANSI C: Math library making #include unnecessary? olspookishmagus Programming 3 11-01-2005 09:50 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 06:38 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration