From mboxrd@z Thu Jan 1 00:00:00 1970 From: Samuel Wales Subject: Re: fill-paragraph fills planning line; blank line possibility Date: Mon, 16 Mar 2020 14:15:13 -0700 Message-ID: References: <878sk0vy2z.fsf@nicolasgoaziou.fr> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:52478) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jDx4v-0006Ut-AD for emacs-orgmode@gnu.org; Mon, 16 Mar 2020 17:15:18 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jDx4u-0004N6-2K for emacs-orgmode@gnu.org; Mon, 16 Mar 2020 17:15:17 -0400 Received: from mail-lj1-x241.google.com ([2a00:1450:4864:20::241]:47048) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1jDx4t-0004Cm-PM for emacs-orgmode@gnu.org; Mon, 16 Mar 2020 17:15:15 -0400 Received: by mail-lj1-x241.google.com with SMTP id d23so20346336ljg.13 for ; Mon, 16 Mar 2020 14:15:15 -0700 (PDT) In-Reply-To: <878sk0vy2z.fsf@nicolasgoaziou.fr> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane-mx.org@gnu.org Sender: "Emacs-orgmode" To: Samuel Wales , emacs-orgmode@gnu.org thank you. i had it wrapped as follows. so i guess i ahve to test if i am in org mode or use funcall on fill paragraph fucntion or something. (define-key global-map "\M-q" 'alpha-fill-or-unfill-region-or-paragraph) (defun alpha-fill-or-unfill-region-or-paragraph () (interactive) (if (eq last-command this-command) (progn (alpha-unfill-region-or-paragraph) (setf this-command 'kludge)) (alpha-fill-region-or-paragraph))) (defun alpha-fill-region-or-paragraph () (interactive) (if (use-region-p) ;; fixme i want to not deactivate the region (call-interactively #'fill-region) (fill-paragraph nil))) On 3/16/20, Nicolas Goaziou wrote: > Hello, > > Samuel Wales writes: > >> recent maint -- but i have not got an mwe. i could be doing something >> wrong. >> >> * x >> SCHEDULED: <2020-03-15 Sun> >> mada wakaranai to omou kedo, ima no meeru wa sono koto asdfa muri ni >> suru kanosei ga aru. >> >> if i fill that using m-x fill-paragraph, it fills the planning line also. >> >> perhaps somebody might know what i am doing wrong or if this is a bug. > > You are using the wrong function. It should be `org-fill-paragraph'. > `fill-paragraph' knows nothing about Org syntax. Hence the result you > are observing. > > Regards, > > -- > Nicolas Goaziou > -- The Kafka Pandemic What is misopathy? https://thekafkapandemic.blogspot.com/2013/10/why-some-diseases-are-wronged.html