macros

How to keep material on one double page in latex ?

I have two side document(so I use twoside option) in latex. I need to keep some material(text, pictures...) on one double page. In another words I want to allow page break from odd to even page but I want to prohibit breaks from even to odd page. I tried to write macro: \newcommand{\nl}{ \\ \ifodd\c@page \relax \else \nopagebreak \fi} ...

DocBook macros?

Is there any way of defining macros (like tex macros o latex defines) in DocBook documents? DocBook is very verbose, and macros would help a lot. I didn't find them in quickstart tutorials. If so, could anyone provide a simple example or a link to? Thanks ...

WORD 2003 - Adding Hyperlinks to other files....can I use currentpath in the hyperlink

I have a document that is an overview document within a folder, there are numerous related documents in a folder that is also in the folder that contains the overview document. I would like to reference these documents throughout the overview document and allow those to be selected and viewed by clicking. so i was going to use a hyperl...

Is there unresizable space in latex? Pictures in good looking grid.

I've created latex macro to typeset guitar chords diagrams(using picture environment). Now I want to make diagrams of different appear in good looking grid when typeset one next to each other as the picture shows: The picture. (on the picture: Labeled "First" bad layout of diagrams, labeled "Second" correct layout when equal number of ...

MS Word Macro - Numeric field insertion with automatic calculation at end of page

Hi, I am trying to duplicate a feature that exists in Multimate (Ashton Tate) word processor. Yes, the one that hasnt been supported for 20 years! If I can duplicate this one feature I can get all the users off MM and onto Word. The documents they create are billing documents. they consist of a descriptive paragraph of any length o...

bold small caps with mathpazo

The URW Palldio font (mathpazo package) does not provide bold small caps. To get round this issue, I'd want to make a macro to use small caps usually and normal caps in bold text. I tried this code: \documentclass{minimal} \usepackage[sc,osf]{mathpazo} % Use small caps normally except in a bold font: switch to uppercase instead. % Thi...

Refactor file copy in Visual Studio?

Does Visual Studio / Resharper support this? By refactor copy I mean to be able to enter new class name in some dialog, and to have the tool do all the refactoring (renaming) for you. No Copy of ... file names, and no error upon having two classes with same name in the project. Netbeans does this out-of-the-box :( ...

How to prevent latex memory overflow

I've got a latex macro that makes small pictures. In that picture I need to draw area. Borders of that area are quadratic bezier curves and that area is to be filled. I did not know how to do it so currently I'm "filling" the area by drawing a plenty of bezier curves inside it... This slows down typeseting and when a macro is used multi...

gcc run "light" preprocessor

Is there any way to run the gcc preprocessor, but only for user-defined macros? I have a few one-liners and some #ifdef etc... conditionals, and I want to see what my code looks like when just those are expanded. As it is, the includes get expanded, my fprintf(stderr)s turn into fprintf(((__getreeent())->_stderr), etc... ...

The way to find out whole picture width in PGF (Latex)

I've got a latex macro that draws a picture using PGF and Tikz according to given parameters. The width of picture drawn depends on these parameters. PGF automatically calculates the resulting width of any picture drawn so the user does not have to set it explicitly(like for example when using latex build in picture environment). Howe...

macro function for printing

Hi, if for example i have : #define PRINT(x) fprintf(stderr, x); and in code i append it : PRINT(("print this")) output is : [print this] if i append it : PRINT(("print %s", "this")) output is : [this] could someone explain me why it receives just the "this" argument and not the whole string ? ...

Excel Macro to copy an entire row from one sheet to another based upon a single word, within a paragraph, inside a cell

Guys i'm looking for a simple excel macro that can copy a row from one sheet to another within excel based upon having a specific word in the cell. I have a sheet one, called "data" and a sheet two called "final". Here is an eaxmple of the data A B C D john mary 555.555.4939 initial rep...

Looping through macro Varargs values

If I define some macro: #define foo(args...) ({/*do something*/}) Is there some way to actually loop through args rather than pass it along to another function? Something like #define foo(args...) \ { \ for (int i = 0; i < sizeof(args); ++i) { \ /*do something with args[i]*/ \ } \ ...

How do I map a macro across a list in Scheme?

I have a Scheme macro and a long list, and I'd like to map the macro across the list, just as if it were a function. How can I do that using R5RS? The macro accepts several arguments: (mac a b c d) The list has (define my-list ((a1 b1 c1 d1) (a2 b2 c2 d2) ... (an bn cn dn))) And ...

C++ boost wave, scoped macro

hello. Is it possible to have scoped macros using custom defined macros through boost wave? I know it should a possible with C++0x however I am working with regular C++. If it is possible, can you provide link or reference how to accomplish this? Thanks ...

Writing a C Macro

Hi, I have to write a macro that get as parameter some variable, and for each two sequential bits with "1" value replace it with 0 bit. For example: 10110100 will become 10000100. And, 11110000->00000000 11100000->100000000 I'm having a troubles writing that macro. I've tried to write a macro that get wach bit and replace it if the nex...

Retrieve data like rework %, schedule and effort varience from Microsoft Project

Hi, I need to generate various metric from my MS project file for the period of one month. I need to generate following reports Schedule Variance Effort Variance Rework Percentage Wasted Efforts For rework percentage, I am using condition like the task.Start date should be greater than or equal to the start date and task.Finish da...

Any low-level macro is defined to indentify iPhone OS w/o include any Apple header?

When compiling a vanilla iPhone project, any macro is defined to identify the platform is on iPhone OS, even when no header file is included? TARGET_OS_MAC or TARGET_OS_IPHONE-like macros are not defined if no header is included. So I am looking for macros defined at the similar level of __cplusplus , __GNUC__ , _MSC_VER ... etc. ...

can anyone help me with this macro?

Anyone can explain in details what the following macro does? #define write_XDATA(address,value) (((char *)0x010000) [address]=value) thx! ...

Stringification of a macro value

I faced a problem - I need to use a macro value both as string and as integer. #define RECORDS_PER_PAGE 10 /*... */ #define REQUEST_RECORDS \ "SELECT Fields FROM Table WHERE Conditions" \ " OFFSET %d * " #RECORDS_PER_PAGE \ " LIMIT " #RECORDS_PER_PAGE ";" char result_buffer[RECORDS_PER_PAGE][MAX_RECORD_LEN]; /...