From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Yilkal Argaw Newsgroups: gmane.emacs.bugs Subject: bug#57131: regarding closing tags for non void html tags in html-mode skeletons Date: Fri, 12 Aug 2022 23:59:39 +0300 Message-ID: References: <87sfm1o5dz.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="24734"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 57131@debbugs.gnu.org To: Lars Ingebrigtsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Aug 12 23:00:54 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oMbm1-0006EP-99 for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 12 Aug 2022 23:00:53 +0200 Original-Received: from localhost ([::1]:35842 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oMbm0-0001u6-7X for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 12 Aug 2022 17:00:52 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:49736) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oMblC-0001gs-Qk for bug-gnu-emacs@gnu.org; Fri, 12 Aug 2022 17:00:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:41059) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oMblC-0005rN-HO for bug-gnu-emacs@gnu.org; Fri, 12 Aug 2022 17:00:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oMblC-0006Su-Cu for bug-gnu-emacs@gnu.org; Fri, 12 Aug 2022 17:00:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Yilkal Argaw Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 12 Aug 2022 21:00:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57131 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: notabug Original-Received: via spool by 57131-submit@debbugs.gnu.org id=B57131.166033799724813 (code B ref 57131); Fri, 12 Aug 2022 21:00:02 +0000 Original-Received: (at 57131) by debbugs.gnu.org; 12 Aug 2022 20:59:57 +0000 Original-Received: from localhost ([127.0.0.1]:59039 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oMbl7-0006S9-0v for submit@debbugs.gnu.org; Fri, 12 Aug 2022 16:59:57 -0400 Original-Received: from mail-yw1-f179.google.com ([209.85.128.179]:44951) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oMbl5-0006Rv-Pa for 57131@debbugs.gnu.org; Fri, 12 Aug 2022 16:59:56 -0400 Original-Received: by mail-yw1-f179.google.com with SMTP id 00721157ae682-31f661b3f89so21019247b3.11 for <57131@debbugs.gnu.org>; Fri, 12 Aug 2022 13:59:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc; bh=RpZiuFSM41hiN5k0QBF3TBl4yo++xJpd+Kh3UJSatc0=; b=ZKQAM3P7qPXg4sChwA0xl4wmRbs8YTUtgvL4wKkjTXURtqmnV+4w/qq7lsdZud/V0K TEY1y7eteGpartiXpcgWg9eELU7U5i+lm65RlEYFXm+c1n6Xqvz6xCzHkmPSN9+3Hf/p VO6cE5dxAXxYBS31aC3nMxb3e/OnxCDrgWzmPv67kXPJG8s6bHOz63bhPWVTMe8Dyxdw HyIRDsMg5muhk1tmoBA+cwl5VthKQ28KZx1ViadAgNFGweDcPre0VzuKizF/5NeJBqg9 qhnbfPhtZqfk0r2020oVeG0bvLJo/wLvL2OyiTBYhWo5ADbk20gV8iT7zlv9ZwZ42G0X SEQQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc; bh=RpZiuFSM41hiN5k0QBF3TBl4yo++xJpd+Kh3UJSatc0=; b=Yzmf/svIcmIcc+nDFWNPKotF2IrwRuaY+Zj5V3tpjcVcBmkLjb559ROnW7C7HOoC61 tXwlUrgy6D3SQUbZ3QqB1Ihym+dF9uMEFhKjKhg/R0VEXH6/atAy0z2WVsf+qN1MjSrH IzUusTK+1Phxn2bBZNc3GHQ+gy7hX2P6dJZ/jPBT3OyJcErI9b8qW/D2SCUlerNZckCL nCcE1+jy5QRp80erEBKjV7yMHFvHci/2zlRzh7LLhrbRLJySU+XqW/rrdo3hhlTA3z0v xdknDi3Gl9yRSlHCOXFCXWfj0LpslPjEfYW5OqOllDeyc3cCDLT8SimQV75OThGviDAC jkfQ== X-Gm-Message-State: ACgBeo2I0kDf4evDBz7cHf6O66HOjtZ86QheHxEWzJbsg5PwBnVxJHPh lz+2k1D0QdCx1UPjQ8ArzsbTqfopJqdQyIhWFvk1CgujxX4= X-Google-Smtp-Source: AA6agR4pTrjBI6JvkxLv1SN2X6xeJa5AxBcsPe3k8W75SQgkw05BorvAQ251Px6U4J9XrbGFjVZvj249CkjCt4gjuHs= X-Received: by 2002:a81:71c6:0:b0:318:38d5:37f3 with SMTP id m189-20020a8171c6000000b0031838d537f3mr5239491ywc.268.1660337990276; Fri, 12 Aug 2022 13:59:50 -0700 (PDT) In-Reply-To: X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:239467 Archived-At: Hi > No, that's not the convention used in "modern html". Quite the opposite. Sorry if I am wrong. I will list the reasons for what I said. I am not trying to make this into a debate but I am listing them if they make my argument clearer. 1. The wording in the HTML5 standard optional tags section Reference Link: https://www.w3.org/TR/2018/SPSD-html5-20180327/syntax.html#optional-tags The wording used in this specification is that the aforementioned closing tags may be omitted. There is no enforcement or recommendation on this behavior. So a user is able to choose on the behavior that one requires and it would not make the code XML. So the editor should not limit this option for XML code only. Note: I am not talking about treating html and xml the same. I am also not referring to tags that are labeled as void-elements in the HTML5 standard but require closing tags on XML. I don't want to close tag for example but I might prefer to have closing tags for

  • and so on. So what I was referring to was having a variable like html-close-optional-tags or html-close-optional-tags-alist which will allow the user to specify this behavior instead of just saying go to use xml-mode if you need this behavior. 2. This is how other tools do it so I may not be the only one who prefers to close my list-items and paragraphs. - Web Mode in Emacs - Emmet on Emacs - VS code - Cuda text - Atom (RIP) - Bluefish Editor - Sublime Text 3 - Vim (vim-closetag plugin) I have even looked into the html source of w3.org and the close their
  • ,

    and tags. With Regards Yilkal A. On Fri, Aug 12, 2022 at 11:56 PM Yilkal Argaw wrote: > > Hi > > > No, that's not the convention used in "modern html". Quite the opposite. > > Sorry if I am wrong. I will list the reasons for what I said. I am > not trying to > make this into a debate but I am listing them if they make my argument clearer. > > 1. The wording in the HTML5 standard optional tags section > Reference Link: > https://www.w3.org/TR/2018/SPSD-html5-20180327/syntax.html#optional-tags > The wording used in this specification is that the > aforementioned closing tags > may be omitted. There is no enforcement or recommendation on > this behavior. > So a user is able to choose on the behavior that one requires > and it would not > make the code XML. So the editor should not limit this option for XML code > only. > > Note: I am not talking about treating html and xml the same. I am also > not referring > to tags that are labeled as void-elements in the HTML5 > standard but require > closing tags on XML. I don't want to close tag for > example but I might > prefer to have closing tags for

  • and so on. So > what I was referring > to was having a variable like html-close-optional-tags or > html-close-optional-tags-alist > which will allow the user to specify this behavior instead > of just saying go to use > xml-mode if you need this behavior. > > 2. This is how other tools do it so I may not be only one who prefers > to close my > list-items and paragraphs. > - Web Mode in Emacs > - Emmet on Emacs > - VS code > - Cuda text > - Atom (RIP) > - Bluefish Editor > - Sublime Text 3 > - Vim (vim-closetag plugin) > > I have even looked into the html source of w3.org and the close > their
  • ,

    and tags. > > With Regards > Yilkal A. > > On Fri, Aug 12, 2022 at 6:20 PM Lars Ingebrigtsen wrote: > > > > Yilkal Argaw writes: > > > > > The problem with using them is that they would not > > > generate closing tags for many of the tags (like

  • because it > > > is assumed that only xml needs closing tags and the closing pairs are > > > controlled by the variable sgml-xml-mode. There should be a variable > > > to control this behaviour > > > > The variable that controls this is `sgml-xml-mode', so just set that to > > a non-nil value if you prefer these functions to insert close tags. > > > > > because the convention used widely in modern > > > html is to close tags as long as they are not "void elements". > > > > No, that's not the convention used in "modern html". Quite the opposite. > > > > > This behaviour is even assumed in the indentation behaviour that it > > > causes weird indentation when inserting the something like list items > > > inside unordered list. > > > > If something is doing that, then it's not parsing HTML properly. HTML > > isn't XHTML. > > > > I don't see anything to fix here, so I'm closing this bug report.