From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/64683 Path: news.gmane.org!not-for-mail From: Marco Pessotto Newsgroups: gmane.comp.tex.context Subject: What's the proper way to typeset a slash in a text flow? Date: Tue, 21 Dec 2010 00:34:42 +0100 Message-ID: <87fwtsaui5.fsf@universe.krase.net> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1292888127 16008 80.91.229.12 (20 Dec 2010 23:35:27 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 20 Dec 2010 23:35:27 +0000 (UTC) To: ntg-context@ntg.nl Original-X-From: ntg-context-bounces@ntg.nl Tue Dec 21 00:35:23 2010 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PUpGE-0008Re-HU for gctc-ntg-context-518@m.gmane.org; Tue, 21 Dec 2010 00:35:22 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 1CDEDCA90C; Tue, 21 Dec 2010 00:35:21 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id wKbkfHdT7diI; Tue, 21 Dec 2010 00:35:18 +0100 (CET) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 8BE56CA8E8; Tue, 21 Dec 2010 00:35:18 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 88608CA8E8 for ; Tue, 21 Dec 2010 00:35:16 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id dCDpfJZpBAd2 for ; Tue, 21 Dec 2010 00:35:14 +0100 (CET) Original-Received: from filter2-nij.mf.surf.net (filter2-nij.mf.surf.net [195.169.124.153]) by balder.ntg.nl (Postfix) with ESMTP id 5293BCA8E3 for ; Tue, 21 Dec 2010 00:35:14 +0100 (CET) Original-Received: from lo.gmane.org (lo.gmane.org [80.91.229.12]) by filter2-nij.mf.surf.net (8.14.3/8.14.3/Debian-5+lenny1) with ESMTP id oBKNFvAK015109 for ; Tue, 21 Dec 2010 00:15:58 +0100 Original-Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1PUpG3-0008O5-Pc for ntg-context@ntg.nl; Tue, 21 Dec 2010 00:35:11 +0100 Original-Received: from 78-2-47-235.adsl.net.t-com.hr ([78.2.47.235]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 21 Dec 2010 00:35:11 +0100 Original-Received: from melmothx by 78-2-47-235.adsl.net.t-com.hr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 21 Dec 2010 00:35:11 +0100 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 47 Original-X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: 78-2-47-235.adsl.net.t-com.hr User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux) Cancel-Lock: sha1:HmiGGn6KyR1v+WqYXRxS+XvFbEE= X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=80.91.229.12; country=NO; latitude=62.0000; longitude=10.0000; http://maps.google.com/maps?q=62.0000,10.0000&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 0aDJzfVPd - ddf94dca7e92 - 20101221 X-Scanned-By: CanIt (www . roaringpenguin . com) on 195.169.124.153 X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.12 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl Xref: news.gmane.org gmane.comp.tex.context:64683 Archived-At: See the following minimal example (I'm not trying to typeset urls or filesystem paths in this way, just regular text): %%%%%%%%%%%%%%%%%%%%%%%%%%%% \def\myslash{/\penalty-5000} \starttext \type{/} {\bfd Love/Hate/Play/Love/Hate/Play/Love/Hate/Play/Love/Hate/Play} \type{\slash} {\bfd Love\slash Hate\slash Play\slash Love\slash Hate\slash Play\slash Love\slash Hate\slash Play\slash Love\slash Hate\slash Play} \type{\textslash} {\bfd Love\textslash Hate\textslash Play\textslash Love\textslash Hate\textslash Play\textslash Love\textslash Hate\textslash Play\textslash Love\textslash Hate\textslash Play} \type{\myslash} {\bfd Love\myslash Hate\myslash Play\myslash Love\myslash Hate\myslash Play\myslash Love\myslash Hate\myslash Play\myslash Love\myslash Hate\myslash Play} \stoptext %%%%%%%%%%%%%%%%%%%%%%%%%%%% Neither one of the first three solutions above give me the right thing, because the line won't break at /. What am I missing? A workaround seems to be \def\myslash{/\penalty-5000} and then using \myslash instead of \slash, but I'm pretty sure I'm not doing this right. Thanks in advance -- Marco ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________