From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM autolearn=unavailable autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!news.eternal-september.org!news.eternal-september.org!feeder.eternal-september.org!aioe.org!.POSTED!not-for-mail From: =?utf-8?Q?Yannick_Duch=C3=AAne_=28Hibou57?= =?utf-8?Q?=29?= Newsgroups: comp.lang.ada Subject: Re: Web-UI for Ada applications Date: Wed, 28 Aug 2013 17:54:22 +0200 Organization: Ada @ Home Message-ID: References: <20130827230816.535a440d@atmarama.noip.me> <20130828105441.7d5d5943@atmarama.noip.me> <87ioyq6tuf.fsf_-_@adaheads.sparre-andersen.dk> <20130828124830.46f645e1@atmarama.noip.me> NNTP-Posting-Host: bsJIecVz+tRSOZwqdVlFPg.user.speranza.aioe.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed; delsp=yes Content-Transfer-Encoding: Quoted-Printable X-Complaints-To: abuse@aioe.org User-Agent: Opera Mail/12.16 (Linux) X-Notice: Filtered by postfilter v. 0.8.2 Xref: news.eternal-september.org comp.lang.ada:17024 Date: 2013-08-28T17:54:22+02:00 List-Id: Le Wed, 28 Aug 2013 13:32:43 +0200, Simon Clubley = a =C3=A9crit: > On 2013-08-28, Gour wrote: >> On Wed, 28 Aug 2013 11:35:36 +0200 >> Jacob Sparre Andersen wrote: >> >>> The problem with this is that you both add an extra "OS" layer (the >>> browser) _and_ require GUI operations to be interpreted (to some >>> extent) rather than executed as binary code. >> >> I'm not sure I get the 2nd part? >> > > When a program which uses, say, the GTK toolkit wants to draw a text b= ox > on the screen, it does it by making a direct subroutine call to the > GTK function from the program itself. > > OTOH, if you use HTML input to render a text box in the browser, then = the > HTML code is treated as source code input to the browser's rendering > engine and needs to first be translated to a internal format before th= e > rendering engine can process the HTML code. > > IOW, every time the rendering engine reads the HTML input, it needs to= > treat it in the same way as, say, a Python or bash interpreter would > treat it's input. Not an issue if the page's content is kept reasonably small. No UI is = handy when it presents a too big page or too many things anyway. There i= s = an issue with, as an example, long text documents (I did such an = application in the past, an XML editor, but with FPK, not Ada), but I = believe the issue here is the editor specification (the editor is just a= n = example), which should not be expected to display a = mega=E2=80=91characters/mega=E2=80=91bytes document as a single piece, a= nd something is = broken in what we expects from some UI. The issue was not the browser in= = such, it was my lack of proper analysis at design time (well, I was awar= e = of this potential issue, but had to save time=E2=80=A6 that was the real= reason = why). Software components should always be designed like Ada types are designe= d, = I mean, with real world constraints and limitations in mind, and that's = = applicable to UI too. If you design an UI as na=C3=AFvely as most progra= mming = languages let you =E2=80=9Cdesign=E2=80=9D numeric types, letting you be= lieve there is no = limitation and you don't have to bother about it, you will get some = issues, inevitably (*). If you do the Ada way, and think bounds and = constraint when designing the UI, you may get ride of parts of the issue= = you are pointing. Computation cost of a typical, is ridiculously small (I don't count = multimedia rendering, which is not part of the UI to me, although it may= = be a component hosted in an UI). (*) Although I my self did the same error at one time, it always been = astonishing to me, all editors I known, tries to open a thousand = mega=E2=80=91bytes document with no proper handling or limitations, and = that's = obviously even more an issue in an UI running in a web=E2=80=91browser, = but that = still not the real issue to me, as I feel the real issue, is to believe = it = can be expected to work fine this way. It can't. -- = =E2=80=9CSyntactic sugar causes cancer of the semi-colons.=E2=80=9D [1] =E2=80=9CStructured Programming supports the law of the excluded muddle.= =E2=80=9D [1] [1]: Epigrams on Programming =E2=80=94 Alan J. =E2=80=94 P. Yale Univers= ity