From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id YAgrDQxaU2CUXgAA0tVLHw (envelope-from ) for ; Thu, 18 Mar 2021 13:47:56 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id kDTnCAxaU2BqDwAAB5/wlQ (envelope-from ) for ; Thu, 18 Mar 2021 13:47:56 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 8E47925C2F for ; Thu, 18 Mar 2021 14:47:55 +0100 (CET) Received: from localhost ([::1]:43798 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lMt0D-0000Be-Oj for larch@yhetil.org; Thu, 18 Mar 2021 09:47:53 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:46126) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lMsv7-000661-8x for emacs-orgmode@gnu.org; Thu, 18 Mar 2021 09:42:37 -0400 Received: from mail-lf1-x134.google.com ([2a00:1450:4864:20::134]:40935) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lMsv5-00026K-Aw for emacs-orgmode@gnu.org; Thu, 18 Mar 2021 09:42:36 -0400 Received: by mail-lf1-x134.google.com with SMTP id a198so4663833lfd.7 for ; Thu, 18 Mar 2021 06:42:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:date:from:to:subject:user-agent:message-id; bh=h9XFTLzUWrEPbKcVR2ge96Lm17yen9fwEuwcbKtLlwM=; b=Eo8ulPnFS37E5ovOm5mQh7zsltR7bpHgzws6LWEvlmfc4aKJCcctJeHXvC+pRsCPHD REi6nTvpMtv/VYEB41d5VajwKfrcgjKlRUmG4gl+x3B/W1TgOaoSSSCiKM2aWk6BVTy2 Kr1jCYXH+uJNAkNlLZayLkQJXNts7BrjaG8xITZZurihpxGa5SY9pNE4Umo2X09YLZhu +T4w6Gh/1zQrUZVZ3FMj6rneUCXDAp11LqPadzxnAsR4wLF9IFwW1bNbVi5H6onD93Pp wLcupUL0htVougm9H/ewLhZsC+TmicQvX8UdfTIhvuIDWozli3DwFJWsukb+fikXrKG+ Pr1w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:date:from:to:subject:user-agent :message-id; bh=h9XFTLzUWrEPbKcVR2ge96Lm17yen9fwEuwcbKtLlwM=; b=SHqUN3JoH16xuDWiKGmumyxwoEwDE5c6Kz8wKtQWCh48wlntwvNUKM6y871dAUNsKB 7FqmM1xJjkTY3xmkKA6F/Lt1jQP/Myp/1lCSqCSLXdWAXtWrT7yQromHW7BxtA5KqRm1 eY2z3m+ThpSo7vEvqIpK8rr6KNQ4pFT4/yNASJsApsUCImUgmd+TGB5qXfa5y0piqV+3 nTnakk2QDOKqeNkEIBsULSWYen75T8/0dBlwWDCPAYgb5xCdUehmva0MlZjLJ7Ga2Sna HUWfZW6yzdIwAv0UNHvWAHcFvWbYI5XnQAYRmqItSFczDwHndfpwrbM1VzYpXxyARyF9 MBpg== X-Gm-Message-State: AOAM533CCehANK6WKrmWlAI0XaN9YggA20Prfur1i3v2oDu2Rj9ka/i2 p72z5JA63CFRnloWEDmHLyZm5D5AwkJ/mg== X-Google-Smtp-Source: ABdhPJy/L5bvfMqT2ycJxtwS+8ZcmBxtaONVCJeQfAkQ39JvvQ8gXDL9IFC+HjSkQCX05t4z4z1g+Q== X-Received: by 2002:a19:3f04:: with SMTP id m4mr5385011lfa.395.1616074952590; Thu, 18 Mar 2021 06:42:32 -0700 (PDT) Received: from m.g.s.chen.ac (cm-84.214.37.174.getinternet.no. [84.214.37.174]) by smtp.gmail.com with ESMTPSA id p10sm249098ljg.99.2021.03.18.06.42.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 18 Mar 2021 06:42:31 -0700 (PDT) MIME-Version: 1.0 Date: Thu, 18 Mar 2021 13:46:50 +0000 From: =?UTF-8?Q?Xianwen_Chen_=28=E9=99=88=E8=B4=A4=E6=96=87=29?= To: emacs-orgmode@gnu.org Subject: Exam LaTeX class User-Agent: Roundcube Webmail/1.4.10 Message-ID: X-Sender: xianwen.chen@gmail.com Content-Type: multipart/alternative; boundary="=_675bce66c0e61c8cd2680e19bb5e1fbd" Received-SPF: pass client-ip=2a00:1450:4864:20::134; envelope-from=xianwen.chen@gmail.com; helo=mail-lf1-x134.google.com X-Spam_score_int: -8 X-Spam_score: -0.9 X-Spam_bar: / X-Spam_report: (-0.9 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URI_DOTEDU=1.157 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1616075275; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=h9XFTLzUWrEPbKcVR2ge96Lm17yen9fwEuwcbKtLlwM=; b=K1m6dO6/7cjK4X3xOPrDzH7JoP1BAUctAtte/gNBlOtmsTco99hX0fzBDxFfO1C4mJQg2k i7gPPDFDox941vnn9KUpOveOyj/SzxKZ4B01E2OTUi7uhmcLbIhnDnQnNwAlnCB9B6MwBT n20NqyH3iSJDK5LMcS7zNxBCLk7lUjniGay4D8H9PM695ekWf38gRSnd2Xcwht9SviJ7kW dQ9c8hwGQGITTI6AA5zqM4LA6yFQy8jAchfoiWUsyBIAoHhi7m7jcRA8q7PGjROKvP1p9M ILJXuhHt4l2GAM9P3RAEEBhoTBV+kMQp1fNv3Rxl1UqVL989r7VANddVKkgI+A== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1616075275; a=rsa-sha256; cv=none; b=E7LDK2cvPZifvnbtyOznvasm7C2pSDXr9iZVmJw0ENXaSTv4I7mkJ0Jt7+dlPL+0c4pweg PkgMwOk8H0NcE2SoMrGkZ4D9PuyVy9hb5H8GCn5dt8ejFh/5O2L+UlQXtH9vngPgrpeZhu KAAaQiDMGxUUAZFgzvLopMa85QZajiPJzTgsRTCyrxZBiTDQ3wSToXq69xWrjVk2t7M6yE t9S3vmPj6ADxvy2R9bLpbcgbg7S409nWJaww4hxQu1OsY/BezkuKqj0J9KxqzTm5tuZzBe mtfoy0ciOD4l09zw2idHmbj6MGXI4InvP+GHjyaXUzkaYwwkSo5lMmCEWqGEQg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20161025 header.b=Eo8ulPnF; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Spam-Score: -3.11 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20161025 header.b=Eo8ulPnF; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Queue-Id: 8E47925C2F X-Spam-Score: -3.11 X-Migadu-Scanner: scn0.migadu.com X-TUID: 57qs0XIrxA3/ --=_675bce66c0e61c8cd2680e19bb5e1fbd Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII; format=flowed Does someone have experiences with the exam LaTeX class: http://www-math.mit.edu/~psh/exam/examdoc.pdf? I made a simple hack to make it work, by adding the following lines to the .emacs file: (add-to-list 'org-latex-classes '("exam" "\\documentclass{exam}" ("\\section{%s}" . "\\section*{%s}") ("\\subsection{%s}" . "\\subsection*{%s}") ("\\subsubsection{%s}" . "\\subsubsection*{%s}") ("\\paragraph{%s}" . "\\paragraph*{%s}") ("\\subparagraph{%s}" . "\\subparagraph*{%s}"))) The next step I'm trying to do, but don't know how, is to ask LaTeX exporter to create two exports to PDF. One export is the usual export. The other export is to have [answers] in \documentclass, which in LaTeX will be: \documentclass[answers]{exam} When answers is specified, the resulted PDF will include the solutions that are preset in the solution environments. The switch of printing or hiding solution environments can also be achieved by one of the following preamble codes: \printanswers or \noprintanswers. I guess one way is to modify the org-latex-export-to-pdf function, so that when the document class is exam, the exporter first export without solutions, and then export to an other PDF file (such as foo-with_solutions.pdf). But maybe someone else has hacked on the exam document class as well and would like to share their experiences? Xianwen --=_675bce66c0e61c8cd2680e19bb5e1fbd Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=UTF-8

Does someone have experiences with the exam LaTeX class: http://www-math.mit.edu/~psh/exa= m/examdoc.pdf?

I made a simple hack to make it work, by adding the following lines to t= he .emacs file:

(add-to-list 'org-latex-classes
'("exam"
"\\documentclass{exam= }"
("\\section{%s}" . "\\section*{%s}")
("\\subsection{%s}" . "\\= subsection*{%s}")
("\\subsubsection{%s}" . "\\subsubsection*{%s}")
("\\paragraph{%s}" . "\\paragraph*{%s}")
("\\subparagraph{%s}" . "\\= subparagraph*{%s}")))

The next step I'm trying to do, but don't know how, is to ask LaTeX expo= rter to create two exports to PDF.

One export is the usual export.

The other export is to have [answers] in \documentclass, which in LaTeX = will be:

\documentclass[answers]{exam}

When answers is specified, the resulted PDF will include the solutions t= hat are preset in the solution environments.

The switch of printing or hiding solution environments can also be achie= ved by one of the following preamble codes: \printanswers or \noprintanswer= s.

I guess one way is to modify the org-latex-export-to-pdf function, so th= at when the document class is exam, the exporter first export without solut= ions, and then export to an other PDF file (such as foo-with_solutions.pdf)= =2E

But maybe someone else has hacked on the exam document class as well and= would like to share their experiences?

Xianwen

--=_675bce66c0e61c8cd2680e19bb5e1fbd--